Skip to content

Create a PHP deamon

nano /etc/init.d/collector

Add your service code inside this script to run as a deamon.

chmod +x /etc/init.d/collector

cd /etc/init.d

update-rc.d collector defaults 98 02

When you update the collector you need to commit the changes with the following command:

systemctl daemon-reload

To remove your created deamon you use:

update-rc.d collector remove

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *