From a3bc0846ecb895f9f94473b60c9b012370e8a270 Mon Sep 17 00:00:00 2001 From: Ivan Golikov Date: Wed, 31 Jan 2024 13:17:36 +0100 Subject: [PATCH] Load environment variables by reading .env.dist file Copying .env.dist to .env will cause complexities with overriding settings when using the resulting Docker image --- .github/workflows/.release-workflow-rc.yml | 6 ++++-- .github/workflows/.release-workflow.yml | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/.release-workflow-rc.yml b/.github/workflows/.release-workflow-rc.yml index 7635bb21..0fceeb4c 100644 --- a/.github/workflows/.release-workflow-rc.yml +++ b/.github/workflows/.release-workflow-rc.yml @@ -24,8 +24,10 @@ jobs: uses: actions/checkout@v3 with: submodules: true - - name: Use default environment settings - run: cp .env.dist .env + - name: Load default environment variables values + uses: cardinalby/export-env-action@v2 + with: + envFile: '.env.dist' - name: Build run: docker compose -f docker-compose.dev.yaml up -d - name: Lint and Test diff --git a/.github/workflows/.release-workflow.yml b/.github/workflows/.release-workflow.yml index 73333079..bcd6124a 100644 --- a/.github/workflows/.release-workflow.yml +++ b/.github/workflows/.release-workflow.yml @@ -40,8 +40,10 @@ jobs: with: commit_message: increment version branch: develop - - name: Use default environment settings - run: cp .env.dist .env + - name: Load default environment variables values + uses: cardinalby/export-env-action@v2 + with: + envFile: '.env.dist' - name: Build run: docker compose -f docker-compose.dev.yaml up -d - name: Lint and Test