Merge pull request #10340 from wolfi-dev/wolfictl-cbbe69f7-df1b-4062-… #6037
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update prod cache of build materials | |
on: | |
push: | |
branches: ['main'] | |
env: | |
PROJECT: prod-images-c6e5 | |
FQ_SERVICE_ACCOUNT: [email protected] | |
SOURCE_CACHE_BUCKET: wolfi-sources | |
jobs: | |
update-cache: | |
runs-on: ubuntu-latest | |
if: github.repository == 'wolfi-dev/os' | |
permissions: | |
contents: read | |
id-token: write | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: chainguard-dev/actions/setup-melange@main | |
- uses: google-github-actions/auth@v1 | |
with: | |
workload_identity_provider: "projects/618116202522/locations/global/workloadIdentityPools/prod-shared-e350/providers/prod-shared-gha" | |
service_account: ${{env.FQ_SERVICE_ACCOUNT}} | |
- uses: google-github-actions/setup-gcloud@v1 | |
with: | |
project_id: ${{env.PROJECT}} | |
- name: 'Update cache of build materials for all packages' | |
run: | | |
for cfg in $(ls -1 | grep '.*\.yaml'); do | |
echo "Updating cache for ${cfg}..."; | |
melange update-cache --cache-dir gs://${{env.SOURCE_CACHE_BUCKET}}/ "${cfg}" || true; | |
done |