Skip to content

Commit f0c2d63

Browse files
jlebonalicefr
authored andcommitted
ci: build bink from source at a pinned commit
This somewhat reverts 3ab5283 ("ci: fetch versioned bink release instead of building from source") and solves the issue of a moving bink target by instead freezing on a specific commit. The original approach of downloading binaries makes sense. But I think it's a bit too early to move to that model. Let's wait until the testing needs of bootc-operator and bink itself are stabilized and then we can move to a binary release model. Assisted-by: Pi (Claude Opus 4.6)
1 parent e7a1424 commit f0c2d63

1 file changed

Lines changed: 46 additions & 6 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 46 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
branches: [main]
99

1010
env:
11-
BINK_VERSION: v0.1.1
11+
BINK_COMMIT: 2b1bbdca74fc36d319fb1ea6d0523d9a732fcb1f
1212

1313
permissions: {}
1414

@@ -47,8 +47,45 @@ jobs:
4747
- name: Lint
4848
run: make lint
4949

50+
build-bink:
51+
runs-on: ubuntu-latest
52+
permissions:
53+
contents: read
54+
steps:
55+
- name: Checkout bink
56+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
57+
with:
58+
repository: alicefr/bink
59+
ref: ${{ env.BINK_COMMIT }}
60+
persist-credentials: false
61+
62+
- name: Set up Go
63+
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
64+
with:
65+
go-version-file: go.mod
66+
cache: true # zizmor: ignore[cache-poisoning]
67+
68+
- name: Install build dependencies
69+
run: |
70+
sudo apt-get update
71+
sudo apt-get install -y \
72+
libgpgme-dev \
73+
libbtrfs-dev \
74+
libdevmapper-dev \
75+
pkg-config
76+
77+
- name: Build bink
78+
run: make build-bink
79+
80+
- name: Upload bink binary
81+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
82+
with:
83+
name: bink
84+
path: bink
85+
5086
e2e:
5187
runs-on: ubuntu-latest
88+
needs: build-bink
5289
timeout-minutes: 30
5390
permissions:
5491
contents: read
@@ -61,11 +98,14 @@ jobs:
6198
with:
6299
persist-credentials: false
63100

64-
- name: Download bink release
65-
run: |
66-
sudo curl -fsSL -o /usr/local/bin/bink \
67-
https://github.com/alicefr/bink/releases/download/${{ env.BINK_VERSION }}/bink
68-
sudo chmod +x /usr/local/bin/bink
101+
- name: Download bink binary
102+
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
103+
with:
104+
name: bink
105+
path: /usr/local/bin
106+
107+
- name: Make bink executable
108+
run: chmod +x /usr/local/bin/bink
69109

70110
- name: Set up Go
71111
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0

0 commit comments

Comments
 (0)