From 727379c237c31137c331eca898bbd819d741add0 Mon Sep 17 00:00:00 2001 From: JHCD Date: Thu, 25 Jun 2015 18:56:46 +0200 Subject: [PATCH] small changes --- service/README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/service/README.md b/service/README.md index cdcf79b..3af43e7 100644 --- a/service/README.md +++ b/service/README.md @@ -1,21 +1,21 @@ ### Start BOSWatch as a daemon -## Changing the init script +##### Changing the init script Lines 14 and 15 define where to find the Python script. In this case the script expects that there is a folder `/usr/local/bin/BOSWatch` and that the script is inside there. -Line 23 sets what user to run the script as. Using root is generally not a good idea but might be necessary for BOSWatch. +Line 23 sets what user to run the script as. Using a root-user is necessary for BOSWatch. Line 19 sets the parameters for BOSWatch, use the same as starting BOSWatch from the shell. We recommend to use "-u" and "-q" when you want to run BOSWatch as a daemon. - "-u": You will find the logfiles in `/var/log/BOSWatch` - "-q": Shows no information. Only logfiles -## Using the init script +##### Using the init script To actually use this script, put your Python script where you want (recommend `/usr/local/bin/BOSWatch`) -and make sure it is executable (e.g. `sudo chmod 755 boswatch.py`) +and make sure it is executable (e.g. `sudo chmod 755 boswatch.py`). Edit the init script accordingly. Copy the init script into /etc/init.d using e.g. `sudo cp boswatch.sh /etc/init.d`. Make sure the script is executable (chmod again) and make sure that it has UNIX line-endings. @@ -25,4 +25,4 @@ check its status with the `sudo /etc/init.d/boswatch.sh status` argument and sto To make the Raspberry Pi use your init script at the right time, one more step is required: Running the command `sudo update-rc.d boswatch.sh defaults`. This command adds in symbolic links to the `/etc/rc.x` directories so that the init script is run at the default times. -You can see these links if you do ls -l /etc/rc?.d/*myservice.sh \ No newline at end of file +You can see these links if you do ls -l /etc/rc?.d/*boswatch.sh \ No newline at end of file