Files
OpenHands/docker
aivong-openhands 5076bb3517 APP-2306: Add VITE_POSTHOG_CLIENT_KEY to Docker build (#1302)
* Add VITE_POSTHOG_CLIENT_KEY to Docker build

Bake the PostHog client key into the frontend bundle at build time by
accepting a VITE_POSTHOG_CLIENT_KEY build arg in the Dockerfile and
passing it from the Docker workflow via the POSTHOG_CLIENT_KEY repo
variable. The key is a public, client-side key (not a secret), following
the same pattern as VITE_APP_ENV.

Closes APP-2306

* Select staging/prod PostHog key by release tag

Mirror the VITE_APP_ENV logic for VITE_POSTHOG_CLIENT_KEY: tagged v*
releases bake the prod key, all other builds (PR/main/local) use staging.
Both keys are public client-side keys (not secrets) sourced from the
POSTHOG_CLIENT_KEY_PROD / POSTHOG_CLIENT_KEY_STAGING repo variables.

* Rename PostHog repo vars to POSTHOG_STAGING_KEY / POSTHOG_PROD_KEY
2026-06-10 22:36:24 +00:00
..