-
Notifications
You must be signed in to change notification settings - Fork 1
62 lines (59 loc) · 1.79 KB
/
build.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Build images 🔧
on:
pull_request:
jobs:
get-old-versions:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Extract versions
run: |
docker run --name generic quay.io/kairos/framework:main_generic true || true
docker cp generic:/framework/etc/kairos/versions.yaml versions_generic.old.yaml
docker rm generic
docker run --name fips quay.io/kairos/framework:main_fips true || true
docker cp fips:/framework/etc/kairos/versions.yaml versions_fips.old.yaml
docker rm fips
- uses: actions/upload-artifact@v3
with:
name: old_versions.zip
path: |
versions_generic.old.yaml
versions_fips.old.yaml
build-generic:
uses: ./.github/workflows/reusable-build.yaml
secrets: inherit
with:
security_profile: generic
build-fips:
uses: ./.github/workflows/reusable-build.yaml
secrets: inherit
with:
security_profile: fips
comment-pr:
runs-on: ubuntu-latest
permissions:
pull-requests: write
needs: [build-generic, build-fips, get-old-versions]
steps:
- uses: actions/checkout@v4
- name: Download versions
uses: actions/download-artifact@v3
with:
name: versions_generic.zip
- name: Download versions fips
uses: actions/download-artifact@v3
with:
name: versions_fips.zip
- name: Download old versions
uses: actions/download-artifact@v3
with:
name: old_versions.zip
- name: Generate PR text
run: |
.github/diffversions.sh
- name: Comment PR
uses: thollander/actions-comment-pull-request@v2
with:
comment_tag: bot-comment
filePath: pr-message