Skip to content

Commit 44a03ea

Browse files
committed
ci: build OCI image tarball and load it to Podman
Podman in GitHub Runner image is too old, and Docker is too new: loading image from docker engine: Error response from daemon: client version 1.41 is too old. Minimum supported API version is 1.44, please upgrade your client to a newer version
1 parent b2442f2 commit 44a03ea

1 file changed

Lines changed: 7 additions & 8 deletions

File tree

.github/workflows/build.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ jobs:
4141
steps:
4242
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4343

44+
- uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3.12.0
45+
4446
- uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3.7.0
4547
with:
4648
registry: ghcr.io
@@ -59,6 +61,7 @@ jobs:
5961
file: ${{ matrix.name }}.dockerfile
6062
pull: true
6163
push: ${{ inputs.push }}
64+
outputs: type=oci,dest=${{ runner.temp }}/image.tar
6265
tags: ${{ steps.docker_meta.outputs.tags }}
6366
labels: ${{ steps.docker_meta.outputs.labels }}
6467
annotations: ${{ steps.docker_meta.outputs.annotations }}
@@ -68,32 +71,28 @@ jobs:
6871
cache-to: type=inline
6972

7073
- id: podman_pull
71-
run: |
72-
imageid="$(podman pull "docker-daemon:$IMAGE_ID")"
73-
echo "imageid=$imageid" | tee "$GITHUB_OUTPUT"
74-
env:
75-
IMAGE_ID: ${{ steps.docker_build.outputs.imageid }}
74+
run: podman load -i "$RUNNER_TEMP/image.tar"
7675

7776
- id: gnome-session-wayland
7877
name: Test gnome-session-wayland
7978
run: test/test-wayland.sh "$IMAGE_ID"
8079
env:
81-
IMAGE_ID: ${{ steps.podman_pull.outputs.imageid }}
80+
IMAGE_ID: ${{ fromJSON(steps.docker_build.outputs.metadata)['image.name'] }}@${{ steps.docker_build.outputs.digest }}
8281

8382
- id: has-x11
8483
name: Check if X11 is available
8584
run: |
8685
cli_arg="$(podman run --rm "$IMAGE_ID" gnome-shell --help | grep -qF -- '--x11' && podman run --rm "$IMAGE_ID" sh -c 'command -V Xvfb >/dev/null' && echo 1 || echo 0)"
8786
echo "cli_arg=$cli_arg" | tee "$GITHUB_OUTPUT"
8887
env:
89-
IMAGE_ID: ${{ steps.podman_pull.outputs.imageid }}
88+
IMAGE_ID: ${{ fromJSON(steps.docker_build.outputs.metadata)['image.name'] }}@${{ steps.docker_build.outputs.digest }}
9089

9190
- id: gnome-session-x11
9291
name: Test gnome-session-x11
9392
run: test/test-x11.sh "$IMAGE_ID"
9493
if: fromJSON(steps.has-x11.outputs.cli_arg)
9594
env:
96-
IMAGE_ID: ${{ steps.podman_pull.outputs.imageid }}
95+
IMAGE_ID: ${{ fromJSON(steps.docker_build.outputs.metadata)['image.name'] }}@${{ steps.docker_build.outputs.digest }}
9796

9897
- name: Upload screenshot
9998
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0

0 commit comments

Comments
 (0)