🐧
Installation Guide

Clawdbot on Linux

Linux is the ideal platform for running Clawdbot. Follow this guide for Ubuntu, Debian, Fedora, Arch, and other distributions.

Supported Distributions

🐧

Ubuntu/Debian

apt

🎩

Fedora/RHEL

dnf

🔷

Arch Linux

pacman

🏔️

Alpine

apk

Installation by Distribution

Most Common
Ubuntu / Debian

Step 1: Update System

sudo apt update && sudo apt upgrade -y

Step 2: Install Node.js 20

curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -

sudo apt-get install -y nodejs

Step 3: Install Git

sudo apt install git -y

Step 4: Clone and Setup Clawdbot

git clone https://github.com/clawdbot/clawdbot.git

cd clawdbot

npm install

cp .env.example .env

nano .env # Add your API keys

Step 5: Start Clawdbot

npm start

Fedora / RHEL / CentOS

Install Dependencies

sudo dnf update -y

sudo dnf install -y nodejs npm git

Clone and Run

git clone https://github.com/clawdbot/clawdbot.git

cd clawdbot && npm install

cp .env.example .env && nano .env

npm start

Arch Linux

Install Dependencies

sudo pacman -Syu

sudo pacman -S nodejs npm git

Clone and Run

git clone https://github.com/clawdbot/clawdbot.git

cd clawdbot && npm install

cp .env.example .env && nano .env

npm start

Universal
Docker (Any Distribution)

Docker works on any Linux distribution and provides a consistent environment.

Install Docker

curl -fsSL https://get.docker.com | sh

sudo usermod -aG docker $USER

# Log out and back in

Run Clawdbot

git clone https://github.com/clawdbot/clawdbot.git

cd clawdbot

cp .env.example .env && nano .env

docker compose up -d

Running as a Systemd Service

To run Clawdbot automatically on boot and keep it running in the background:

Create Service File

sudo nano /etc/systemd/system/clawdbot.service

Service Configuration

[Unit]

Description=Clawdbot AI Assistant

After=network.target

[Service]

Type=simple

User=your_username

WorkingDirectory=/home/your_username/clawdbot

ExecStart=/usr/bin/npm start

Restart=on-failure

RestartSec=10

[Install]

WantedBy=multi-user.target

Enable and Start

sudo systemctl daemon-reload

sudo systemctl enable clawdbot

sudo systemctl start clawdbot

sudo systemctl status clawdbot # Check status

Troubleshooting

EACCES permission denied

Don't use sudo with npm. Fix npm permissions by running: mkdir ~/.npm-global && npm config set prefix '~/.npm-global'

Node.js version too old

Clawdbot requires Node.js 18+. Use the NodeSource repository or nvm to install a newer version.

Service fails to start

Check logs with sudo journalctl -u clawdbot -f. Common issues include wrong paths or missing environment variables.