File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1111 permissions :
1212 contents : read
1313 packages : write
14+ strategy :
15+ matrix :
16+ test-image : [docker-sdcc-test-1, docker-sdcc-test-2]
1417 steps :
1518 - name : Checkout
1619 uses : actions/checkout@v3
@@ -25,21 +28,18 @@ jobs:
2528 username : ${{ github.actor }}
2629 password : ${{ secrets.GITHUB_TOKEN }}
2730
28- - name : Build test image
31+ - name : Build and test push
2932 uses : docker/build-push-action@v4
3033 with :
3134 context : .
3235 dockerfile : Dockerfile.test
33- push : false # Don't push, just test build
34- load : true # Load into Docker daemon
35- tags : ghcr.io/tg9541/docker-sdcc:3.9.0-test
36+ push : true
37+ tags : ghcr.io/tg9541/${{ matrix.test-image }}:latest
38+ labels : |
39+ org.opencontainers.image.description=Test image
40+ org.opencontainers.image.title=Test
41+ org.opencontainers.image.version=1.0
3642
37- - name : Verify image
43+ - name : Verify push
3844 run : |
39- docker images | grep docker-sdcc
40- echo "Test build successful!"
41-
42- - name : Push test image (optional)
43- if : github.event_name == 'workflow_dispatch'
44- run : |
45- docker push ghcr.io/tg9541/docker-sdcc:3.9.0-test
45+ echo "Test image pushed successfully to: ghcr.io/tg9541/${{ matrix.test-image }}:latest"
You can’t perform that action at this time.
0 commit comments