From 5390beaed9210ad9fbbdf9a5d85cd941af89dc9c Mon Sep 17 00:00:00 2001 From: chpark Date: Thu, 23 Apr 2026 01:38:55 +0900 Subject: [PATCH] =?UTF-8?q?fix(ci):=20secrets=20source=EB=A5=BC=20docker?= =?UTF-8?q?=20build=20=EC=9D=B4=EC=A0=84=EC=9C=BC=EB=A1=9C=20=EC=9D=B4?= =?UTF-8?q?=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/deploy-remote.sh | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scripts/deploy-remote.sh b/scripts/deploy-remote.sh index 24635de..a6f86f5 100644 --- a/scripts/deploy-remote.sh +++ b/scripts/deploy-remote.sh @@ -28,7 +28,13 @@ else cd insurance fi -echo "[*] Building web image" +# 빌드 전에 비밀값 로드 (EXPO_PUBLIC_* 포함) +SECRETS_FILE=/home/chpark/.insurance-secrets +if [ -r "$SECRETS_FILE" ]; then + set -a; source "$SECRETS_FILE"; set +a +fi + +echo "[*] Building web image (kakao key len=${#EXPO_PUBLIC_KAKAO_JS_KEY})" docker build \ --build-arg EXPO_PUBLIC_API_BASE=https://api.insurance.junggomoa.com \ --build-arg EXPO_PUBLIC_KAKAO_JS_KEY="${EXPO_PUBLIC_KAKAO_JS_KEY:-}" \ @@ -46,10 +52,6 @@ docker push localhost:5000/insurance/api:latest echo "[*] Applying Kubernetes manifests" kubectl apply -f deploy/k8s/namespace.yaml -SECRETS_FILE=/home/chpark/.insurance-secrets -if [ -r "$SECRETS_FILE" ]; then - set -a; source "$SECRETS_FILE"; set +a -fi POSTGRES_PASSWORD="${POSTGRES_PASSWORD:-$(openssl rand -hex 24)}" JWT_SECRET="${JWT_SECRET:-$(openssl rand -hex 32)}"