Two surfaces, two platforms.
Config: apphosting.yaml at the repo root.
| App | sites/mainweb (workspace web) |
| Runtime | Node 22 |
| Output | Next standalone (sites/mainweb/.next/standalone/sites/mainweb/server.js) |
| Concurrency | 80 |
| CPU / memory | 2 / 1024 MiB |
| Instances | 0–10 |
| GCP project | dsgt-website |
Build command (abbreviated):
pnpm installdrizzle-kit push --verbose < /dev/nullon@query/db(additive only; destructive waits for a TTY confirmation that stdin cannot give)pnpm --filter @query/db db:check— fails the build if a declared column is missingpnpm turbo run build --filter=web- Copy
.next/static(andpublicif present) into the standalone tree
Run: node sites/mainweb/.next/standalone/sites/mainweb/server.js
Secrets are GCP Secret Manager. Grant the App Hosting backend access once per secret, e.g. firebase apphosting:secrets:grantaccess DATABASE_URL --backend query.
Env mapping (names only) is in apphosting.yaml: DATABASE_URL, AUTH_SECRET (also copied to NEXTAUTH_SECRET), Google/GitHub OAuth, Stripe, SMTP, DDoS ceilings, TRUSTED_PROXY_HOPS=1.
Config: firebase.json, .firebaserc.
| Hosting site / target | Public directory |
|---|---|
dsgt-website |
sites/mainweb/out (legacy static path; production mainweb is App Hosting, not this) |
target hacklytics |
sites/hacklytics2027/out |
Live deploys of Hacklytics: push to main runs pnpm turbo run build --filter=hacklytics2027 then FirebaseExtended/action-hosting-deploy with channelId: live and target: hacklytics. Pull requests get preview channels pr-<number>.
Service account secret: FIREBASE_SERVICE_ACCOUNT_DSGT_WEBSITE.
See GCP_SETUP.md:
gcloud auth login
gcloud auth application-default login
firebase login
gcloud config set project dsgt-website
firebase use dsgt-website./scripts/sync-secrets.sh is referenced there for pulling Secret Manager values into .env.local. If that script is not in the tree, copy secrets from Secret Manager manually or recreate the script.
.dockerignore excludes git, node_modules, env files, markdown (except README), and Firebase metadata from an image build context. There is no root Dockerfile in the current tree; App Hosting builds from apphosting.yaml.
Sign in once, then insert an admin row with role = 'super_admin' and is_active = true for that user_id. Further staff are appointed from /admin/staff.