services: Add Discord Bot service
This commit is contained in:
parent
732e5e1cd4
commit
6c17cd62eb
5 changed files with 59 additions and 0 deletions
16
roles/services/templates/discord-bot.service
Normal file
16
roles/services/templates/discord-bot.service
Normal file
|
@ -0,0 +1,16 @@
|
|||
# Managed by Ansible
|
||||
|
||||
[Unit]
|
||||
Description=HobbyBot
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Restart=on-failure
|
||||
RestartSec=10s
|
||||
ExecStart=/var/lib/discord-bot/main.py
|
||||
DynamicUser=true
|
||||
Environment="DISCORD_TOKEN={{ discord_token }}"
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Add table
Add a link
Reference in a new issue