Skip to content

Commit

Permalink
Update main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
bkona-alopa authored Oct 10, 2024
1 parent 0e3b038 commit d904747
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,36 @@ on:
options:
- DEV
- TEST
env:
#
DEV: "['DEVAP-in']"
TEST: "['DCPRODEU-it','DCPRODEU-fr','DCPRODEU-dk','DCPRODEU-fi','DCPRODEU-ch']"

permissions:
id-token: write
contents: read
deployments: write

jobs:
Getting-Countries:
name: Getting Countries in ${{ inputs.deployment_region }}
runs-on: ubuntu-latest
timeout-minutes: 10
permissions:
contents: read
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}

steps:
- id: set-matrix
run: echo "matrix=${{ env[format('{0}',inputs.environment)] }}" >> $GITHUB_OUTPUT

call-workflow-in-local-repo-DEV:
if: ${{ inputs.environment == 'DEV' }}
strategy:
matrix:
env_supported:
[DEV, DEVEU]
${{ fromJson(needs.Getting-Countries.outputs.matrix) }}
uses: ./.github/workflows/deploy.yml
with:
deployment_environment: ${{ matrix.env_supported }}
Expand All @@ -29,7 +46,7 @@ jobs:
strategy:
matrix:
env_supported:
[TEST, TESTEU]
${{ fromJson(needs.Getting-Countries.outputs.matrix) }}
uses: ./.github/workflows/deploy.yml
with:
deployment_environment: ${{ matrix.env_supported }}
Expand Down

0 comments on commit d904747

Please sign in to comment.