818 B
818 B
Marvin deployment (systemd)
This project is intended to run as a systemd service using polling, a .env file for configuration, and a dedicated unprivileged user.
Recommended setup
- Create a dedicated user:
marvin - Place the project at:
/home/marvin/marvin - Store secrets in:
/home/marvin/marvin/.env - Run the bot with systemd
- View logs with:
journalctl -u marvin -f
Service file
Install the provided service file:
sudo cp deploy/marvin.service /etc/systemd/system/marvin.service
sudo systemctl daemon-reload
sudo systemctl enable --now marvin
Notes
- The bot uses Telegram polling (
getUpdates), so only one instance should run at a time. - If another copy is running, you may see a Telegram 409 conflict.
- Use
journalctl -u marvin -fto follow logs live.