Skip to content

feat(tasks): add cloud hogland runtime option to workspace picker#2387

Draft
webjunkie wants to merge 1 commit into
mainfrom
feat/cloud-hogland-runtime-option
Draft

feat(tasks): add cloud hogland runtime option to workspace picker#2387
webjunkie wants to merge 1 commit into
mainfrom
feat/cloud-hogland-runtime-option

Conversation

@webjunkie
Copy link
Copy Markdown

Problem

Adds a "Cloud · Hogland" entry to the workspace picker so we can dark-launch the new hogland sandbox backend (see posthog/posthog#60042) end-to-end without committing to it as the default. Lets us A/B against the current Modal cloud runtime per-run.

Changes

  • WorkspaceModeSelect: new "Cloud · Hogland" row alongside the existing "Default", gated by feature flag tasks-hogland-runtime (on in dev). Picking Hogland clears the cloud environment selection; picking Default or a user env clears the runtime. Trigger label reflects the active choice.
  • Plumbs an optional sandboxRuntime through TaskInputuseTaskCreationTaskCreationSagacreateTaskRun, where it's serialized as the existing backend field sandbox_runtime.
  • sandbox_runtime and sandbox_environment_id are orthogonal: runtime picks the backend infra, environment picks the network policy. Mutually exclusive in this PR by design — if we ever want a per-env default runtime, that's a separate column on SandboxEnvironment.

Handoff is intentionally not touched. New cloud runs only.

How did you test this?

Local diff review against the existing sandboxEnvironmentId plumbing — same pattern, parallel field. Did not run typecheck (no pnpm install yet); the changes follow the existing patterns 1:1 so I'd be surprised if anything breaks, but worth running pnpm --filter @posthog/code typecheck before merging.

Publish to changelog?

no

Adds a "Cloud · Hogland" entry alongside the existing "Default" cloud
choice in WorkspaceModeSelect. Selecting it sends sandbox_runtime=posthog
on createTaskRun, which the posthog backend maps to the hogland sandbox
adapter (see feat/tasks-hogland-sandbox-runtime). Gated behind feature
flag tasks-hogland-runtime so we can dark-launch.

The new sandbox_runtime field is orthogonal to sandbox_environment_id:
runtime picks the backend infra, environment picks the network policy.
Picking a user env or "Default" clears the runtime; picking Hogland
clears the env.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant