Skip to content

Instantly share code, notes, and snippets.

@HashWarlock
Last active February 27, 2026 01:51
Show Gist options
  • Select an option

  • Save HashWarlock/5da0b7e00839524c8162604ced251f34 to your computer and use it in GitHub Desktop.

Select an option

Save HashWarlock/5da0b7e00839524c8162604ced251f34 to your computer and use it in GitHub Desktop.
Deploy OpenClaw on GCP Workshop for AI Collective

Intro (2 minutes)

Hey everyone — I’m Joshua Waller, Director of Technical Evangelism at Phala, where we built dstack — an open framework for Confidential Compute and Private AI. Today we won’t be focusing on Private AI, but we will be exploring how to deploy OpenClaw on Google Cloud Platform using Compute Engine and Docker.

The goal is to walk out of here with a live, working Gateway running on GCP — and a clear mental model of how each piece fits together.

We’ll do this step‑by‑step, and I’ll pause at milestones to make sure everyone is on the same page before moving forward. If you get stuck, we’ll solve it together — no one gets left behind.

What you’ll accomplish today:

  • Create a GCP project and VM
  • Install Docker on the VM
  • Deploy OpenClaw using the official setup script
  • Access the Control UI securely
  • Verify the gateway is working

Milestones (we’ll pause after each):

  1. GCP Ready — project created, billing enabled, Compute Engine API on
  2. VM Online — instance created and SSH access confirmed
  3. Docker Ready — Docker installed and usable
  4. OpenClaw Deployed — ./docker-setup.sh completed successfully
  5. Control UI Working — UI opens and gateway token is accepted
  6. (If time) Messaging Connected — connect OpenClaw to Telegram and explore what’s possible next

If that sounds good, let’s get started with Step 1.

Deploying OpenClaw on GCP

Compute Engine + Docker (Workshop)

Speaker Notes: Welcome and quick intro. Set expectations for the flow.

Milestones (Roadmap)

Today’s Milestones

  1. GCP Ready
  2. VM Online
  3. Docker Ready
  4. OpenClaw Deployed
  5. Control UI Working
  6. (If time) Messaging Connected

Speaker Notes: We’ll pause after each milestone to regroup.

Pause Check: “Sound good? Everyone aligned on the roadmap?”

Milestone 1: GCP Ready

Goal: Project created, billing enabled, Compute API on Commands:

gcloud projects create <project-id> --name="OpenClaw Gateway"
gcloud config set project <project-id>
gcloud services enable compute.googleapis.com

Speaker Notes: This gives us a place to deploy and turns on the Compute Engine API.

Pause Check: “Does everyone see the project in GCP and billing enabled?”

Milestone 2: VM Online

Goal: VM created + SSH works Commands:

gcloud compute instances create openclaw-gateway \
  --zone=us-central1-a \
  --machine-type=e2-medium \
  --boot-disk-size=20GB \
  --image-family=debian-12 \
  --image-project=debian-cloud

gcloud compute ssh openclaw-gateway --zone=us-central1-a

Speaker Notes: We’re spinning up the host that will run OpenClaw.

Pause Check: “Who is successfully SSH’d into the VM?”

Milestone 3: Docker Ready

Goal: Docker installed and usable Commands:

sudo apt-get update
sudo apt-get install -y git curl ca-certificates
curl -fsSL https://get.docker.com | sudo sh
sudo usermod -aG docker $USER
exit
  
# Then SSH back in:

gcloud compute ssh openclaw-gateway --zone=us-central1-a

Speaker Notes: Docker isolates our runtime and makes upgrades predictable.

Pause Check: “Run docker --version — do you see output?”

Milestone 4: OpenClaw Deployed

Goal: OpenClaw running via setup script Commands:

git clone https://github.com/openclaw/openclaw.git
cd openclaw
mkdir -p ~/.openclaw ~/.openclaw/workspace
./docker-setup.sh

Speaker Notes: This script builds and starts the stack. Expect the onboarding UI afterward.

Pause Check: “Do you see the OpenClaw onboarding screen?”

Milestone 5: Control UI Working

Goal: UI reachable + token accepted Commands (SSH tunnel):

gcloud compute ssh openclaw-gateway --zone=us-central1-a -- -L 18789:127.0.0.1:18789

# Open: http://127.0.0.1:18789?token=<your-token>

Speaker Notes: We keep it loopback‑only and access securely via tunnel.

Pause Check: “Is anyone seeing token mismatch or origin errors?”

Milestone 6 (If Time): Messaging Connected

Goal: Connect Telegram + show live usage Topics:

• Add bot token in openclaw.json • Pair the bot • Demo basic commands

Speaker Notes: This is where OpenClaw becomes truly useful.

Pause Check: “Who wants to connect Telegram or Whatsapp now?”

Wrap / Q&A

What’s Next

  • Add skills
  • Customize Docker deployment flow
  • Automate workflows

Speaker Notes: Invite questions, mention follow‑up resources.

@HashWarlock
Copy link
Author

HashWarlock commented Feb 27, 2026

After Milestone 5 do as follows:

  • Update ~/.openclaw/openclaw.json under the gateway
"gateway": {
    "port": 18789,
    "mode": "local",
    "bind": "loopback",
    "controlUi": {
      "allowedOrigins": [
        "http://127.0.0.1:18789"
      ]
    },
    "auth": {
      "mode": "token",
      "token": "YOUR_TOKEN"
    },
    "remote": {
      "token": "YOUR_TOKEN"
    },
}

Then you will need to go to the URL http://127.0.0.1:18789?token=<your-token>

Screenshot 2026-02-26 at 7 30 24 PM

GO TO OVERVIEW TAB TO SEE YOU NEED TO RUN THESE COMMANDS:

docker compose -f <path-to>/openclaw/docker-compose.yml exec openclaw-gateway node dist/index.js devices list

Screenshot 2026-02-26 at 7 32 44 PM

THEN APPROVE THE DEVICE REQUEST:

docker compose -f <path-to>/openclaw/docker-compose.yml exec openclaw-gateway node dist/index.js devices approve <device-request-id>

# Check the devices list again and you will see the device approved and you chat with your Control UI
docker compose -f <path-to>/openclaw/docker-compose.yml exec openclaw-gateway node dist/index.js devices list
image

Screenshot 2026-02-26 at 7 33 37 PM

Chat with your agent in the Control UI and allow list your telegram ID:

image

AND YOU ARE LIVE! HAPPY BUILDING :)

Screenshot 2026-02-26 at 7 37 31 PM

Hit me up at joshua@phala.network and I will help you get through any problems. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment