{
  "title": "Create a persistent volume (1GB is usually enough)",
  "content": "fly volumes create openclaw_data --size 1 --region iad\ntoml theme={null}\napp = \"my-openclaw\"  # Your app name\nprimary_region = \"iad\"\n\n[build]\n  dockerfile = \"Dockerfile\"\n\n[env]\n  NODE_ENV = \"production\"\n  OPENCLAW_PREFER_PNPM = \"1\"\n  OPENCLAW_STATE_DIR = \"/data\"\n  NODE_OPTIONS = \"--max-old-space-size=1536\"\n\n[processes]\n  app = \"node dist/index.js gateway --allow-unconfigured --port 3000 --bind lan\"\n\n[http_service]\n  internal_port = 3000\n  force_https = true\n  auto_stop_machines = false\n  auto_start_machines = true\n  min_machines_running = 1\n  processes = [\"app\"]\n\n[[vm]]\n  size = \"shared-cpu-2x\"\n  memory = \"2048mb\"\n\n[mounts]\n  source = \"openclaw_data\"\n  destination = \"/data\"\nbash theme={null}",
  "code_samples": [
    {
      "code": "**Tip:** Choose a region close to you. Common options: `lhr` (London), `iad` (Virginia), `sjc` (San Jose).\n\n## 2) Configure fly.toml\n\nEdit `fly.toml` to match your app name and requirements.\n\n**Security note:** The default config exposes a public URL. For a hardened deployment with no public IP, see [Private Deployment](#private-deployment-hardened) or use `fly.private.toml`.",
      "language": "unknown"
    },
    {
      "code": "**Key settings:**\n\n| Setting                        | Why                                                                         |\n| ------------------------------ | --------------------------------------------------------------------------- |\n| `--bind lan`                   | Binds to `0.0.0.0` so Fly's proxy can reach the gateway                     |\n| `--allow-unconfigured`         | Starts without a config file (you'll create one after)                      |\n| `internal_port = 3000`         | Must match `--port 3000` (or `OPENCLAW_GATEWAY_PORT`) for Fly health checks |\n| `memory = \"2048mb\"`            | 512MB is too small; 2GB recommended                                         |\n| `OPENCLAW_STATE_DIR = \"/data\"` | Persists state on the volume                                                |\n\n## 3) Set secrets",
      "language": "unknown"
    }
  ],
  "headings": [
    {
      "level": "h2",
      "text": "2) Configure fly.toml",
      "id": "2)-configure-fly.toml"
    },
    {
      "level": "h2",
      "text": "3) Set secrets",
      "id": "3)-set-secrets"
    }
  ],
  "url": "llms-txt#create-a-persistent-volume-(1gb-is-usually-enough)",
  "links": []
}