Linux Setup
Overview
Section titled “Overview”Linux is ideal for running Clawdbot as a always-on service. This guide covers Ubuntu/Debian, Fedora, and Arch Linux.
Installation
Section titled “Installation”# Update systemsudo apt update && sudo apt upgrade -y
# Install Pythonsudo apt install python3.11 python3.11-venv python3-pip git -y
# Clone Clawdbotgit clone https://github.com/polvoazul/clawdbot.gitcd clawdbot
# Setup environmentpython3.11 -m venv venvsource venv/bin/activatepip install -r requirements.txt
# Configurecp .env.example .envnano .env# Install Pythonsudo dnf install python3.11 python3-pip git -y
# Clone and setupgit clone https://github.com/polvoazul/clawdbot.gitcd clawdbotpython3.11 -m venv venvsource venv/bin/activatepip install -r requirements.txt# Install Pythonsudo pacman -S python python-pip git
# Clone and setupgit clone https://github.com/polvoazul/clawdbot.gitcd clawdbotpython -m venv venvsource venv/bin/activatepip install -r requirements.txtRunning as Service
Section titled “Running as Service”Using systemd
Section titled “Using systemd”Create /etc/systemd/system/clawdbot.service:
[Unit]Description=Clawdbot AI AssistantAfter=network.target
[Service]Type=simpleUser=clawdbotWorkingDirectory=/home/clawdbot/clawdbotEnvironment="PATH=/home/clawdbot/clawdbot/venv/bin"ExecStart=/home/clawdbot/clawdbot/venv/bin/python -m clawdbotRestart=alwaysRestartSec=10
[Install]WantedBy=multi-user.targetEnable and start:
sudo systemctl daemon-reloadsudo systemctl enable clawdbotsudo systemctl start clawdbotManaging the Service
Section titled “Managing the Service”# Check statussudo systemctl status clawdbot
# View logssudo journalctl -u clawdbot -f
# Restartsudo systemctl restart clawdbot
# Stopsudo systemctl stop clawdbotVPS Deployment
Section titled “VPS Deployment”Recommended Providers
Section titled “Recommended Providers”| Provider | Min Specs | Price |
|---|---|---|
| DigitalOcean | 1GB RAM | ~$6/mo |
| Vultr | 1GB RAM | ~$6/mo |
| Linode | 1GB RAM | ~$5/mo |
| Hetzner | 2GB RAM | ~$4/mo |
Security Hardening
Section titled “Security Hardening”# Update systemsudo apt update && sudo apt upgrade -y
# Configure firewallsudo ufw allow sshsudo ufw allow 443 # If using webhookssudo ufw enable
# Create dedicated usersudo useradd -m -s /bin/bash clawdbotsudo su - clawdbotTroubleshooting
Section titled “Troubleshooting”Service won’t start
# Check logssudo journalctl -u clawdbot -n 50
# Verify permissionsls -la /home/clawdbot/clawdbot/High memory usage
- Reduce context length
- Use lighter model (Haiku)