@cryptotaxi247 / netdata-1 / commits / d0b8699f3

Use QEMU from the runner environment instead of an external copy. (#19468)

* Use QEMU from the runner environment instead of an external copy. This should make things both more self-contained and easier to debug when things go wrong. * Fix conditional for QEMU setup.

Austin S. Hemmelgarn committed Jan 24, 2025 at 08:49 UTC d0b8699f3fd765a63ea5ab3931ca429b8c92cc7c
3 files changed +19 -3
.github/workflows/build.yml
+10
@@ -228,10 +228,18 @@ jobs:
228 with:
229 path: artifacts/cache
230 key: ${{ steps.cache-key.outputs.key }}
231 + - name: Set up QEMU
232 + id: qemu
233 + if: needs.file-check.outputs.run == 'true'
234 + run: |
235 + sudo apt-get update
236 + sudo apt-get upgrade -y
237 + sudo apt-get install -y qemu-user-static
238 - name: Build
239 if: github.event_name != 'workflow_dispatch' && needs.file-check.outputs.run == 'true' # Don’t use retries on PRs.
240 run: |
241 export EXTRA_INSTALL_FLAGS=${{ needs.file-check.outputs.skip-go }}
242 + export SKIP_EMULATION=1
243 .github/scripts/build-static.sh ${{ matrix.arch }}
244 - name: Build
245 if: github.event_name == 'workflow_dispatch' && needs.file-check.outputs.run == 'true'
@@ -242,6 +250,7 @@ jobs:
250 max_attempts: 3
251 command: |
252 export EXTRA_INSTALL_FLAGS=${{ needs.file-check.outputs.skip-go }}
253 + export SKIP_EMULATION=1
254 .github/scripts/build-static.sh ${{ matrix.arch }}
255 - name: Store
256 id: store
@@ -264,6 +273,7 @@ jobs:
273 Checkout: ${{ steps.checkout.outcome }}
274 Fix Tags: ${{ steps.fix-tags.outcome }}
275 Mark stable: ${{ steps.channel.outcome }}
276 + Set up QEMU: ${{ steps.qemu.outcome }}
277 Build: ${{ steps.build.outcome }}
278 Store: ${{ steps.store.outcome }}
279 SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
.github/workflows/docker.yml
+4 -1
@@ -153,7 +153,10 @@ jobs:
153 - name: Setup QEMU
154 id: qemu
155 if: matrix.platform != 'linux/i386' && matrix.platform != 'linux/amd64' && needs.file-check.outputs.run == 'true'
156 - uses: docker/setup-qemu-action@v3
156 + run: |
157 + sudo apt-get update
158 + sudo apt-get upgrade -y
159 + sudo apt-get install -y qemu-user-static
160 - name: Setup Buildx
161 id: prepare
162 if: needs.file-check.outputs.run == 'true'
.github/workflows/packaging.yml
+5 -2
@@ -230,8 +230,11 @@ jobs:
230 fi
231 - name: Setup QEMU
232 id: qemu
233 - if: matrix.platform != 'linux/amd64' && matrix.platform != 'linux/i386' && needs.file-check.outputs.run == 'true'
234 - uses: docker/setup-qemu-action@v3
233 + if: matrix.platform != 'linux/i386' && matrix.platform != 'linux/amd64' && needs.file-check.outputs.run == 'true'
234 + run: |
235 + sudo apt-get update
236 + sudo apt-get upgrade -y
237 + sudo apt-get install -y qemu-user-static
238 - name: Fetch images
239 id: fetch-images
240 if: needs.file-check.outputs.run == 'true'