Skip to content

Commit

Permalink
pass GCR secrets to smoke test action
Browse files Browse the repository at this point in the history
  • Loading branch information
pdabelf5 committed Jan 19, 2024
1 parent d471a74 commit 1c5523a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 9 additions & 2 deletions .github/actions/smoke-tests/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ inputs:
rhel-license:
description: RHEL license for UBI builds
required: false
gcr-workload-identity-secret:
description: Google Workflow Identity secret
required: false
gcr-service-account-secret:
description: Google Service Account secret
required: false

outputs:
test-results-name:
Expand Down Expand Up @@ -104,8 +110,8 @@ runs:
uses: google-github-actions/auth@v2
with:
token_format: access_token
workload_identity_provider: ${{ secrets.GCR_WORKLOAD_IDENTITY }}
service_account: ${{ secrets.GCR_SERVICE_ACCOUNT }}
workload_identity_provider: ${{ inputs.gcr-workload-identity-secret }}
service_account: ${{ inputs.gcr-service-account-secret }}

- name: Login to GCR
uses: docker/login-action@v3
Expand All @@ -118,6 +124,7 @@ runs:
id: check-image
run: |
docker inspect ${{ inputs.test-image }}
shell: bash
continue-on-error: true

- name: Build Test-Runner Container
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -359,6 +359,8 @@ jobs:
nginx-crt: ${{ contains(matrix.images.image, 'nap') && secrets.NGINX_AP_CRT || secrets.NGINX_CRT }}
nginx-key: ${{ contains(matrix.images.image, 'nap') && secrets.NGINX_AP_KEY || secrets.NGINX_KEY }}
azure-ad-secret: ${{ secrets.AZURE_AD_AUTOMATION }}
gcr-workload-identity-secret: ${{ secrets.GCR_WORKLOAD_IDENTITY }}
gcr-service-account-secret: ${{ secrets.GCR_SERVICE_ACCOUNT }}
rhel-license: ${{ contains(matrix.images.image, 'ubi') && secrets.RHEL_LICENSE || '' }}
go-md5: ${{ needs.checks.outputs.go_code_md5 }}
test-image: "gcr.io/f5-gcs-7899-ptg-ingrss-ctlr/dev/test-runner:${{ hashFiles('./tests/requirements.txt') || 'latest' }}"
Expand Down

0 comments on commit 1c5523a

Please sign in to comment.