# systemd unit — adjust User, WorkingDirectory, and EnvironmentFile paths. # Install: # sudo cp deploy/gallery.service /etc/systemd/system/gallery.service # sudo systemctl daemon-reload # sudo systemctl enable --now gallery [Unit] Description=Art Gallery (Node.js) After=network.target [Service] Type=simple User=gallery WorkingDirectory=/opt/Art-gallery Environment=NODE_ENV=production EnvironmentFile=/opt/Art-gallery/.env ExecStart=/usr/bin/node server/index.js Restart=on-failure RestartSec=5 [Install] WantedBy=multi-user.target