OpenClaw on DigitalOcean
Deploy your personal AI assistant with WhatsApp, Telegram, and Gmail
PowerShell (Windows)
irm https://raw.githubusercontent.com/marshellis/ai-foundry/main/rigs/openclaw-droplet/install.ps1 | iexBash (macOS / Linux)
curl -fsSL https://raw.githubusercontent.com/marshellis/ai-foundry/main/rigs/openclaw-droplet/install.sh | bashAbout
A complete setup for OpenClaw on a DigitalOcean droplet. Includes remote installation, swap optimization, and guided setup for WhatsApp (with dedicated number), Telegram bot, and Gmail Pub/Sub integration.
What It Does
Deploys OpenClaw on a DigitalOcean droplet ($6/month) from a Windows PowerShell terminal. The installer SSHs into the droplet, installs OpenClaw with systemd persistence, and walks you through setting up Gmail (via Pub/Sub webhooks) and Google Drive/Docs (read and write access via OAuth). After setup, your AI assistant can send and receive email and read/write Google Docs.
Use Cases
- Personal AI assistant with Gmail and Google Drive access, deployed from Windows
- Always-on AI that runs 24/7 on a cheap VPS
- Private alternative to cloud AI assistants with full Google Workspace integration
What the Installer Does
For transparency, here is exactly what the installer does:
- 1
Create or select droplet
Optionally create a new droplet via doctl, or enter existing droplet IP
- 2
Connect to droplet via SSH
Tests SSH connection and uploads setup script
- 3
Update system and add swap
Runs apt upgrade and creates 2GB swap for 1GB droplets
- 4
Install Node.js 22 and dependencies
NodeSource, gcloud CLI, Tailscale
- 5
Run OpenClaw installer
Downloads and runs the official OpenClaw installer
- 6
Run onboarding wizard
Interactive setup for daemon, API keys, and initial config
- 7
Guide Gmail Pub/Sub setup
Walk through GCP project, topic, and webhook configuration for sending and receiving email
- 8
Authorize Google Docs and Drive
Enables Docs and Drive APIs and expands OAuth scopes so the assistant can read/write Google Docs
Verifying It Works
After installation, follow these steps to confirm everything is working:
- 1
Check OpenClaw is running
Expected: openclaw status shows gateway running with systemd
- 2
Access Control UI via SSH tunnel
Expected: ssh -L 18789:localhost:18789 root@DROPLET_IP then open http://localhost:18789
- 3
Send an email to your assistant's Gmail
Expected: Email triggers Pub/Sub webhook, assistant processes and can respond
- 4
Ask the assistant to read a Google Doc
Expected: Assistant can access and summarize Google Docs the authenticated account has access to
- 5
Ask the assistant to list files in Google Drive
Expected: Assistant can list and search files in Google Drive
Windows 10+
PowerShell with OpenSSH client (built into Windows 10 and later)
Account with billing enabled. Droplet can be created automatically via doctl or manually.
SSH Key
SSH key added to DigitalOcean (for doctl) or droplet access configured
DigitalOcean CLI for automated droplet creation. Install and run 'doctl auth init'.
For the AI model powering the assistant
With billing enabled for Gmail Pub/Sub and Google Drive/Docs OAuth
Windows installer -- runs from PowerShell, SSHs into droplet
Bash installer for macOS/Linux (also available but not the primary target)
Setup script that runs on the droplet
Post-install channel configuration helper