2016-08-21, 18:56
(2016-08-21, 18:46)MikeKL Wrote: This is current content of service.webgrabplus.service which starts on boot and then every 21600 seconds (six hours) after that :-
Quote:[Unit]
Description=WebGrab+Plus
Documentation=http://www.webgrabplus.com/
After=network.target
Requires=network.target
[Service]
ExecStart=/bin/sh /storage/.kodi/addons/service.webgrabplus/bin/webgrabplus.start
Restart=always
RestartSec=21600
[Install]
WantedBy=kodi.target
I understand from page you pointed me to that I would need to create an additonal service.webgrabplus.timer file (in same folder?)
i.e. something similar to as follows :-
Quote:[Unit]
Description=Run WebGrab+Plus daily
[Timer]
OnCalendar=*-*-* 03:00:00
Persistent=true
[Install]
WantedBy=timers.target
But currently not sure what to do to start timer and how it actually interacts with service.webgrabplus.service and what I need to edit in orginal service file etc.
Will keep reading/studying
I don't know much about systemd much yet either. I haven't needed to set up linux init scripts for a long time.
I was hoping we could just remove the RestartSec and replace it with the Timer section but I am just hoping.
If that works we should be able to add a setting in the Kodi service configuration to set the time to run it at.
Then the kodi service can edit the system service file and restart it.
I hope you can work it out. Good Luck.