From 4f49fad7f9bcd5931cd8007be2e19c7bf47019a9 Mon Sep 17 00:00:00 2001 From: justin Date: Fri, 5 Jun 2026 18:41:09 -0500 Subject: [PATCH] deploy: bring up the healthcare proxy-relay sidecar on prod and dev deploy.sh: include proxy-relay in the default service set; it's an upstream image (ginuerzh/gost) with no build context, so exclude it from 'compose build' while keeping it in 'compose up'. deploy-dev.sh: rsync docker-compose.yml to the dev server (it was never synced, so new services like proxy-relay never reached dev) and add proxy-relay to the 'compose up --build' set. --- deploy.sh | 8 ++++++-- scripts/deploy-dev.sh | 9 ++++++++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/deploy.sh b/deploy.sh index 76e1bd7..c2eac79 100755 --- a/deploy.sh +++ b/deploy.sh @@ -8,7 +8,11 @@ set -euo pipefail cd /opt/performancewest -SERVICES="${@:-site api workers}" +SERVICES="${@:-site api workers proxy-relay}" + +# proxy-relay is an upstream image (no build context). Build everything else, +# but always include it in the `up` set so the healthcare proxy sidecar runs. +BUILD_SERVICES="$(echo "$SERVICES" | tr ' ' '\n' | grep -v '^proxy-relay$' | tr '\n' ' ')" echo "=== Pulling latest from git ===" git pull origin main @@ -30,7 +34,7 @@ echo "=== Building: $SERVICES ===" case " $SERVICES " in *" erpnext "*) echo "--- staging custom Frappe apps ---"; bash erpnext/build.sh ;; esac -docker compose build $SERVICES +[ -n "${BUILD_SERVICES// }" ] && docker compose build $BUILD_SERVICES echo "" echo "=== Restarting: $SERVICES ===" diff --git a/scripts/deploy-dev.sh b/scripts/deploy-dev.sh index eb5540a..77bea38 100755 --- a/scripts/deploy-dev.sh +++ b/scripts/deploy-dev.sh @@ -55,10 +55,17 @@ for f in site/Dockerfile site/nginx.conf site/package.json site/astro.config.mjs fi done +# Keep the dev compose file in sync with git so service changes (e.g. the +# healthcare proxy-relay sidecar) actually reach dev. The .env is server-managed +# and not overwritten. +rsync -avz -e "$SSH" docker-compose.yml "$REMOTE:$DEV_DIR/docker-compose.yml" + echo "" echo "=== Rebuilding containers ===" -$SSH "$REMOTE" "cd $DEV_DIR && sudo docker compose up -d --build api site workers" +# proxy-relay is an upstream image (no build context); `up --build` skips the +# build for it but still (re)creates it from the compose definition. +$SSH "$REMOTE" "cd $DEV_DIR && sudo docker compose up -d --build api site workers proxy-relay" echo "" echo "=== Deploy complete ==="