How to start a service at boot time in ubuntu 12.04, run as a different user?
- by Alex
I have a server ClueReleaseManager which I have installed on a Ubuntu 12.04 system from a separate user (named pypi), and I want to be able to start this server at startup.
I already have tried to create a simple bash script with some commands (login as user pypi, use a virtual python environment, start the server), but this does not work properly. Either the terminal crashes or when I try to ask the status of the service it is started and I am logged in as user pypi ...?
So, here the question: What are the steps to take to make sure the ClueReleaseManager service properly starts up on boot time, and which I can control (start/stop/..) during runtime, while the service is running from a user pypi?
Additional information and constraints:
I want to do this as simple as possible
Without any other packages/programs to be installed
I am not familiar with the Ubuntu 12.04 init structure
All the information I found on the web is very sparse, confusing, incorrect or does not apply to my case of running a service as a different user from root.