From 77baa9bdf6bc2e01c4996deba9f9746bf71bff8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Bournhonesque?= Date: Wed, 17 Apr 2024 13:55:57 +0200 Subject: [PATCH] chore: pass OFF_TLD envvar to docker compose --- .github/workflows/container-deploy.yml | 3 +++ docker-compose.yml | 1 + 2 files changed, 4 insertions(+) diff --git a/.github/workflows/container-deploy.yml b/.github/workflows/container-deploy.yml index 6f47d14..ed770fe 100644 --- a/.github/workflows/container-deploy.yml +++ b/.github/workflows/container-deploy.yml @@ -35,11 +35,13 @@ jobs: run: | echo "SSH_HOST=10.1.0.200" >> $GITHUB_ENV echo "ENVIRONMENT=staging" >> $GITHUB_ENV + echo "OFF_TLD=net" >> $GITHUB_ENV - name: Set various variable for staging (org) deployment if: matrix.env == 'nutripatrol-org' run: | echo "SSH_HOST=10.1.0.201" >> $GITHUB_ENV echo "ENVIRONMENT=prod" >> $GITHUB_ENV + echo "OFF_TLD=org" >> $GITHUB_ENV - name: Wait for docker image container build workflow uses: tomchv/wait-my-workflow@v1.1.0 id: wait-build @@ -113,6 +115,7 @@ jobs: echo "RESTART_POLICY=always" >> .env echo "SENTRY_DNS=${{ secrets.SENTRY_DSN }}" >> .env echo "ENVIRONMENT=${{ env.ENVIRONMENT }}" >> .env + echo "OFF_TLD=${{ env.OFF_TLD }}" >> .env # Expose API on port 9010 echo "API_EXPOSE=0.0.0.0:9010" >> .env echo 'CORS_ALLOW_ORIGINS=["https://nutripatrol.openfoodfacts.net", "https://nutripatrol.openfoodfacts.org"]' >> .env diff --git a/docker-compose.yml b/docker-compose.yml index c6f1eb1..fe09dc2 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -11,6 +11,7 @@ x-api-common: &api-common - POSTGRES_DB - POSTGRES_HOST - CORS_ALLOW_ORIGINS + - OFF_TLD networks: - default