Created
June 25, 2013 12:58
-
-
Save slashdevsda/5858233 to your computer and use it in GitHub Desktop.
basic systemd unit for nodeJS, using forever.
with mongodb dep.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Start Node.js Service | |
Requires=network.target mongodb.service | |
After=network.target | |
[Service] | |
Type=forking | |
WorkingDirectory=/srv/node/ | |
ExecStart=/usr/bin/forever start --pidFile /srv/node/nodeserialskiller.pid /srv/node/server.js | |
ExecStop=/usr/bin/forever stop /srv/node/server.js | |
PIDFile=/srv/node/nodeserialskiller.pid | |
User=nodejs | |
Group=nodejs | |
[Install] | |
WantedBy=multi-user.target | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment