Skip to content

Instantly share code, notes, and snippets.

@usmansaleem
Created November 19, 2019 06:18
Show Gist options
  • Save usmansaleem/a128f86517d573c714724bd03096be62 to your computer and use it in GitHub Desktop.
Save usmansaleem/a128f86517d573c714724bd03096be62 to your computer and use it in GitHub Desktop.
Systemd file blog backend - place the file in /etc/systemd/system
[Unit]
Description=Usman Saleem Blog - NodeJS Backend
Documentation=https://usmans.info
After=network.target
[Service]
Type=simple
User=blog
WorkingDirectory=/opt/blog-nodejs-ts
ExecStart=/usr/bin/yarn start
Restart=on-failure
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment