From 579e9caffb927139ca36ead923ef40d0f82897dc Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 10 Jan 2024 12:22:43 -0500 Subject: [PATCH 01/64] Update ci.yml --- .github/workflows/ci.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 45ffa66..7ea135b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,6 +36,21 @@ jobs: - name: Echo Changed Files Output run: echo "${{ toJSON(needs.get-changed-files.outputs.changed-files) }}" + azure-login: + name: Azure Login + runs-on: ubuntu-latest + steps: + - name: Set up Azure credentials + run: | + echo "Logging into Azure..." + az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} + az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} + env: + AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} + AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }} + AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} + pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main From 527adb99dd51f8db56f09c4408801cd91509e859 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 10 Jan 2024 12:53:01 -0500 Subject: [PATCH 02/64] Update ci.yml --- .github/workflows/ci.yml | 38 ++++++++++++++++++++++++++------------ 1 file changed, 26 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7ea135b..036f4d2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,21 +36,35 @@ jobs: - name: Echo Changed Files Output run: echo "${{ toJSON(needs.get-changed-files.outputs.changed-files) }}" + #azure-login: + # name: Azure Login + #runs-on: ubuntu-latest + #steps: + # - name: Set up Azure credentials + # run: | + # echo "Logging into Azure..." + # az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} + # az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} + #env: + # AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} + #AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + #AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }} + #AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} azure-login: - name: Azure Login runs-on: ubuntu-latest steps: - - name: Set up Azure credentials - run: | - echo "Logging into Azure..." - az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} - az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} - env: - AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} - AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} - AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }} - AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} - + - name: 'Az CLI login' + uses: azure/login@v1 + with: + client-id: ${{ secrets.AZURE_CLIENT_ID }} + tenant-id: ${{ secrets.AZURE_TENANT_ID }} + subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }} + + - name: 'Run Azure CLI commands' + run: | + az account show + az group list + pwd pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main From 0e7bc60d2e3d6d0c610c6eee185ac90fda3a3062 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 10 Jan 2024 13:20:31 -0500 Subject: [PATCH 03/64] Update ci.yml --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 036f4d2..ea64bff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,9 @@ on: required: false TEST_PYPI_API_TOKEN: required: false - +permissions: + id-token: write + contents: read jobs: get-changed-files: From 524d1dd26a37e3220f9caa38549ef228a55650f0 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 10 Jan 2024 13:26:41 -0500 Subject: [PATCH 04/64] Update ci.yml --- .github/workflows/ci.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ea64bff..420ab7d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,14 +14,15 @@ on: version: required: false type: string + permissions: + id-token: write + contents: read secrets: PYPI_API_TOKEN: required: false TEST_PYPI_API_TOKEN: required: false -permissions: - id-token: write - contents: read + jobs: get-changed-files: From 58fceed91fa726878d99903914741923df3b7ecd Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 10 Jan 2024 13:27:47 -0500 Subject: [PATCH 05/64] Update ci.yml --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 420ab7d..5bc7819 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,9 +14,6 @@ on: version: required: false type: string - permissions: - id-token: write - contents: read secrets: PYPI_API_TOKEN: required: false @@ -55,6 +52,9 @@ jobs: #AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} azure-login: runs-on: ubuntu-latest + permissions: + id-token: write + contents: read steps: - name: 'Az CLI login' uses: azure/login@v1 From 6dd4af9e4a998dd5ffe5e1a81723f8b432432a2b Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 17:58:27 -0500 Subject: [PATCH 06/64] Update ci.yml --- .github/workflows/ci.yml | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5bc7819..f4f1e39 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,17 +52,12 @@ jobs: #AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} azure-login: runs-on: ubuntu-latest - permissions: - id-token: write - contents: read steps: - name: 'Az CLI login' uses: azure/login@v1 with: - client-id: ${{ secrets.AZURE_CLIENT_ID }} - tenant-id: ${{ secrets.AZURE_TENANT_ID }} - subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }} - + creds: ${{ secrets.AZURE_CREDENTIALS }} + - name: 'Run Azure CLI commands' run: | az account show From 2ea4fc1c10d944df2d9f7692ccdafab6ee4489b8 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:09:51 -0500 Subject: [PATCH 07/64] Update ci.yml --- .github/workflows/ci.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f4f1e39..23b541e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,11 +58,12 @@ jobs: with: creds: ${{ secrets.AZURE_CREDENTIALS }} - - name: 'Run Azure CLI commands' - run: | + - name: Azure CLI script + uses: azure/CLI@v1 + with: + azcliversion: latest + inlineScript: | az account show - az group list - pwd pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main From 2ecfdbcc3d8e148e75338743cae6a3e654c40e79 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:15:20 -0500 Subject: [PATCH 08/64] Update ci.yml --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 23b541e..e8c0dfe 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,7 +54,7 @@ jobs: runs-on: ubuntu-latest steps: - name: 'Az CLI login' - uses: azure/login@v1 + uses: azure/login@v1.5.1 with: creds: ${{ secrets.AZURE_CREDENTIALS }} From 0a74c99224151b29c82ad5e3d45bf68c9be34b6e Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:24:30 -0500 Subject: [PATCH 09/64] Update ci.yml --- .github/workflows/ci.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e8c0dfe..b9e8aeb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -50,6 +50,19 @@ jobs: #AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} #AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }} #AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} + + check-az-cli: + runs-on: ubuntu-latest + steps: + - name: Check if Azure CLI is installed + run: | + if ! command -v az &> /dev/null; then + echo "Azure CLI is not installed." + exit 1 + fi + + az --version + azure-login: runs-on: ubuntu-latest steps: From d5da0748b84d46bf7141bf45329e8d2b2b791ed7 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:47:52 -0500 Subject: [PATCH 10/64] Update ci.yml --- .github/workflows/ci.yml | 47 ++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 26 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b9e8aeb..a26368a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,34 +36,29 @@ jobs: - name: Echo Changed Files Output run: echo "${{ toJSON(needs.get-changed-files.outputs.changed-files) }}" - #azure-login: - # name: Azure Login - #runs-on: ubuntu-latest - #steps: - # - name: Set up Azure credentials - # run: | - # echo "Logging into Azure..." - # az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} - # az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} - #env: - # AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} - #AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} - #AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }} - #AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} - - check-az-cli: - runs-on: ubuntu-latest - steps: - - name: Check if Azure CLI is installed - run: | - if ! command -v az &> /dev/null; then - echo "Azure CLI is not installed." - exit 1 - fi + azure-login: + name: Azure Login + runs-on: ubuntu-latest + steps: + - name: Set up Azure credentials + run: | + echo "Logging into Azure..." + az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} + az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} + + # check-az-cli: + # runs-on: ubuntu-latest + # steps: + # - name: Check if Azure CLI is installed + # run: | + # if ! command -v az &> /dev/null; then + # echo "Azure CLI is not installed." + # exit 1 + # fi - az --version + # az --version - azure-login: + azure-login2: runs-on: ubuntu-latest steps: - name: 'Az CLI login' From 8c577a797fbdb6e1774648c6bce538ff321d5d7e Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:50:15 -0500 Subject: [PATCH 11/64] Update ci.yml --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a26368a..fede5c2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -62,9 +62,9 @@ jobs: runs-on: ubuntu-latest steps: - name: 'Az CLI login' - uses: azure/login@v1.5.1 + uses: Azure/login@v1 with: - creds: ${{ secrets.AZURE_CREDENTIALS }} + creds: '{"clientId":"${{ secrets.AZURE_CLIENT_ID }}","clientSecret":"${{ secrets.AZURE_CLIENT_SECRET }}","subscriptionId":"${{ secrets.AZURE_SUBSCRIPTION_ID }}","tenantId":"${{ secrets.AZURE_TENANT_ID }}"}' - name: Azure CLI script uses: azure/CLI@v1 From 3f633d908fdfc63f17de9ecaf77401d1a61ffdf1 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Thu, 11 Jan 2024 18:55:44 -0500 Subject: [PATCH 12/64] Update ci.yml --- .github/workflows/ci.yml | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fede5c2..b3a5d72 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,20 +58,27 @@ jobs: # az --version + test-secret: + runs-on: ubuntu-latest + steps: + - name: 'test secrets' + run: | + echo "AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}" + azure-login2: runs-on: ubuntu-latest steps: - - name: 'Az CLI login' - uses: Azure/login@v1 - with: - creds: '{"clientId":"${{ secrets.AZURE_CLIENT_ID }}","clientSecret":"${{ secrets.AZURE_CLIENT_SECRET }}","subscriptionId":"${{ secrets.AZURE_SUBSCRIPTION_ID }}","tenantId":"${{ secrets.AZURE_TENANT_ID }}"}' + - name: 'Az CLI login' + uses: Azure/login@v1 + with: + creds: '{"clientId":"${{ secrets.AZURE_CLIENT_ID }}","clientSecret":"${{ secrets.AZURE_CLIENT_SECRET }}","subscriptionId":"${{ secrets.AZURE_SUBSCRIPTION_ID }}","tenantId":"${{ secrets.AZURE_TENANT_ID }}"}' - - name: Azure CLI script - uses: azure/CLI@v1 - with: - azcliversion: latest - inlineScript: | - az account show + - name: Azure CLI script + uses: azure/CLI@v1 + with: + azcliversion: latest + inlineScript: | + az account show pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main From 7f6acd32bb5baa6c3e432cd09c7ad2ba3ad988b5 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 12 Jan 2024 12:55:34 -0500 Subject: [PATCH 13/64] Update ci.yml --- .github/workflows/ci.yml | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b3a5d72..938bc3f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,25 +45,6 @@ jobs: echo "Logging into Azure..." az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} - - # check-az-cli: - # runs-on: ubuntu-latest - # steps: - # - name: Check if Azure CLI is installed - # run: | - # if ! command -v az &> /dev/null; then - # echo "Azure CLI is not installed." - # exit 1 - # fi - - # az --version - - test-secret: - runs-on: ubuntu-latest - steps: - - name: 'test secrets' - run: | - echo "AZURE_SUBSCRIPTION_ID: ${{ secrets.AZURE_SUBSCRIPTION_ID }}" azure-login2: runs-on: ubuntu-latest From 06d7665a83d6d4b7d7a1874e82ff183927b8394e Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 12 Mar 2024 18:54:30 +0000 Subject: [PATCH 14/64] Set GitHub Secrets of Azure credentials to env vars --- .github/workflows/ci.yml | 52 +++++++++++++++++++++------------------- 1 file changed, 28 insertions(+), 24 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 938bc3f..cffb198 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,5 +1,4 @@ name: CI - on: workflow_call: inputs: @@ -20,7 +19,6 @@ on: TEST_PYPI_API_TOKEN: required: false - jobs: get-changed-files: name: Get Changed Files @@ -36,45 +34,52 @@ jobs: - name: Echo Changed Files Output run: echo "${{ toJSON(needs.get-changed-files.outputs.changed-files) }}" - azure-login: - name: Azure Login - runs-on: ubuntu-latest - steps: - - name: Set up Azure credentials - run: | - echo "Logging into Azure..." - az login --service-principal -u ${{ secrets.AZURE_CLIENT_ID }} -p ${{ secrets.AZURE_CLIENT_SECRET }} --tenant ${{ secrets.AZURE_TENANT_ID }} - az account set --subscription ${{ secrets.AZURE_SUBSCRIPTION_ID }} - - azure-login2: + credentials: runs-on: ubuntu-latest + permissions: + id-token: write + contents: read + outputs: + CREDENTIAL1: ${{ steps.credentials.outputs.CREDENTIAL1 }} + CREDENTIAL2: ${{ steps.credentials.outputs.CREDENTIAL2 }} + CREDENTIAL3: ${{ steps.credentials.outputs.CREDENTIAL3 }} steps: - - name: 'Az CLI login' - uses: Azure/login@v1 - with: - creds: '{"clientId":"${{ secrets.AZURE_CLIENT_ID }}","clientSecret":"${{ secrets.AZURE_CLIENT_SECRET }}","subscriptionId":"${{ secrets.AZURE_SUBSCRIPTION_ID }}","tenantId":"${{ secrets.AZURE_TENANT_ID }}"}' + - name: Output encoded credentials + id: credentials + env: + CREDENTIAL1: ${{ secrets.AZURE_CLIENT_ID }} + CREDENTIAL2: ${{ secrets.AZURE_CLIENT_SECRET }} + CREDENTIAL3: ${{ secrets.AZURE_TENANT_ID }} + run: | + echo "CREDENTIAL1=$(echo $CREDENTIAL1 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + echo "CREDENTIAL2=$(echo $CREDENTIAL2 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + echo "CREDENTIAL3=$(echo $CREDENTIAL3 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - - name: Azure CLI script - uses: azure/CLI@v1 - with: - azcliversion: latest - inlineScript: | - az account show pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main needs: - get-changed-files + - credentials with: changed-files: ${{ needs.get-changed-files.outputs.changed-files }} test: name: Test + permissions: + id-token: write + contents: read needs: - pre-commit + - credentials uses: salt-extensions/central-artifacts/.github/workflows/test-action.yml@main with: setup-vault: ${{ inputs.setup-vault }} + secrets: + env_vars: | + CREDENTIAL1=${{ needs.credentials.outputs.CREDENTIAL1 }} + CREDENTIAL2=${{ needs.credentials.outputs.CREDENTIAL2 }} + CREDENTIAL3=${{ needs.credentials.outputs.CREDENTIAL3 }} docs: name: Docs @@ -145,7 +150,6 @@ jobs: run: | tree exitstatus grep -RE 'failure|cancelled' exitstatus/ && exit 1 || exit 0 - - name: Done if: always() run: From 39aa7d5c6e94a5645d75a1e2b335db9b56586ee3 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 13 Mar 2024 21:33:01 +0000 Subject: [PATCH 15/64] update pr.yml --- .github/workflows/ci.yml | 27 +++++++-------------------- 1 file changed, 7 insertions(+), 20 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cffb198..7c7f16a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,20 +40,9 @@ jobs: id-token: write contents: read outputs: - CREDENTIAL1: ${{ steps.credentials.outputs.CREDENTIAL1 }} - CREDENTIAL2: ${{ steps.credentials.outputs.CREDENTIAL2 }} - CREDENTIAL3: ${{ steps.credentials.outputs.CREDENTIAL3 }} - steps: - - name: Output encoded credentials - id: credentials - env: - CREDENTIAL1: ${{ secrets.AZURE_CLIENT_ID }} - CREDENTIAL2: ${{ secrets.AZURE_CLIENT_SECRET }} - CREDENTIAL3: ${{ secrets.AZURE_TENANT_ID }} - run: | - echo "CREDENTIAL1=$(echo $CREDENTIAL1 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - echo "CREDENTIAL2=$(echo $CREDENTIAL2 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - echo "CREDENTIAL3=$(echo $CREDENTIAL3 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} + AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} + AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} pre-commit: name: Pre-Commit @@ -75,12 +64,10 @@ jobs: uses: salt-extensions/central-artifacts/.github/workflows/test-action.yml@main with: setup-vault: ${{ inputs.setup-vault }} - secrets: - env_vars: | - CREDENTIAL1=${{ needs.credentials.outputs.CREDENTIAL1 }} - CREDENTIAL2=${{ needs.credentials.outputs.CREDENTIAL2 }} - CREDENTIAL3=${{ needs.credentials.outputs.CREDENTIAL3 }} - + env: + AZURE_CLIENT_ID: ${{ needs.credentials.outputs.AZURE_CLIENT_ID }} + AZURE_CLIENT_SECRET: ${{ needs.credentials.outputs.AZURE_CLIENT_SECRET }} + AZURE_TENANT_ID: ${{ needs.credentials.outputs.AZURE_TENANT_ID }} docs: name: Docs needs: From d4d091c82eca11429733158202f5fe3df4609302 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 13 Mar 2024 21:47:16 +0000 Subject: [PATCH 16/64] update pr.yml --- .github/workflows/ci.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7c7f16a..d04eb92 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,6 +43,18 @@ jobs: AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + steps: + - name: Output encoded credentials + id: credentials + env: + CREDENTIAL1: ${{ secrets.AZURE_CLIENT_ID }} + CREDENTIAL2: ${{ secrets.AZURE_CLIENT_SECRET }} + CREDENTIAL3: ${{ secrets.AZURE_TENANT_ID }} + run: | + echo "CREDENTIAL1=$(echo $CREDENTIAL1 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + echo "CREDENTIAL2=$(echo $CREDENTIAL2 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + echo "CREDENTIAL3=$(echo $CREDENTIAL3 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT + pre-commit: name: Pre-Commit From 68e5576eea2aedd2e637fc63bf643af04ea9182d Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 13 Mar 2024 22:07:16 +0000 Subject: [PATCH 17/64] update ci.yml --- .github/workflows/ci.yml | 47 +++++++++++++--------------------------- 1 file changed, 15 insertions(+), 32 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d04eb92..1263b07 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,4 +1,5 @@ name: CI + on: workflow_call: inputs: @@ -18,6 +19,13 @@ on: required: false TEST_PYPI_API_TOKEN: required: false + AZURE_CLIENT_ID: + required: false + AZURE_TENANT_ID: + required: false + AZURE_CLIENT_SECRET: + required: false + jobs: get-changed-files: @@ -34,52 +42,26 @@ jobs: - name: Echo Changed Files Output run: echo "${{ toJSON(needs.get-changed-files.outputs.changed-files) }}" - credentials: - runs-on: ubuntu-latest - permissions: - id-token: write - contents: read - outputs: - AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} - AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} - AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} - steps: - - name: Output encoded credentials - id: credentials - env: - CREDENTIAL1: ${{ secrets.AZURE_CLIENT_ID }} - CREDENTIAL2: ${{ secrets.AZURE_CLIENT_SECRET }} - CREDENTIAL3: ${{ secrets.AZURE_TENANT_ID }} - run: | - echo "CREDENTIAL1=$(echo $CREDENTIAL1 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - echo "CREDENTIAL2=$(echo $CREDENTIAL2 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - echo "CREDENTIAL3=$(echo $CREDENTIAL3 | base64 -w0 | base64 -w0)" >> $GITHUB_OUTPUT - - pre-commit: name: Pre-Commit uses: salt-extensions/central-artifacts/.github/workflows/pre-commit-action.yml@main needs: - get-changed-files - - credentials with: changed-files: ${{ needs.get-changed-files.outputs.changed-files }} test: name: Test - permissions: - id-token: write - contents: read needs: - pre-commit - - credentials uses: salt-extensions/central-artifacts/.github/workflows/test-action.yml@main with: setup-vault: ${{ inputs.setup-vault }} - env: - AZURE_CLIENT_ID: ${{ needs.credentials.outputs.AZURE_CLIENT_ID }} - AZURE_CLIENT_SECRET: ${{ needs.credentials.outputs.AZURE_CLIENT_SECRET }} - AZURE_TENANT_ID: ${{ needs.credentials.outputs.AZURE_TENANT_ID }} + secrets: + AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} + AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} + AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + docs: name: Docs needs: @@ -149,7 +131,8 @@ jobs: run: | tree exitstatus grep -RE 'failure|cancelled' exitstatus/ && exit 1 || exit 0 + - name: Done if: always() run: - echo "All workflows finished" + echo "All workflows finished" \ No newline at end of file From ad1d7401a949ff66d4e49db5e21f381d89678f72 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Wed, 13 Mar 2024 22:44:38 +0000 Subject: [PATCH 18/64] reverting --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1263b07..2ccd290 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -135,4 +135,6 @@ jobs: - name: Done if: always() run: - echo "All workflows finished" \ No newline at end of file + echo "All workflows finished" + + #### \ No newline at end of file From cf3289932e35cc9bcfe5a240e2c2e6fe37837244 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 19:50:03 +0000 Subject: [PATCH 19/64] testing env vars --- .github/workflows/ci.yml | 22 +++++----------------- .github/workflows/test-action.yml | 29 +++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2ccd290..21a4b4f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,17 +14,7 @@ on: version: required: false type: string - secrets: - PYPI_API_TOKEN: - required: false - TEST_PYPI_API_TOKEN: - required: false - AZURE_CLIENT_ID: - required: false - AZURE_TENANT_ID: - required: false - AZURE_CLIENT_SECRET: - required: false + secrets: ${{ toJson(secrets) }} jobs: @@ -54,13 +44,11 @@ jobs: name: Test needs: - pre-commit - uses: salt-extensions/central-artifacts/.github/workflows/test-action.yml@main + # uses: salt-extensions/central-artifacts/.github/workflows/test-action.yml@main + uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - secrets: - AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }} - AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }} - AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }} + secrets: ${{ toJson(secrets) }} docs: name: Docs @@ -137,4 +125,4 @@ jobs: run: echo "All workflows finished" - #### \ No newline at end of file + #### diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 0994dd6..a85bde7 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,6 +7,9 @@ on: required: false type: boolean default: false + secrets: + env_vars: + required: true jobs: Linux: @@ -29,6 +32,22 @@ jobs: steps: - uses: actions/checkout@v4 + - name: Decode credentials as env vars + env: + env_vars: ${{ secrets.env_vars }} + run: | + for i in $env_vars; do + i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) + echo ::add-mask::${i#*=} + printf '%s\n' "$i" >> $GITHUB_ENV + done + + - name: Validate credentials + run: | + # Secrets are now available as masked env vars + echo $CREDENTIAL1 + echo $CREDENTIAL2 + echo $CREDENTIAL3 - name: Setup Vault if: ${{ inputs.setup-vault }} @@ -52,11 +71,21 @@ jobs: run: | nox --force-color -e tests-3 --install-only + - name: Test env vars + env: + env_vars: ${{ toJson(secrets.env_vars )}} + run: | + for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do + key=$(echo $secret | cut -d "=" -f 1) + value=$(echo $secret | cut -d "=" -f 2 | base64 -d) + echo "export $key=\"$value\"" >> $GITHUB_ENV + done - name: Test env: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | + echo $AZURE_CLIENT_ID nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 95d48e2c57dd38f0d4099d1b70cc46f2d51a4801 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 20:00:49 +0000 Subject: [PATCH 20/64] testing env vars --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 21a4b4f..25e7d07 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,9 @@ on: version: required: false type: string - secrets: ${{ toJson(secrets) }} + secrets: + env_vars: + required: false jobs: From 1b4f4bbd1835a2cc3e32cfd03c9abca2698fab5a Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 20:19:47 +0000 Subject: [PATCH 21/64] testing env vars --- .github/workflows/ci.yml | 6 ++---- .github/workflows/test-action.yml | 3 --- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 25e7d07..f0f2bda 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,9 +14,7 @@ on: version: required: false type: string - secrets: - env_vars: - required: false + jobs: @@ -50,7 +48,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - secrets: ${{ toJson(secrets) }} + secrets: inherit docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index a85bde7..7d97cbe 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,6 @@ on: required: false type: boolean default: false - secrets: - env_vars: - required: true jobs: Linux: From 9409133eb59f88a373ba7494a73d4b64635dacca Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 20:23:56 +0000 Subject: [PATCH 22/64] testing env vars --- .github/workflows/test-action.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 7d97cbe..596ec57 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -41,10 +41,7 @@ jobs: - name: Validate credentials run: | - # Secrets are now available as masked env vars - echo $CREDENTIAL1 - echo $CREDENTIAL2 - echo $CREDENTIAL3 + echo $AZURE_CLIENT_ID - name: Setup Vault if: ${{ inputs.setup-vault }} From 6e8fdee22a94d7dfb976a758d7f12a81805ceb67 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 20:27:31 +0000 Subject: [PATCH 23/64] testing env vars --- .github/workflows/test-action.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 596ec57..1d0ef6b 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -68,12 +68,12 @@ jobs: - name: Test env vars env: env_vars: ${{ toJson(secrets.env_vars )}} - run: | - for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do - key=$(echo $secret | cut -d "=" -f 1) - value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_ENV - done + run: | + for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do + key=$(echo $secret | cut -d "=" -f 1) + value=$(echo $secret | cut -d "=" -f 2 | base64 -d) + echo "export $key=\"$value\"" >> $GITHUB_ENV + done - name: Test env: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} From 0f5e064779ab29af1ace22c69c3044f7136f7851 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 20:45:57 +0000 Subject: [PATCH 24/64] testing env vars --- .github/workflows/test-action.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 1d0ef6b..5c7e087 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -33,10 +33,14 @@ jobs: env: env_vars: ${{ secrets.env_vars }} run: | - for i in $env_vars; do - i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) - echo ::add-mask::${i#*=} - printf '%s\n' "$i" >> $GITHUB_ENV + if [ -z "$env_vars" ]; then + echo "No environment variables found" + exit 1 + fi + for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do + key=$(echo $secret | cut -d "=" -f 1) + value=$(echo $secret | cut -d "=" -f 2 | base64 -d) + echo "export $key=\"$value\"" >> $GITHUB_ENV done - name: Validate credentials From 8b9c57983fc0176239679cf414c724b68c8c73be Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 21:01:23 +0000 Subject: [PATCH 25/64] testing env vars --- .github/workflows/ci.yml | 4 ++++ .github/workflows/test-action.yml | 8 +++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f0f2bda..7f9a2b5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,6 +14,9 @@ on: version: required: false type: string + env_vars: + required: false + type: boolean @@ -48,6 +51,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} + env_vars: ${{ inputs.env_vars }} secrets: inherit docs: diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 5c7e087..4a3f8d3 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,6 +7,9 @@ on: required: false type: boolean default: false + env_vars: + required: false + type: boolean jobs: Linux: @@ -31,11 +34,10 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: - env_vars: ${{ secrets.env_vars }} + env_vars: ${{ inputs.env_vars }} run: | if [ -z "$env_vars" ]; then echo "No environment variables found" - exit 1 fi for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do key=$(echo $secret | cut -d "=" -f 1) @@ -71,7 +73,7 @@ jobs: - name: Test env vars env: - env_vars: ${{ toJson(secrets.env_vars )}} + env_vars: ${{ toJSON(secrets.env_vars )}} run: | for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do key=$(echo $secret | cut -d "=" -f 1) From 11665c4b4baac68a05d0c801544159aa4428bb0b Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 21:08:59 +0000 Subject: [PATCH 26/64] testing env vars --- .github/workflows/test-action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 4a3f8d3..1e5cd87 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -42,7 +42,7 @@ jobs: for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do key=$(echo $secret | cut -d "=" -f 1) value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_ENV + echo "export $key=\"$value\"" >> $GITHUB_OUTPUT done - name: Validate credentials @@ -78,7 +78,7 @@ jobs: for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do key=$(echo $secret | cut -d "=" -f 1) value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_ENV + echo "export $key=\"$value\"" >> $GITHUB_OUTPUT done - name: Test env: From 461408380fa61c510a22d377bd9e48d1ba32b2ec Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 21:19:17 +0000 Subject: [PATCH 27/64] testing env vars --- .github/workflows/ci.yml | 2 +- .github/workflows/test-action.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7f9a2b5..18a461e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,7 +51,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - env_vars: ${{ inputs.env_vars }} + env_vars: ${{ needs.test-action.outputs.env_vars }} secrets: inherit docs: diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 1e5cd87..c143573 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -9,7 +9,7 @@ on: default: false env_vars: required: false - type: boolean + type: string jobs: Linux: From 60f37a72e34d7b3ff7c1024f770277551c935ad0 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 21:56:41 +0000 Subject: [PATCH 28/64] testing env vars --- .github/workflows/ci.yml | 4 ++-- .github/workflows/test-action.yml | 17 +++++++---------- 2 files changed, 9 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 18a461e..73f931b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,9 +14,9 @@ on: version: required: false type: string + secrets: env_vars: - required: false - type: boolean + required: true diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index c143573..a27c71c 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,9 @@ on: required: false type: boolean default: false + secrets: env_vars: - required: false - type: string + required: true jobs: Linux: @@ -34,15 +34,12 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: - env_vars: ${{ inputs.env_vars }} + env_vars: ${{ secrets.env_vars }} run: | - if [ -z "$env_vars" ]; then - echo "No environment variables found" - fi - for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do - key=$(echo $secret | cut -d "=" -f 1) - value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_OUTPUT + for i in $env_vars; do + i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) + echo ::add-mask::${i#*=} + printf '%s\n' "$i" >> $GITHUB_ENV done - name: Validate credentials From 8696bdb07ddcc6def8938b1b5bb10f269d9badfe Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 22:02:19 +0000 Subject: [PATCH 29/64] testing env vars --- .github/workflows/ci.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 73f931b..08cff05 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,8 +51,6 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - env_vars: ${{ needs.test-action.outputs.env_vars }} - secrets: inherit docs: name: Docs From cbc968c23f8019b395a2f5c98690c8eb196be60a Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 22:11:38 +0000 Subject: [PATCH 30/64] testing env vars --- .github/workflows/ci.yml | 2 ++ .github/workflows/test-action.yml | 20 +++++++++++--------- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 08cff05..a3f3789 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,6 +51,8 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} + secrets: + env_vars: ${{ secrets.env_vars}} docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index a27c71c..14506d1 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -68,21 +68,23 @@ jobs: run: | nox --force-color -e tests-3 --install-only - - name: Test env vars - env: - env_vars: ${{ toJSON(secrets.env_vars )}} - run: | - for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do - key=$(echo $secret | cut -d "=" -f 1) - value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_OUTPUT - done + # - name: Test env vars + # env: + # env_vars: ${{ secrets.env_vars }} + # run: | + # for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do + # key=$(echo $secret | cut -d "=" -f 1) + # value=$(echo $secret | cut -d "=" -f 2 | base64 -d) + # echo "export $key=\"$value\"" >> $GITHUB_OUTPUT + # done - name: Test env: + env_vars: ${{ secrets.env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | echo $AZURE_CLIENT_ID + echo $env_vars nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From bcc0411ee8dbb632b3522c52b9026b84c15eae4f Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 23:00:57 +0000 Subject: [PATCH 31/64] testing env vars --- .github/workflows/ci.yml | 8 ++++---- .github/workflows/test-action.yml | 15 ++++++--------- 2 files changed, 10 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a3f3789..dbfc673 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,9 +14,10 @@ on: version: required: false type: string - secrets: env_vars: - required: true + required: false + type: string + @@ -51,8 +52,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - secrets: - env_vars: ${{ secrets.env_vars}} + env_vars: ${{ inputs.env_vars}} docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 14506d1..963d92e 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,9 @@ on: required: false type: boolean default: false - secrets: env_vars: - required: true + required: false + type: string jobs: Linux: @@ -33,13 +33,11 @@ jobs: steps: - uses: actions/checkout@v4 - name: Decode credentials as env vars - env: - env_vars: ${{ secrets.env_vars }} + if: ${{ inputs.env_vars }} run: | - for i in $env_vars; do - i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) - echo ::add-mask::${i#*=} - printf '%s\n' "$i" >> $GITHUB_ENV + for i in "${{ inputs.env_vars }}" + do + printf "%s\n" $i >> $GITHUB_ENV done - name: Validate credentials @@ -79,7 +77,6 @@ jobs: # done - name: Test env: - env_vars: ${{ secrets.env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | From 79a947da42a248d21a4efcdc486a1e4b6717a3aa Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 23:12:18 +0000 Subject: [PATCH 32/64] testing env vars --- .github/workflows/ci.yml | 7 +++---- .github/workflows/test-action.yml | 15 +++++++++------ 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dbfc673..a0894a6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,10 +14,9 @@ on: version: required: false type: string + secrets: env_vars: - required: false - type: string - + required: true @@ -52,7 +51,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - env_vars: ${{ inputs.env_vars}} + secrets: inherit docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 963d92e..14506d1 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,9 @@ on: required: false type: boolean default: false + secrets: env_vars: - required: false - type: string + required: true jobs: Linux: @@ -33,11 +33,13 @@ jobs: steps: - uses: actions/checkout@v4 - name: Decode credentials as env vars - if: ${{ inputs.env_vars }} + env: + env_vars: ${{ secrets.env_vars }} run: | - for i in "${{ inputs.env_vars }}" - do - printf "%s\n" $i >> $GITHUB_ENV + for i in $env_vars; do + i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) + echo ::add-mask::${i#*=} + printf '%s\n' "$i" >> $GITHUB_ENV done - name: Validate credentials @@ -77,6 +79,7 @@ jobs: # done - name: Test env: + env_vars: ${{ secrets.env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | From a4411e635119da3e241a15f84f81b418add723dd Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Fri, 15 Mar 2024 23:41:04 +0000 Subject: [PATCH 33/64] testing env vars --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0894a6..90f5277 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,6 +14,9 @@ on: version: required: false type: string + env_vars: + required: false + type: string secrets: env_vars: required: true From 04887ed29cad16a142b3d60b9c007e64e283fef5 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 15:03:15 +0000 Subject: [PATCH 34/64] testing env vars --- .github/workflows/ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 90f5277..db79762 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,9 +17,6 @@ on: env_vars: required: false type: string - secrets: - env_vars: - required: true @@ -54,6 +51,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} + env_vars: ${{ inputs.env_vars }} secrets: inherit docs: From cbd9ae958f4d318b49929885447876bd2ed94949 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 15:05:15 +0000 Subject: [PATCH 35/64] testing env vars --- .github/workflows/ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index db79762..d25f496 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,7 +51,6 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - env_vars: ${{ inputs.env_vars }} secrets: inherit docs: From 600b3b0b680fb5d6a641cdfe7b2dc0b5a9aeab1c Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 16:21:31 +0000 Subject: [PATCH 36/64] testing env vars --- .github/workflows/test-action.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 14506d1..68284fc 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,9 @@ on: required: false type: boolean default: false - secrets: env_vars: - required: true + required: false + type: string jobs: Linux: @@ -34,7 +34,7 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: - env_vars: ${{ secrets.env_vars }} + env_vars: ${{ inputs.env_vars }} run: | for i in $env_vars; do i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) From ffc23fed91ebf9a1ee40dea6ecbee224562bee7a Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 16:59:35 +0000 Subject: [PATCH 37/64] testing env vars --- .github/workflows/ci.yml | 3 +++ .github/workflows/test-action.yml | 11 ++++++----- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d25f496..c2073a9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,6 +17,9 @@ on: env_vars: required: false type: string + AZURE_CLIENT_ID: + required: false + type: string diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 68284fc..f9c5883 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -10,6 +10,9 @@ on: env_vars: required: false type: string + AZURE_CLIENT_ID: + required: false + type: string jobs: Linux: @@ -34,13 +37,11 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: + AZURE_CLIENT_ID: ${{ inputs.AZURE_CLIENT_ID }} env_vars: ${{ inputs.env_vars }} run: | - for i in $env_vars; do - i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) - echo ::add-mask::${i#*=} - printf '%s\n' "$i" >> $GITHUB_ENV - done + echo $AZURE_CLIENT_ID + echo $env_vars - name: Validate credentials run: | From d3997fdfc36b8d22d9115cc663cbf08ab70d2658 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 17:33:23 +0000 Subject: [PATCH 38/64] testing env vars --- .github/workflows/ci.yml | 1 + .github/workflows/test-action.yml | 10 ++-------- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c2073a9..a634299 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,6 +54,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} + env_vars: ${{ inputs.env_vars}} secrets: inherit docs: diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index f9c5883..dc3c736 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -10,9 +10,6 @@ on: env_vars: required: false type: string - AZURE_CLIENT_ID: - required: false - type: string jobs: Linux: @@ -37,15 +34,13 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: - AZURE_CLIENT_ID: ${{ inputs.AZURE_CLIENT_ID }} env_vars: ${{ inputs.env_vars }} run: | - echo $AZURE_CLIENT_ID echo $env_vars - name: Validate credentials run: | - echo $AZURE_CLIENT_ID + echo $env_vars - name: Setup Vault if: ${{ inputs.setup-vault }} @@ -80,11 +75,10 @@ jobs: # done - name: Test env: - env_vars: ${{ secrets.env_vars }} + env_vars: ${{ inputs.env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo $AZURE_CLIENT_ID echo $env_vars nox --force-color -e tests-3 -- -vv tests/ From 58fb87608f8169b14340ed58e5863aa37f31b9fc Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 17:44:22 +0000 Subject: [PATCH 39/64] testing env vars --- .github/workflows/ci.yml | 3 +++ .github/workflows/test-action.yml | 25 ++++++++++++++++--------- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a634299..89788b9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,6 +20,9 @@ on: AZURE_CLIENT_ID: required: false type: string + secrets: + secret_env_vars: + required: false diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index dc3c736..04227b3 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -10,6 +10,9 @@ on: env_vars: required: false type: string + secrets: + secret_env_vars: + required: false jobs: Linux: @@ -35,8 +38,10 @@ jobs: - name: Decode credentials as env vars env: env_vars: ${{ inputs.env_vars }} + secret_env_vars: ${{ secrets.secret_env_vars }} run: | echo $env_vars + echo $secret_env_vars - name: Validate credentials run: | @@ -64,22 +69,24 @@ jobs: run: | nox --force-color -e tests-3 --install-only - # - name: Test env vars - # env: - # env_vars: ${{ secrets.env_vars }} - # run: | - # for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do - # key=$(echo $secret | cut -d "=" -f 1) - # value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - # echo "export $key=\"$value\"" >> $GITHUB_OUTPUT - # done + - name: Test env vars + env: + env_vars: ${{ secrets.env_vars }} + run: | + for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do + key=$(echo $secret | cut -d "=" -f 1) + value=$(echo $secret | cut -d "=" -f 2 | base64 -d) + echo "export $key=\"$value\"" >> $GITHUB_OUTPUT + done - name: Test env: env_vars: ${{ inputs.env_vars }} + secret_env_vars: ${{ secrets.secret_env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | echo $env_vars + echo $secret_env_vars nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From e5996d8373cef868f482c456fdc21684d2301e38 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 17:52:20 +0000 Subject: [PATCH 40/64] testing env vars --- .github/workflows/test-action.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 04227b3..c42910f 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -71,7 +71,8 @@ jobs: - name: Test env vars env: - env_vars: ${{ secrets.env_vars }} + env_vars: ${{ inputs.env_vars }} + secret_env_vars: ${{ secrets.secret_env_vars }} run: | for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do key=$(echo $secret | cut -d "=" -f 1) From 410d0d6f99d886708fb3bc86f0ad3665859919cf Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 18:16:20 +0000 Subject: [PATCH 41/64] testing env vars --- .github/workflows/test-action.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index c42910f..91862f6 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -79,6 +79,12 @@ jobs: value=$(echo $secret | cut -d "=" -f 2 | base64 -d) echo "export $key=\"$value\"" >> $GITHUB_OUTPUT done + IFS=',' read -ra secrets_array <<< "$secret_env_vars" + for secret in "${secrets_array[@]}"; do + key=$(echo "$secret" | cut -d "=" -f 1) + value=$(echo "$secret" | cut -d "=" -f 2-) + echo "export $key=\"$value\"" >> $GITHUB_OUTPUT + done - name: Test env: env_vars: ${{ inputs.env_vars }} From 1f56cfca70eaeb5135699af3aa6e1d4bcfb6ad5b Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 18:32:22 +0000 Subject: [PATCH 42/64] testing env vars --- .github/workflows/test-action.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 91862f6..e5c9e92 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -74,11 +74,6 @@ jobs: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} run: | - for secret in $(echo $env_vars | jq -r "to_entries|map(\"\(.key)=\(.value|@base64)\")|.[]"); do - key=$(echo $secret | cut -d "=" -f 1) - value=$(echo $secret | cut -d "=" -f 2 | base64 -d) - echo "export $key=\"$value\"" >> $GITHUB_OUTPUT - done IFS=',' read -ra secrets_array <<< "$secret_env_vars" for secret in "${secrets_array[@]}"; do key=$(echo "$secret" | cut -d "=" -f 1) From 30aff594d0a79131997ea591ac291758780024eb Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 18:44:14 +0000 Subject: [PATCH 43/64] testing env vars --- .github/workflows/test-action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index e5c9e92..44735f9 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -76,8 +76,8 @@ jobs: run: | IFS=',' read -ra secrets_array <<< "$secret_env_vars" for secret in "${secrets_array[@]}"; do - key=$(echo "$secret" | cut -d "=" -f 1) - value=$(echo "$secret" | cut -d "=" -f 2-) + key=$(echo "$secret" | cut -d ":" -f 1 | tr -d '[:space:]' | tr -d '"') + value=$(echo "$secret" | cut -d ":" -f 2- | tr -d '[:space:]' | tr -d '"') echo "export $key=\"$value\"" >> $GITHUB_OUTPUT done - name: Test From 5afd135c9a45c632e089fec244121c330dd25961 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 19:06:07 +0000 Subject: [PATCH 44/64] testing env vars --- .github/workflows/ci.yml | 3 --- .github/workflows/test-action.yml | 4 +++- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 89788b9..8c974cf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,9 +17,6 @@ on: env_vars: required: false type: string - AZURE_CLIENT_ID: - required: false - type: string secrets: secret_env_vars: required: false diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 44735f9..6d2d563 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -40,7 +40,7 @@ jobs: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} run: | - echo $env_vars + echo "${{ toJSON(env_vars) }} echo $secret_env_vars - name: Validate credentials @@ -70,6 +70,7 @@ jobs: nox --force-color -e tests-3 --install-only - name: Test env vars + id: env env: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} @@ -80,6 +81,7 @@ jobs: value=$(echo "$secret" | cut -d ":" -f 2- | tr -d '[:space:]' | tr -d '"') echo "export $key=\"$value\"" >> $GITHUB_OUTPUT done + - name: Test env: env_vars: ${{ inputs.env_vars }} From 46e37d2c5d95d1ef22c1334c79600ac95fd544cd Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 19:07:25 +0000 Subject: [PATCH 45/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 6d2d563..d3d23e0 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -40,7 +40,7 @@ jobs: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} run: | - echo "${{ toJSON(env_vars) }} + echo "${{ toJSON(inputs.env_vars) }} echo $secret_env_vars - name: Validate credentials From 3fbaef09d715765066dac900a14a57a4311a2a22 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 19:15:24 +0000 Subject: [PATCH 46/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index d3d23e0..2b82b39 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -40,7 +40,7 @@ jobs: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} run: | - echo "${{ toJSON(inputs.env_vars) }} + echo "${{ toJSON(inputs.env_vars) }}" echo $secret_env_vars - name: Validate credentials From 58b0e35201141d7b165366c15a481213e1d81080 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 19:25:53 +0000 Subject: [PATCH 47/64] testing env vars --- .github/workflows/test-action.yml | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 2b82b39..9cf9ea9 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -40,12 +40,21 @@ jobs: env_vars: ${{ inputs.env_vars }} secret_env_vars: ${{ secrets.secret_env_vars }} run: | - echo "${{ toJSON(inputs.env_vars) }}" - echo $secret_env_vars + echo "$env_vars" + echo "$secret_env_vars" - - name: Validate credentials + - name: Test env vars + id: env + env: + env_vars: ${{ inputs.env_vars }} + secret_env_vars: ${{ secrets.secret_env_vars }} run: | - echo $env_vars + IFS=',' read -ra secrets_array <<< "$secret_env_vars" + for secret in "${secrets_array[@]}"; do + key=$(echo "$secret" | cut -d ":" -f 1 | tr -d '[:space:]' | tr -d '"') + value=$(echo "$secret" | cut -d ":" -f 2- | tr -d '[:space:]' | tr -d '"') + echo "export $key=\"$value\"" >> $GITHUB_OUTPUT + done - name: Setup Vault if: ${{ inputs.setup-vault }} @@ -69,19 +78,6 @@ jobs: run: | nox --force-color -e tests-3 --install-only - - name: Test env vars - id: env - env: - env_vars: ${{ inputs.env_vars }} - secret_env_vars: ${{ secrets.secret_env_vars }} - run: | - IFS=',' read -ra secrets_array <<< "$secret_env_vars" - for secret in "${secrets_array[@]}"; do - key=$(echo "$secret" | cut -d ":" -f 1 | tr -d '[:space:]' | tr -d '"') - value=$(echo "$secret" | cut -d ":" -f 2- | tr -d '[:space:]' | tr -d '"') - echo "export $key=\"$value\"" >> $GITHUB_OUTPUT - done - - name: Test env: env_vars: ${{ inputs.env_vars }} From 98546be3ba0ef67e14e7a845530613d99eb32815 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 19:43:23 +0000 Subject: [PATCH 48/64] testing env vars --- .github/workflows/test-action.yml | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 9cf9ea9..562d59d 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -10,9 +10,6 @@ on: env_vars: required: false type: string - secrets: - secret_env_vars: - required: false jobs: Linux: @@ -38,7 +35,12 @@ jobs: - name: Decode credentials as env vars env: env_vars: ${{ inputs.env_vars }} - secret_env_vars: ${{ secrets.secret_env_vars }} + secret_env_vars: | + { + "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", + "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", + "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" + } run: | echo "$env_vars" echo "$secret_env_vars" @@ -47,7 +49,12 @@ jobs: id: env env: env_vars: ${{ inputs.env_vars }} - secret_env_vars: ${{ secrets.secret_env_vars }} + secret_env_vars: | + { + "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", + "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", + "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" + } run: | IFS=',' read -ra secrets_array <<< "$secret_env_vars" for secret in "${secrets_array[@]}"; do @@ -81,7 +88,12 @@ jobs: - name: Test env: env_vars: ${{ inputs.env_vars }} - secret_env_vars: ${{ secrets.secret_env_vars }} + secret_env_vars: | + { + "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", + "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", + "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" + } SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | From ff887d3384e762a555d0a96751a3cfa31b7f41e1 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 20:23:50 +0000 Subject: [PATCH 49/64] testing env vars --- .github/workflows/ci.yml | 7 +----- .github/workflows/test-action.yml | 42 +++++++------------------------ 2 files changed, 10 insertions(+), 39 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8c974cf..8dd94ba 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,11 +14,8 @@ on: version: required: false type: string - env_vars: - required: false - type: string secrets: - secret_env_vars: + env_vars: required: false @@ -54,9 +51,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - env_vars: ${{ inputs.env_vars}} secrets: inherit - docs: name: Docs needs: diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 562d59d..b9df32c 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,9 +7,9 @@ on: required: false type: boolean default: false + secrets: env_vars: required: false - type: string jobs: Linux: @@ -34,34 +34,17 @@ jobs: - uses: actions/checkout@v4 - name: Decode credentials as env vars env: - env_vars: ${{ inputs.env_vars }} - secret_env_vars: | - { - "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", - "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", - "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" - } + env_vars: ${{ secrets.env_vars }} run: | - echo "$env_vars" - echo "$secret_env_vars" + for i in $env_vars; do + i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) + echo ::add-mask::${i#*=} + printf '%s\n' "$i" >> $GITHUB_ENV + done - name: Test env vars - id: env - env: - env_vars: ${{ inputs.env_vars }} - secret_env_vars: | - { - "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", - "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", - "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" - } run: | - IFS=',' read -ra secrets_array <<< "$secret_env_vars" - for secret in "${secrets_array[@]}"; do - key=$(echo "$secret" | cut -d ":" -f 1 | tr -d '[:space:]' | tr -d '"') - value=$(echo "$secret" | cut -d ":" -f 2- | tr -d '[:space:]' | tr -d '"') - echo "export $key=\"$value\"" >> $GITHUB_OUTPUT - done + echo $env_vars - name: Setup Vault if: ${{ inputs.setup-vault }} @@ -87,18 +70,11 @@ jobs: - name: Test env: - env_vars: ${{ inputs.env_vars }} - secret_env_vars: | - { - "AZURE_CLIENT_ID": "${{ secrets.AZURE_CLIENT_ID }}", - "AZURE_CLIENT_SECRET": "${{ secrets.AZURE_CLIENT_SECRET }}", - "AZURE_TENANT_ID": "${{ secrets.AZURE_TENANT_ID }}" - } + env_vars: ${{ secrets.env_vars }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | echo $env_vars - echo $secret_env_vars nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From b9f65c936b40189c441fef29903293d129070585 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Mon, 18 Mar 2024 20:50:33 +0000 Subject: [PATCH 50/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index b9df32c..c9404b4 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -44,7 +44,7 @@ jobs: - name: Test env vars run: | - echo $env_vars + echo $AZURE_CLIENT_ID - name: Setup Vault if: ${{ inputs.setup-vault }} From dd23fc8c7cd0e618c3808d8e76b45be577256d9c Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 16:17:46 +0000 Subject: [PATCH 51/64] testing env vars --- .github/workflows/ci.yml | 4 ++++ .github/workflows/test-action.yml | 21 ++++++++++++--------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8dd94ba..9d7e208 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,6 +14,9 @@ on: version: required: false type: string + ENV_VARS: + required: false + type: string secrets: env_vars: required: false @@ -51,6 +54,7 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} + ENV_VARS: ${{ inputs.ENV_VARS }} secrets: inherit docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index c9404b4..089b72b 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,6 +7,9 @@ on: required: false type: boolean default: false + ENV_VARS: + required: false + type: string secrets: env_vars: required: false @@ -32,19 +35,19 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Decode credentials as env vars + + - name: Decode environment variables for tests env: - env_vars: ${{ secrets.env_vars }} + ENV_VARS: "${{ inputs.ENV_VARS }}" run: | - for i in $env_vars; do - i=$(echo $i | sed 's/=.*//g')=$(echo ${i#*=} | base64 -di | base64 -di) - echo ::add-mask::${i#*=} - printf '%s\n' "$i" >> $GITHUB_ENV - done + echo "$TEST_ENV_VARS" | base64 -d >> $GITHUB_ENV - - name: Test env vars + - name: Just testing if the env vars got here run: | - echo $AZURE_CLIENT_ID + [[ "$AZURE_CLIENT_ID" == "hello" ]] && echo "hello" + [[ "$AZURE_CLIENT_SECRET" == "world" ]] && echo "world" + [[ "$AZURE_TENANT_ID" == "bye" ]] && echo "bye" + - name: Setup Vault if: ${{ inputs.setup-vault }} From 0bc5bf5fe74465dc7f6d77ed238f90ec1b667d41 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 16:30:35 +0000 Subject: [PATCH 52/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 089b72b..2223242 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -40,7 +40,7 @@ jobs: env: ENV_VARS: "${{ inputs.ENV_VARS }}" run: | - echo "$TEST_ENV_VARS" | base64 -d >> $GITHUB_ENV + echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV - name: Just testing if the env vars got here run: | From 27129883cc23c76a3d120c9680a34d9d00cd6137 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 16:51:38 +0000 Subject: [PATCH 53/64] testing env vars --- .github/workflows/ci.yml | 6 +----- .github/workflows/test-action.yml | 10 +++------- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9d7e208..d9b720e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,11 +14,8 @@ on: version: required: false type: string - ENV_VARS: - required: false - type: string secrets: - env_vars: + ENV_VARS: required: false @@ -54,7 +51,6 @@ jobs: uses: M3GH4NN/central-artifacts/.github/workflows/test-action.yml@credentials with: setup-vault: ${{ inputs.setup-vault }} - ENV_VARS: ${{ inputs.ENV_VARS }} secrets: inherit docs: name: Docs diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 2223242..07ef8a9 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -7,11 +7,8 @@ on: required: false type: boolean default: false - ENV_VARS: - required: false - type: string secrets: - env_vars: + ENV_VARS: required: false jobs: @@ -38,7 +35,7 @@ jobs: - name: Decode environment variables for tests env: - ENV_VARS: "${{ inputs.ENV_VARS }}" + ENV_VARS: "${{ secrets.ENV_VARS }}" run: | echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV @@ -73,11 +70,10 @@ jobs: - name: Test env: - env_vars: ${{ secrets.env_vars }} + ENV_VARS: ${{ secrets.ENV_VARS }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo $env_vars nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 21ee97b49c097dd0acc03aad33df86ce185ef55e Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 17:11:53 +0000 Subject: [PATCH 54/64] testing env vars --- .github/workflows/test-action.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 07ef8a9..6bebf0b 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -39,11 +39,6 @@ jobs: run: | echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV - - name: Just testing if the env vars got here - run: | - [[ "$AZURE_CLIENT_ID" == "hello" ]] && echo "hello" - [[ "$AZURE_CLIENT_SECRET" == "world" ]] && echo "world" - [[ "$AZURE_TENANT_ID" == "bye" ]] && echo "bye" - name: Setup Vault From 90ed7043ca1befee68f2ddfef1739107b7e395ef Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 17:54:40 +0000 Subject: [PATCH 55/64] testing env vars --- .github/workflows/test-action.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 6bebf0b..bfd9600 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -69,6 +69,7 @@ jobs: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | + echo "${{secrets.ENV_VARS}}" nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From cf9f9d7d89eeb2387ff617f7cdc2c44fd03f1994 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 19:30:04 +0000 Subject: [PATCH 56/64] testing env vars --- .github/workflows/test-action.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index bfd9600..09c7407 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -69,7 +69,14 @@ jobs: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo "${{secrets.ENV_VARS}}" + echo "Decoding environment variables..." + declare -A vars + IFS=' ' read -r -a var_array <<< "${ENV_VARS}" + for var in "${var_array[@]}"; do + IFS='=' read -r key value <<< "$var" + decoded_value=$(echo "$value" | base64 -d) + echo "$key=$decoded_value" >> $GITHUB_ENV + done nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 90b717ecd1c2fa0ae78906fa34fb775508eb08d7 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 19:44:07 +0000 Subject: [PATCH 57/64] testing env vars --- .github/workflows/test-action.yml | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 09c7407..ec2c4e3 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -35,9 +35,12 @@ jobs: - name: Decode environment variables for tests env: - ENV_VARS: "${{ secrets.ENV_VARS }}" + ENV_VARS: "${{ env.ENV_VARS }}" run: | - echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV + echo "$ENV_VARS" | base64 -d >> decoded_env_vars.txt + while read -r line; do + echo "$line" >> $GITHUB_ENV + done < decoded_env_vars.txt @@ -69,14 +72,7 @@ jobs: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo "Decoding environment variables..." - declare -A vars - IFS=' ' read -r -a var_array <<< "${ENV_VARS}" - for var in "${var_array[@]}"; do - IFS='=' read -r key value <<< "$var" - decoded_value=$(echo "$value" | base64 -d) - echo "$key=$decoded_value" >> $GITHUB_ENV - done + echo "${{secrets.ENV_VARS}}" nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 4e1b5a4b1c9c6c3a0bd1d7868ff9cbd26adb624e Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 19:51:36 +0000 Subject: [PATCH 58/64] testing env vars --- .github/workflows/test-action.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index ec2c4e3..aed9768 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -35,7 +35,7 @@ jobs: - name: Decode environment variables for tests env: - ENV_VARS: "${{ env.ENV_VARS }}" + ENV_VARS: "${{ secrets.ENV_VARS }}" run: | echo "$ENV_VARS" | base64 -d >> decoded_env_vars.txt while read -r line; do @@ -68,11 +68,11 @@ jobs: - name: Test env: - ENV_VARS: ${{ secrets.ENV_VARS }} + ENV_VARS: ${{ env.ENV_VARS }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo "${{secrets.ENV_VARS}}" + echo "${{env.ENV_VARS}}" nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 6414f26a7f7740f119d9863248f17b265339370d Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 20:04:27 +0000 Subject: [PATCH 59/64] testing env vars --- .github/workflows/test-action.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index aed9768..3f3cd97 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -37,11 +37,7 @@ jobs: env: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | - echo "$ENV_VARS" | base64 -d >> decoded_env_vars.txt - while read -r line; do - echo "$line" >> $GITHUB_ENV - done < decoded_env_vars.txt - + echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV - name: Setup Vault @@ -68,11 +64,9 @@ jobs: - name: Test env: - ENV_VARS: ${{ env.ENV_VARS }} SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | - echo "${{env.ENV_VARS}}" nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From 2ae28d947ee26b26f7ec4ec4f46ee4a38f91ee9a Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 20:25:36 +0000 Subject: [PATCH 60/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 3f3cd97..4cf4568 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -37,7 +37,7 @@ jobs: env: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | - echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV + echo "::add-mask::$ENV_VARS" | base64 -d >> $GITHUB_ENV - name: Setup Vault From 98d552cd526848ebc1514fe3f67adc297dc23606 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 20:33:53 +0000 Subject: [PATCH 61/64] testing env vars --- .github/workflows/test-action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 4cf4568..3f3cd97 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -37,7 +37,7 @@ jobs: env: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | - echo "::add-mask::$ENV_VARS" | base64 -d >> $GITHUB_ENV + echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV - name: Setup Vault From 89e14c611b079bca8dbb4de794e7dd86294b7ad5 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 20:57:27 +0000 Subject: [PATCH 62/64] testing env vars --- .github/workflows/test-action.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 3f3cd97..213513b 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -37,7 +37,10 @@ jobs: env: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | - echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV + echo "$ENV_VARS" | base64 -d + echo "::add-mask::$AZURE_CLIENT_ID" + echo "AZURE_CLIENT_ID=$AZURE_CLIENT_ID" >> $GITHUB_ENV + echo "AZURE_TENANT_ID=$AZURE_TENANT_ID" >> $GITHUB_ENV - name: Setup Vault @@ -67,6 +70,7 @@ jobs: SALT_REQUIREMENT: salt==${{ matrix.salt-version }} SKIP_REQUIREMENTS_INSTALL: YES run: | + nox --force-color -e tests-3 -- -vv tests/ - name: Create CodeCov Flags From a669462d518177c790bda55726c6fe338623621f Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 21:04:09 +0000 Subject: [PATCH 63/64] testing env vars --- .github/workflows/test-action.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index 213513b..e8c3929 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -38,9 +38,8 @@ jobs: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | echo "$ENV_VARS" | base64 -d - echo "::add-mask::$AZURE_CLIENT_ID" - echo "AZURE_CLIENT_ID=$AZURE_CLIENT_ID" >> $GITHUB_ENV - echo "AZURE_TENANT_ID=$AZURE_TENANT_ID" >> $GITHUB_ENV + echo "AZURE_CLIENT_ID=::add-mask::$AZURE_CLIENT_ID" >> $GITHUB_ENV + echo "AZURE_TENANT_ID=::add-mask::$AZURE_TENANT_ID" >> $GITHUB_ENV - name: Setup Vault From 0609116de6ded22f878d9e8499fc69e14377e9a9 Mon Sep 17 00:00:00 2001 From: Meghann Cunningham Date: Tue, 19 Mar 2024 21:34:09 +0000 Subject: [PATCH 64/64] testing env vars --- .github/workflows/test-action.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/test-action.yml b/.github/workflows/test-action.yml index e8c3929..af156ab 100644 --- a/.github/workflows/test-action.yml +++ b/.github/workflows/test-action.yml @@ -37,9 +37,7 @@ jobs: env: ENV_VARS: "${{ secrets.ENV_VARS }}" run: | - echo "$ENV_VARS" | base64 -d - echo "AZURE_CLIENT_ID=::add-mask::$AZURE_CLIENT_ID" >> $GITHUB_ENV - echo "AZURE_TENANT_ID=::add-mask::$AZURE_TENANT_ID" >> $GITHUB_ENV + echo "$ENV_VARS" | base64 -d >> $GITHUB_ENV - name: Setup Vault