turknode.cloud/solutions/bots
Telegram and Discord bots
Bots need a machine that is always on and a stable IP. The smallest Linux plan is usually enough.
Recommended
- Plan
- The smallest plan in either location; more RAM for bots with a database
- System
- Ubuntu or Debian with Python or Node.js
- Process manager
- systemd, pm2 or Docker so the bot restarts by itself
Keep a bot running with systemd
Save this as /etc/systemd/system/mybot.service, then run systemctl enable --now mybot.
[Unit]
Description=My bot
After=network-online.target
[Service]
WorkingDirectory=/opt/mybot
ExecStart=/usr/bin/python3 bot.py
Restart=always
[Install]
WantedBy=multi-user.targetManage it from code too
Restart or rebuild the server through our API.