Add init scripts

This commit is contained in:
Michael De Roover 2021-12-13 21:15:18 +01:00
parent 0d5f7069a0
commit 071f89287a
Signed by: vim
GPG Key ID: 075496E232CE04CB
2 changed files with 19 additions and 0 deletions

7
init/openrc Normal file
View File

@ -0,0 +1,7 @@
#!/sbin/openrc-run
description="Telegram Userbot"
command="/usr/bin/ubot"
command_user="bot:bot"
command_background=true
pidfile="/run/ubot.pid"

12
init/systemd Normal file
View File

@ -0,0 +1,12 @@
[Unit]
Description=Telegram Userbot
[Service]
Type=simple
User=bot
ExecStart=/usr/bin/ubot
Restart=always
RestartSec=0
[Install]
WantedBy=multi-user.target