Skip to content

Commit ba15af7

Browse files
committed
build ENV_CONTENT first, then append RELAY_AUTH_BLOCK only when present, keeps the .env block cleaner and avoids inserting optional auth vars into the main env list, preserves alphabetical / logical ordering of the env vars in the generated content
1 parent 45887b2 commit ba15af7

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

scripts/bash/deploy_arc_ring.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,11 @@ PACS_PORT=11112
9797
PACS_STORAGE_PATH=${BASE_PATH}/data/storage
9898
PACS_DB_PATH=${BASE_PATH}/data/pacs.db
9999
LOG_LEVEL=INFO
100-
${RELAY_AUTH_BLOCK}SAMPLE_IMAGES_PATH=${BASE_PATH}/current/sample_images"
100+
SAMPLE_IMAGES_PATH=${BASE_PATH}/current/sample_images"
101+
102+
if [[ -n "${RELAY_AUTH_BLOCK}" ]]; then
103+
ENV_CONTENT="${ENV_CONTENT}${RELAY_AUTH_BLOCK}"
104+
fi
101105

102106
# Cross-platform base64 encoding (works on macOS and Linux)
103107
ENV_CONTENT_B64=$(printf '%s' "$ENV_CONTENT" | base64 | tr -d '\n')

0 commit comments

Comments
 (0)