Co-authored-by: Han Kyaw <hankyaw@Hans-MBP.lan>tags/0.15.0
| @@ -374,7 +374,6 @@ x-shared-env: &shared-api-worker-env | |||
| SSRF_COREDUMP_DIR: ${SSRF_COREDUMP_DIR:-/var/spool/squid} | |||
| SSRF_REVERSE_PROXY_PORT: ${SSRF_REVERSE_PROXY_PORT:-8194} | |||
| SSRF_SANDBOX_HOST: ${SSRF_SANDBOX_HOST:-sandbox} | |||
| COMPOSE_PROFILES: ${COMPOSE_PROFILES:-${VECTOR_STORE:-weaviate}} | |||
| EXPOSE_NGINX_PORT: ${EXPOSE_NGINX_PORT:-80} | |||
| EXPOSE_NGINX_SSL_PORT: ${EXPOSE_NGINX_SSL_PORT:-443} | |||
| POSITION_TOOL_PINS: ${POSITION_TOOL_PINS:-} | |||
| @@ -37,6 +37,8 @@ def generate_shared_env_block(env_vars, anchor_name="shared-api-worker-env"): | |||
| """ | |||
| lines = [f"x-shared-env: &{anchor_name}"] | |||
| for key, default in env_vars.items(): | |||
| if key == "COMPOSE_PROFILES": | |||
| continue | |||
| # If default value is empty, use ${KEY:-} | |||
| if default == "": | |||
| lines.append(f" {key}: ${{{key}:-}}") | |||