Skip to content

Commit

Permalink
Use json.dumps to render deployment params that are to be put as envi…
Browse files Browse the repository at this point in the history
…ronment variables
  • Loading branch information
ricardogsilva committed Dec 6, 2024
1 parent f214fd0 commit 8f4c476
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion deployments/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def handle(self) -> None:

render_context = dataclasses.asdict(self.config)
render_kwargs = {}
# conf keys that have _env_ in their name are going to be put as env values
# conf keys that have 'env_' in their name are going to be put as env values
# inside the container and will be consumed by pydantic. If one of these is
# a list we dump it as JSON in order to ensure correct handling of
# parameters that represent collections, for example cors origins, which
Expand Down
4 changes: 2 additions & 2 deletions docker/compose.production.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ services:
ARPAV_PPCV__ADMIN_USER__USERNAME: "${webapp_env_admin_user_username}"
ARPAV_PPCV__ADMIN_USER__PASSWORD: "${webapp_env_admin_user_password}"
ARPAV_PPCV__THREDDS_SERVER__BASE_URL: "${webapp_env_thredds_server_base_url}"
ARPAV_PPCV__CORS_ORIGINS: "${webapp_env_cors_origins}"
ARPAV_PPCV__CORS_METHODS: "${webapp_env_cors_methods}"
ARPAV_PPCV__CORS_ORIGINS: '${webapp_env_cors_origins}'
ARPAV_PPCV__CORS_METHODS: '${webapp_env_cors_methods}'
ARPAV_PPCV__ALLOW_CORS_CREDENTIALS: "${webapp_env_allow_cors_credentials}"
labels:
- "traefik.http.routers.arpav-backend.entrypoints=web"
Expand Down

0 comments on commit 8f4c476

Please sign in to comment.