Skip to content

Commit c4dff7c

Browse files
authored
Settings for workload identity federation (gcs) (#346)
* settings for workload identity federation (gcs) * settings for workload identity federation (gcs) remove garbase from 'workload_identity_provider' * settings for workload identity federation (gcs) check if the gcs test bucket gs://pfn-pfio-test-bucket is available or not * settings for workload identity federation (gcs) * settings for workload identity federation (gcs) * settings for workload identity federation (gcs) * settings for workload identity federation (gcs) * settings for workload identity federation (gcs) * settings for workload identity federation (gcs) try to use a service account * settings for workload identity federation (gcs) change a service account name * settings for workload identity federation (gcs)
1 parent 14f0232 commit c4dff7c

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

.github/workflows/python-package.yml

+16
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99

1010
jobs:
1111
build:
12+
# Add "id-token" with the intended permissions.
13+
permissions:
14+
contents: 'read'
15+
id-token: 'write'
1216

1317
runs-on: ubuntu-latest
1418
strategy:
@@ -18,6 +22,18 @@ jobs:
1822

1923
steps:
2024
- uses: actions/checkout@v4
25+
26+
- uses: 'google-github-actions/auth@v2'
27+
with:
28+
project_id: 'cluster-storage'
29+
workload_identity_provider: 'projects/1097862457753/locations/global/workloadIdentityPools/github-actions-pfio-ci-tasks/providers/github'
30+
service_account: '[email protected]'
31+
- name: 'Set up Google Cloud SDK'
32+
uses: 'google-github-actions/setup-gcloud@v2'
33+
- name: 'Check Bucket accessibility'
34+
run: |
35+
gcloud storage ls gs://pfn-pfio-test-bucket/ --recursive
36+
2137
- name: Set up Python ${{ matrix.python-version }}
2238
uses: actions/setup-python@v5
2339
with:

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@ dist
99
.tox
1010

1111
*~
12+
13+
# Ignore generated credentials from google-github-actions/auth
14+
gha-creds-*.json

0 commit comments

Comments
 (0)