Skip to content

Instantly share code, notes, and snippets.

@thomasfr
Created September 9, 2013 14:33
Show Gist options
  • Save thomasfr/6496445 to your computer and use it in GitHub Desktop.
Save thomasfr/6496445 to your computer and use it in GitHub Desktop.
Systemd Services
[Unit]
Description=Description for this application
Requires=network.target
After=network.target
[Service]
WorkingDirectory=/srv/app
ExecStart=/usr/bin/npm start
Restart=always
StandardOuput=syslog
SyslogIdentifier=bi-reporting
User=http
Group=http
Environment=PATH=/bin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin
Environment=NODE_ENV=production
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment