Open Feuermurmel opened 9 years ago
Or write a systemd
unit file!!1 Yay!
I managed to create the following systems unit file:
/etc/systemd/system/youtube-podcast-gateway.service
[Unit]
Description=youtube-podcast-gateway
[Service]
ExecStart=/home/ubuntu/youtube-podcast-gateway/run.sh
#ExecReload=/usr/bin/pkill -f run.sh ; sleep 1 ; home/ubuntu/youtube-podcast-gateway/run.sh
ExecStop=/usr/bin/pkill -f run.sh
For some reason I'm not able to make working the ExecReload command...
I'm not ultra-familiar with systemd but shouldn't declaring ExecStop
be unnecessary for services which do not need to be shut down properly? I.e. systemd can just kill the whole process group/session/whatever?
Otherwise I'd like to but this into the repository as an example unit file. I will test this myself. Soon. :)
Probably just use ISC cron's @reboot syntax and some redirection to a log file.