Skip to content

Commit

Permalink
fix(workflows): Start buildkit for mac tests
Browse files Browse the repository at this point in the history
Signed-off-by: Cezar Craciunoiu <[email protected]>
  • Loading branch information
craciunoiuc committed Aug 5, 2024
1 parent 1cc2f82 commit dae1250
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/tests-stable.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,26 @@ jobs:
os: [ubuntu-24.04, ubuntu-22.04, macos-12, macos-13, macos-14, mac-m2-14]
runs-on: ${{ matrix.os }}
steps:
- name: Generate Suffix
shell: bash
id: suffix
run: echo "suffix=$(date +%s)" >> "$GITHUB_OUTPUT"

- name: Set up BuildKit
shell: bash
run: |
docker run \
--rm \
-itd \
--privileged \
--name "buildkitd_${GITHUB_RUN_ID}_${SUFFIX}" \
-v /run/buildkit:/run/buildkit:rw \
moby/buildkit:v0.14.1;
timeout 60 bash -c 'while [ ! -S "/run/buildkit/buildkitd.sock" ]; do sleep 1; done'
sudo chmod 666 /run/buildkit/buildkitd.sock;
env:
SUFFIX: ${{ steps.suffix.outputs.suffix }}

- uses: actions/checkout@v4
with:
submodules: recursive
Expand Down Expand Up @@ -43,6 +63,11 @@ jobs:
- name: Run tests
run: make test-unit

- name: Stop BuildKit
if: always()
shell: bash
run: docker stop "buildkitd_${GITHUB_RUN_ID}_${{ steps.suffix.outputs.suffix }}" || true

e2e-cli:
strategy:
fail-fast: false
Expand Down

0 comments on commit dae1250

Please sign in to comment.