Skip to main content

walkerOS Runner

The walkerOS runner is the walkeros/flow Docker image in self-bundling mode. Point it at a flow config — local file or API — and it bundles, runs, and keeps itself up to date.

Loading...

Runner vs Docker runtime

Runner (this page)Docker runtime
InputFlow config (JSON)Pre-built bundle (.mjs)
BundlingSelf-bundles internallyNone — expects pre-built
API integrationHeartbeat, config polling, hot-swapNone
Use caseSelf-hosted production, managed deploySimple deploy, CI/CD pipelines

Use the runner when you want API visibility, remote config, or hot-swap. Use the Docker runtime when you pre-build bundles in CI and want minimal images.

Deployment modes

Same image, same config format. Each mode adds one env var:

ModeWhat you setWhat happens
A. LocalBUNDLE onlyBundles config, runs. No API.
B. Registered+ WALKEROS_TOKEN + PROJECT_IDSame as A, plus heartbeat. Visible in dashboard.
C. Remote config+ FLOW_IDFetches config from API. Polls for updates. Hot-swaps on change.
D. Managed(set by walkerOS)Same as C, on walkerOS infrastructure.

Mode A: fully local

No signup, no token, no API:

Loading...

Mode B: local config + dashboard

Adds heartbeat registration. The runner appears in your project dashboard:

Loading...

Mode C: remote config with hot-swap

Config is fetched from the API. Polls for updates, hot-swaps on new versions:

Loading...

Environment variables

VariableDefaultDescription
MODEcollectcollect (HTTP event server) or serve (static file server)
PORT8080Server port
BUNDLE/app/flow/bundle.mjsLocal config/bundle path or URL
WALKEROS_TOKENAPI token for registration and config fetch
PROJECT_IDProject ID (required with WALKEROS_TOKEN)
FLOW_IDFlow ID for remote config (requires token + project)
CACHE_DIR/app/cacheDirectory for last-known-good bundle cache
POLL_INTERVAL30Seconds between config polls (mode C/D)
HEARTBEAT_INTERVAL60Seconds between heartbeats (mode B/C/D)
APP_URLhttps://app.walkeros.ioAPI base URL (alias: WALKEROS_APP_URL)

Validation rules

Invalid combinations fail fast with actionable error messages:

Vars setResult
Nothing or BUNDLE onlyMode A — local bundle, no API
WALKEROS_TOKEN + PROJECT_IDMode B — local config + heartbeat
WALKEROS_TOKEN + PROJECT_ID + FLOW_IDMode C/D — remote config + polling
FLOW_ID without tokenError: FLOW_ID requires WALKEROS_TOKEN and PROJECT_ID
WALKEROS_TOKEN without PROJECT_IDError: WALKEROS_TOKEN requires PROJECT_ID
BUNDLE + FLOW_IDStarts with local bundle, polls for remote. Hot-swaps when remote version is newer.

Pipeline

After config is resolved, all modes converge into the same pipeline:

1. Validate env ─────────── all modes ──────────
2. Resolve config local | API fetch

┌──────────────────┐
│ config (Flow.Setup) │
└──────────────────┘

3. Bundle ───────────────── esbuild ────────────
4. Cache ────────────── write last-known-good ──
5. Run ──────────────────── all modes ──────────
6. Heartbeat ────────────── if token set ───────
7. Poll + hot-swap ──────── if flow_id set ─────

Polling and hot-swap

When FLOW_ID is set, the runner polls for config changes using ETags:

  1. Every POLL_INTERVAL seconds, checks for a new config version
  2. 304 Not Modified — no action
  3. New version detected — downloads config, bundles locally, atomically swaps the running flow, updates cache, reports version via heartbeat

If the new bundle fails to load, the current flow stays active (safe swap).

Caching and resilience

The runner writes the last working bundle to CACHE_DIR (/app/cache). This provides cold-start resilience:

  • API unreachable at startup — falls back to cached bundle
  • Bundling fails — uses cached bundle instead
  • Mount as a Docker volume to persist across restarts
Loading...

Health checks

The /health endpoint is available on the configured PORT:

Loading...
Loading...

In serve mode, /status returns detailed runner state (instance ID, config version, config source, uptime, API status).

The Docker image includes a built-in HEALTHCHECK that polls /health every 30 seconds with a 30-second start period.

Docker Compose examples

Mode A: local config

Loading...

Mode C: remote config with cache

Loading...
Heartbeat details

When WALKEROS_TOKEN and PROJECT_ID are set, the runner sends periodic heartbeats:

  • Endpoint: POST /api/projects/:projectId/runners/heartbeat
  • Interval: Every HEARTBEAT_INTERVAL seconds (default 60)
  • Payload: instance ID, flow ID, config version, CLI version, uptime, mode
  • Fire-and-forget: Failures are logged, never crash the runner

Runners appear in the project dashboard after their first heartbeat.

Building a custom image
Loading...

Pin a specific CLI version:

Loading...

Troubleshooting

Runner won't start — Check the error message. Invalid env var combinations produce specific errors like FLOW_ID requires WALKEROS_TOKEN and PROJECT_ID.

API fetch fails at startup — The runner falls back to the cached bundle. If no cache exists, it exits. Mount CACHE_DIR as a volume for resilience.

Hot-swap not working — Verify FLOW_ID is set (polling only runs in mode C/D). Check logs for Config unchanged or Poll error. Confirm the flow was updated in the walkerOS UI.

Bundle fails after config fetch — The runner continues with the current flow and logs the error. The cached bundle is not overwritten.

Next steps

💡 Need Professional Support?
Need professional support with your walkerOS implementation? Check out our services.