diff --git a/.gitignore b/.gitignore index 864575245..399acf48d 100644 --- a/.gitignore +++ b/.gitignore @@ -23,6 +23,11 @@ dist-electron # Desktop production config is public (backend URL, etc.) — track it so # `pnpm package` produces a release-ready build without extra setup. !apps/desktop/.env.production +# Desktop staging config is public (staging API/web URLs) — track it so +# `pnpm dev:desktop:staging` works from a fresh checkout instead of relying +# on a hand-written local env file (MUL-5025: a misnamed VITE_ var there +# silently broke copy-link URLs). +!apps/desktop/.env.staging # Mobile staging config is public (staging API URL) — track it so a fresh # checkout can run `pnpm dev:mobile:staging` / `ios:mobile*:staging` without # the user having to copy `.env.example` first. diff --git a/apps/desktop/.env.staging b/apps/desktop/.env.staging new file mode 100644 index 000000000..bd28da7c5 --- /dev/null +++ b/apps/desktop/.env.staging @@ -0,0 +1,11 @@ +# Internal staging environment; not a public support environment. +# Used by `pnpm dev:desktop:staging` (`electron-vite dev --mode staging`). +# Personal overrides go in .env.staging.local. +VITE_API_URL=https://multica-api.copilothub.ai + +# VITE_APP_URL is the web app origin used for copy-link/open-in-browser URLs. +# Do not point it at the API host. It must be explicit here: the `api.` +# derivation in shared/runtime-config.ts doesn't match this deployment's +# `multica-api.` naming and would fall back to the API origin +# (MUL-5025). +VITE_APP_URL=https://multica-app.copilothub.ai diff --git a/apps/mobile/.env.staging b/apps/mobile/.env.staging index 16b0fb60b..2679127da 100644 --- a/apps/mobile/.env.staging +++ b/apps/mobile/.env.staging @@ -1,10 +1,9 @@ +# Internal staging environment; not a public support environment. # Used by `pnpm dev:mobile:staging` and the `ios:device:staging[:release]` # scripts. Loaded via `dotenv-cli` (see package.json), NOT by Expo's auto- # loader — Expo only auto-loads .env..local files. EXPO_PUBLIC_API_URL=https://multica-api.copilothub.ai # Optional. Enables "Copy link" / "Open on web" actions in issue / project / -# comment menus. Without it those menu items just don't appear. Fill in the -# staging web host when you have it (canonical value lives in -# apps/desktop/.env.staging on a teammate's machine). -# EXPO_PUBLIC_WEB_URL=https:// +# comment menus. Without it those menu items just don't appear. +EXPO_PUBLIC_WEB_URL=https://multica-app.copilothub.ai