diff --git a/scripts/deploy/deploy-node.sh b/scripts/deploy/deploy-node.sh index 69df10c..c76e143 100755 --- a/scripts/deploy/deploy-node.sh +++ b/scripts/deploy/deploy-node.sh @@ -120,7 +120,18 @@ for service in "${SERVICES[@]}"; do COMPOSE_CMD="${COMPOSE_CMD} --env-file ${ENV_FILE}" fi - $COMPOSE_CMD up -d --remove-orphans + # Services with their own Dockerfile need a rebuild on every deploy — + # otherwise `up -d` sees "container running, image tag unchanged" and skips + # rebuilding even when src/ changed, silently leaving the old code running + # (backlog c858dbc). Services with a prebuilt image (no Dockerfile) don't + # need --build. + if [ -f "${REPO_PATH}/services/${service}/Dockerfile" ]; then + echo "Building ${service} (has Dockerfile)" + $COMPOSE_CMD up -d --build --remove-orphans + else + echo "Using prebuilt image for ${service}" + $COMPOSE_CMD up -d --remove-orphans + fi done echo "--- Deployment Complete ---"