chore(staging): enable submitter-view-all PO history flag on staging
Add NEXT_PUBLIC_SUBMITTER_VIEW_ALL_ENABLED=true to the staging env so submitters (TECHNICAL/MANNING) can read all POs and open the History page on the staging instance for testing ahead of a prod rollout. The flag is written into the freshly-provisioned .env heredoc and also appended idempotently to already-provisioned staging .envs on the next refresh. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
parent
7980d68a7a
commit
e4f7f6623f
2 changed files with 13 additions and 0 deletions
|
|
@ -221,6 +221,11 @@ before a release tag deploys them to prod.
|
|||
- A fixed banner **"INTERNAL DEV / STAGING - NOT PRODUCTION"** is shown (driven by
|
||||
`NEXT_PUBLIC_ENV_LABEL` in the staging `.env`; the `EnvBanner` component renders nothing
|
||||
when the var is unset, so production is unaffected).
|
||||
- **Feature flags on staging:** `staging-up.sh` enables
|
||||
`NEXT_PUBLIC_SUBMITTER_VIEW_ALL_ENABLED=true`, so submitters (TECHNICAL/MANNING) can
|
||||
read every PO and open the History page here (read-only) for testing ahead of a prod
|
||||
rollout. The line is appended idempotently, so already-provisioned staging `.env`s pick
|
||||
it up on the next refresh.
|
||||
- Log in with a password user (SSO is off here), e.g. `admin@pelagiamarine.com`.
|
||||
|
||||
## Issue label lifecycle
|
||||
|
|
|
|||
|
|
@ -42,12 +42,20 @@ AZURE_AD_CLIENT_SECRET="dev-placeholder"
|
|||
AZURE_AD_TENANT_ID="dev-placeholder"
|
||||
DATABASE_URL="$TEST_URL"
|
||||
GST_SERVICE_URL="http://localhost:3003"
|
||||
NEXT_PUBLIC_SUBMITTER_VIEW_ALL_ENABLED=true
|
||||
NEXT_PUBLIC_ENV_LABEL="INTERNAL DEV / STAGING - NOT PRODUCTION"
|
||||
PORT=$PORT
|
||||
EOF
|
||||
chmod 600 "$DIR/App/.env"
|
||||
fi
|
||||
|
||||
# Ensure feature flags are present on already-provisioned staging envs too (the
|
||||
# .env above is written only once, so a flag added later won't appear without
|
||||
# this). Let submitters (TECHNICAL/MANNING) read all POs + open History on staging.
|
||||
if ! grep -qE '^NEXT_PUBLIC_SUBMITTER_VIEW_ALL_ENABLED=' "$DIR/App/.env"; then
|
||||
printf 'NEXT_PUBLIC_SUBMITTER_VIEW_ALL_ENABLED=true\n' >> "$DIR/App/.env"
|
||||
fi
|
||||
|
||||
# pm2-run wrapper so the dev server always gets nvm on PATH and the right port.
|
||||
# Bind to 127.0.0.1 only -- staging is reachable solely via SSH tunnel
|
||||
# (ssh -L 3200:localhost:3200 ...), never directly from the public internet.
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue