salendron / Snakeberry

A lightweight webservice based media player fpr Raspberry Pi.
14 stars 10 forks source link

Added init.d startup script #3

Open nichtich opened 11 years ago

nichtich commented 11 years ago

Snakeberry should better use a startup script with PID file and write logs to /var/log, so I added this script. I would also like to create a debian package instead of asking people to do manual installation, but I have not figured out how, yet.

salendron commented 11 years ago

Thanks, that's great! I am a bit busy with projects irght now, but as soon as I have time for Snakeberry again I will merge your request!

Thanks again for your support!

nichtich commented 11 years ago

Ok, I'll add more issues and code so you can have a view later. :-)

diplopoda commented 11 years ago

I tried to use the web client and the init.d startup - but it (raspberry pi ;) ) keeps telling me that the new snakeberry is not a valid executable and I can't update rc.d.

Any hint?

nichtich commented 11 years ago

@diplopoda What excately have you tried? This should work:

chmod +x snakeberry
sudo cp snakeberry /etc/init.d/
sudo /etc/init.d/snakeberry 

The web client is not usable yet, I am working on it. Thanks for beta-testing :-)

diplopoda commented 11 years ago

@nichtich, when trying to do this, this error comes up:

sudo: /etc/init.d/snakeberry: command not found

nichtich commented 11 years ago

@diplopoda you have to copy the file snakeberry to this location:

cd /home/pi/snakeberry/SnakeberryService/
sudo cp snakeberry /etc/init.d/

If you are not comfortable with linux shell and files it may be easier to wait until we have a custom installer script for SnakeberryService