diff --git a/install/bot-server.service b/install/bot-server.service new file mode 100644 index 0000000..054c354 --- /dev/null +++ b/install/bot-server.service @@ -0,0 +1,20 @@ +[Unit] +# Set this to something specific for this bot +Description="CircleBot Instance" + +[Service] +ExecStart=/usr/bin/npm start +# Set this to the bot's top level directory +WorkingDirectory=/opt/bots/CircleBot +Restart=always +RestartSec=10 +StandardOutput=journal +StandardError=journal +# Set this to something specific for this bot +SyslogIdentifier=CircleBot +# Set these to the appropriate owner of the bot folders +User=botuser +Group=botuser + +[Install] +WantedBy=multi-user.target