[Unit]
Description=*** ****** Service //서비스 제목 또는 설명
After=network.target // network가 커널에서 로드된이후
[Service]
ExecStart=/home/****/***/service-name //실행파일 경로
ExecStop=/home/****/***/service-name //실행파일 경로
Restart=on-failure //restart 조건 (on-failure : 오류발생시 재시작, always : 항상)
RestartSec=60 // 60초 주기
[Install]
WantedBy=multi-user.target
출처 ) https://nasanx2001.tistory.com/m/entry/우분투-1804-자동실행-서비스등록
Ubuntu 16.04 system service 등록하기)
https://pinedance.github.io/blog/2017/09/12/Ubuntu-16.04-system-service-등록하기
리눅스에서 Service 등록하기)
https://khann.tistory.com/m/5
[Ubuntu] Systemd Service 등록) == 옵션 설명잘되어 있음.
https://blog.silnex.kr/ubuntu-systemd-service-등록/