File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change 5252 cybuerg/cfspeedtest:${{ github.sha }}
5353 cache-from : type=local,src=/tmp/.buildx-cache
5454 cache-to : type=local,dest=/tmp/.buildx-cache-new,mode=max
55+ outputs : type=docker,dest=/tmp/docker-image.tar
5556 - name : Move cache
5657 run : |
5758 rm -rf /tmp/.buildx-cache
5859 mv /tmp/.buildx-cache-new /tmp/.buildx-cache
60+ - name : Upload Docker image as artifact
61+ uses : actions/upload-artifact@v3
62+ with :
63+ name : docker-image
64+ path : /tmp/docker-image.tar
65+ retention-days : 1
66+
67+ verify-docker-image :
68+ needs : docker-build
69+ runs-on : ubuntu-latest
70+ strategy :
71+ matrix :
72+ platform : [linux/amd64, linux/arm64]
73+ steps :
74+ - name : Download Docker image
75+ uses : actions/download-artifact@v3
76+ with :
77+ name : docker-image
78+ path : /tmp
79+ - name : Load Docker image
80+ run : |
81+ docker load < /tmp/docker-image.tar
82+ - name : Verify amd64 image
83+ if : matrix.platform == 'linux/amd64'
84+ run : |
85+ docker run --platform linux/amd64 cybuerg/cfspeedtest:${{ github.sha }} --help
86+ docker run --platform linux/amd64 --entrypoint /bin/sh cybuerg/cfspeedtest:${{ github.sha }} -c "file /usr/local/bin/cfspeedtest" | grep "x86-64"
87+ - name : Verify arm64 image
88+ if : matrix.platform == 'linux/arm64'
89+ run : |
90+ docker run --platform linux/arm64 cybuerg/cfspeedtest:${{ github.sha }} --help
91+ docker run --platform linux/arm64 --entrypoint /bin/sh cybuerg/cfspeedtest:${{ github.sha }} -c "file /usr/local/bin/cfspeedtest" | grep "aarch64"
You can’t perform that action at this time.
0 commit comments