-
Notifications
You must be signed in to change notification settings - Fork 1
33 lines (32 loc) · 1.17 KB
/
pull_request.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Push Multiarch Images
on:
pull_request:
push:
branches:
- main
jobs:
build-and-push-arch-specifics:
name: Build Rocks and Push Arch Specific Images
uses: ./dev/workflow.yaml
with:
owner: ${{ github.repository_owner }}
trivy-image-config: "trivy.yaml"
multiarch-awareness: true
cache-action: ${{ (github.event_name == 'push') && 'save' || 'restore' }}
platform-labels: '{"arm64": "Ubuntu_ARM64_4C_16G_01"}'
maximize-build-space: false
scan-images:
uses: canonical/k8s-workflows/.github/workflows/scan_images.yaml@main
needs: [build-and-push-arch-specifics]
secrets: inherit
with:
upload-result: ${{ github.event_name == 'push' }}
images: ${{ needs.build-and-push-arch-specifics.outputs.images }}
trivy-image-config: ./trivy.yaml
build-and-push-multiarch-manifest:
name: Combine Rocks and Push Multiarch Manifest
uses: canonical/k8s-workflows/.github/workflows/assemble_multiarch_image.yaml@main
needs: [build-and-push-arch-specifics]
with:
rock-metas: ${{ needs.build-and-push-arch-specifics.outputs.rock-metas }}
dry-run: ${{ github.event_name != 'push' }}