SRCDS Steam group

starting srcds from wwwrun
I want to start a shellscript from the user wwwrun. The Script start a CSS Server from user srcds but it doesn't start :/

Here is the command in the shellscript:

su $CS_USER -l -c "screen -d -m -S $NAME $DAEMON $PARAMS"
$CS_USER is srcds.

Is it because the user srcds is password protected? Please help me.
Is there nobody who can help me?
You can use sudo for it

First make a script where you put in the screen-command you wanna run.

Start visudo to edit /etc/sudoers. visudo is just a vi-wrapper to edit /etc/sudoers safely. Now add the following line:
wwwuser localhost=(srcds) NOPASSWD:PATH_TO_SCRIPT
where PATH_TO_SCRIPT is the full path to the script you created.
If you wanna know more read the manpage of sudoers

Now you change the su-line in your script in:

That should do it
Note for our MickeySoft users:
A reboot a day, keeps Dr.Watson away Big Grin

Forum Jump:

Users browsing this thread: 1 Guest(s)