From 699e9247b757a824bc83cdd1d512696fb574635f Mon Sep 17 00:00:00 2001 From: Amr Gaber Date: Tue, 16 Jun 2026 15:22:35 -0500 Subject: [PATCH] Parameterize deploy.sh account via GCP_ACCOUNT Removes the hardcoded deployer email from scripts/deploy.sh. The account now comes from a required GCP_ACCOUNT env var (clear error if unset); we don't fall back to the active gcloud account, to avoid deploying as the wrong identity. --- scripts/deploy.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/scripts/deploy.sh b/scripts/deploy.sh index 89aaa4b..51ba4bd 100755 --- a/scripts/deploy.sh +++ b/scripts/deploy.sh @@ -8,7 +8,15 @@ set -euo pipefail PROJECT="treepolitics-prod" -ACCOUNT="amr@agtechgroup.solutions" +# Deployer's gcloud account. Set GCP_ACCOUNT so no personal email is baked into +# git history and each deployer uses their own identity (we deliberately do NOT +# fall back to the active gcloud account, to avoid deploying as the wrong one). +ACCOUNT="${GCP_ACCOUNT:-}" +if [ -z "${ACCOUNT}" ]; then + echo "Set GCP_ACCOUNT to the gcloud account to deploy with, e.g.:" >&2 + echo " GCP_ACCOUNT=you@example.com ./scripts/deploy.sh" >&2 + exit 1 +fi REGION="us-east1" SERVICE="treepolitics-api" REPO="api"