File tree Expand file tree Collapse file tree 2 files changed +22
-7
lines changed Expand file tree Collapse file tree 2 files changed +22
-7
lines changed Original file line number Diff line number Diff line change 1+ # Panubo build and push to Quay.io and ECR Public
2+ # This GH Action is intended for public docker images that package upstream applications/services (ie not for projects of Panubo's).
3+ # For repos that build multiple repos use the multi-build-push.yml workflow.
4+ #
5+ # This workflow runs on pushes to "main", PRs (does not push) or matching git tags.
6+ # Image names are generated from the repository name, if "docker-" is part of the repository name it is removed from the docker image name.
7+ #
8+ # Additionally this workflow performs some automated testing after a docker build.
9+ # Automated testing is triggered by `make _ci_test`, if no test is required the Makefile target should just run `true`.
10+ # Before tests are run a Docker build is performed, the resulting image has a tag of "test"
11+ # BATS is installed since it is commonly required by the tests.
12+
113name : build and push on main and tags
214
315on :
@@ -74,10 +86,10 @@ jobs:
7486 username : ${{ secrets.PANUBUILD_QUAYIO_USERNAME }}
7587 password : ${{ secrets.PANUBUILD_QUAYIO_TOKEN }}
7688
77- # - name: Setup BATS
78- # uses: mig4/setup-bats@v1
79- # with:
80- # bats-version: 1.7.0
89+ - name : Setup BATS
90+ uses : mig4/setup-bats@v1
91+ with :
92+ bats-version : 1.7.0
8193
8294 - name : Build and export to Docker
8395 uses : docker/build-push-action@v4
8799 load : true
88100 tags : ${{ steps.image_name.outputs.image_name }}:test
89101
90- # - name: Test
91- # run: |
92- # make _ci_test
102+ - name : Test
103+ run : |
104+ make _ci_test
93105
94106 - name : Build and Push
95107 uses : docker/build-push-action@v3
Original file line number Diff line number Diff line change @@ -17,6 +17,9 @@ build-with-cache:
1717test :
1818 bats -r tests/
1919
20+ _ci_test :
21+ true
22+
2023push :
2124 docker push $(IMAGE_NAME ) :$(TAG )
2225
You can’t perform that action at this time.
0 commit comments