Skip to content

Instantly share code, notes, and snippets.

@scelis
Last active August 29, 2015 13:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save scelis/ca9d012cacc5022dbd24 to your computer and use it in GitHub Desktop.
Save scelis/ca9d012cacc5022dbd24 to your computer and use it in GitHub Desktop.
#!/bin/bash
# This file is located at: /etc/service/myservice/log/run
PATH=/usr/local/bin:/usr/bin:/bin
mkdir -p /var/log/myservice
chown scelis:scelis /var/log/myservice
exec 2>&1
exec setuidgid scelis multilog t s10485760 n5 '!tai64nlocal' /var/log/myservice
#!/bin/bash
# This file is located at: /etc/service/myservice/run
PATH=/usr/local/bin:/usr/bin
cd /home/scelis/repos/myservice
exec envdir /home/scelis/repos/myservice/env \
setuidgid scelis \
/usr/bin/python2.7 myservice.py
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment