跳转到内容

Linux 安装指南

Linux 是运行 OpenClaw 作为全天候服务的理想选择。

Terminal window
# 更新系统
sudo apt update && sudo apt upgrade -y
# 安装 Python
sudo apt install python3.11 python3.11-venv python3-pip git -y
# 克隆并设置
git clone https://github.com/openclaw/openclaw.git
cd openclaw
python3.11 -m venv venv
source venv/bin/activate
pip install -r requirements.txt

创建 /etc/systemd/system/openclaw.service:

[Unit]
Description=OpenClaw AI Assistant
After=network.target
[Service]
Type=simple
User=openclaw
WorkingDirectory=/home/openclaw/openclaw
ExecStart=/home/openclaw/openclaw/venv/bin/python -m openclaw
Restart=always
[Install]
WantedBy=multi-user.target

启用并启动:

Terminal window
sudo systemctl daemon-reload
sudo systemctl enable openclaw
sudo systemctl start openclaw
提供商最低配置价格
DigitalOcean1GB RAM~$6/月
Vultr1GB RAM~$6/月
Hetzner2GB RAM~$4/月