| 123456789101112131415161718192021222324252627282930313233 |
- [Unit]
- Description=SmartBotic Runner Service
- Documentation=https://github.com/smartbotic/smartbotic
- After=network.target smartbotic-webserver.service
- Requires=smartbotic-webserver.service
- # Without PartOf, "systemctl restart smartbotic.target" starts nothing and
- # stops nothing: a target is only a grouping, and restart/stop do not reach
- # its members through Wants alone. That silently leaves an old binary running
- # after a rebuild, with systemctl still reporting the target as active.
- PartOf=smartbotic.target
- [Service]
- Type=simple
- WorkingDirectory=/data/smartbotic
- # Add delay to ensure webserver is fully started before runner tries to register
- ExecStartPre=/bin/sleep 3
- ExecStart=/data/smartbotic/build/smartbotic-runner
- Restart=on-failure
- RestartSec=5
- StandardOutput=journal
- StandardError=journal
- # Environment
- Environment=LOG_LEVEL=info
- Environment=RUNNER_ID=runner-1
- Environment=NODES_PATH=/data/smartbotic/nodes
- # Resource limits
- LimitNOFILE=65536
- [Install]
- WantedBy=default.target
|