From 45e54475d0cb67a4ede21f47428af78f24a2a103 Mon Sep 17 00:00:00 2001 From: Jan Prochazka Date: Wed, 28 Sep 2022 19:22:41 +0200 Subject: [PATCH] docker build --- .github/workflows/build-docker-beta.yaml | 78 +++++++++++++----------- 1 file changed, 41 insertions(+), 37 deletions(-) diff --git a/.github/workflows/build-docker-beta.yaml b/.github/workflows/build-docker-beta.yaml index 5cd72b18..e21baf7f 100644 --- a/.github/workflows/build-docker-beta.yaml +++ b/.github/workflows/build-docker-beta.yaml @@ -49,17 +49,7 @@ jobs: dbgate/dbgate tags: | type=semver,pattern={{version}},suffix=-beta - type=semver,pattern={{major}}.{{minor}},suffix=-beta - - - name: Build docker - uses: mr-smithers-excellent/docker-build-push@v3 - with: - image: dbgate/dbgate - registry: docker.io - dockerfile: docker/Dockerfile - username: ${{ secrets.DOCKER_USERNAME }} - password: ${{ secrets.DOCKER_PASSWORD }} - tags: ${{ steps.meta.outputs.tags }},beta +# type=semver,pattern={{major}}.{{minor}},suffix=-beta - name: Docker alpine meta id: alpmeta @@ -69,32 +59,46 @@ jobs: dbgate/dbgate tags: | type=semver,pattern={{version}},suffix=-beta-alpine - type=semver,pattern={{major}}.{{minor}},suffix=-beta-alpine +# type=semver,pattern={{major}}.{{minor}},suffix=-beta-alpine - # - name: Build docker image - # run: | - # docker build ./docker -t dbgate - # - name: Push docker image - # run: | - # docker tag dbgate dbgate/dbgate:beta - # docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} - # docker push dbgate/dbgate:beta + - name: Build docker image + run: | + docker build ./docker -t dbgate + - name: Push docker image + run: | + docker tag dbgate dbgate/dbgate:beta + docker tag dbgate ${{ steps.meta.outputs.tags }} + docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} + docker push dbgate/dbgate:beta + docker push ${{ steps.meta.outputs.tags }} - # - name: Build alpine docker image - # run: | - # docker build ./docker -t dbgate -f docker/Dockerfile-alpine - # - name: Push alpine docker image - # run: | - # docker tag dbgate dbgate/dbgate:beta-alpine - # docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} - # docker push dbgate/dbgate:beta-alpine + - name: Build alpine docker image + run: | + docker build ./docker -t dbgate -f docker/Dockerfile-alpine + - name: Push alpine docker image + run: | + docker tag dbgate dbgate/dbgate:beta-alpine + docker tag dbgate ${{ steps.alpmeta.outputs.tags }} + docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} + docker push dbgate/dbgate:beta-alpine + docker push ${{ steps.alpmeta.outputs.tags }} - - name: Build docker - uses: mr-smithers-excellent/docker-build-push@v3 - with: - image: dbgate/dbgate - registry: docker.io - dockerfile: docker/Dockerfile-alpine - username: ${{ secrets.DOCKER_USERNAME }} - password: ${{ secrets.DOCKER_PASSWORD }} - tags: ${{ steps.alpmeta.outputs.tags }},beta-alpine + # - name: Build docker + # uses: mr-smithers-excellent/docker-build-push@v3 + # with: + # image: dbgate/dbgate + # registry: docker.io + # dockerfile: docker/Dockerfile + # username: ${{ secrets.DOCKER_USERNAME }} + # password: ${{ secrets.DOCKER_PASSWORD }} + # tags: ${{ steps.meta.outputs.tags }},beta + + # - name: Build docker alpine + # uses: mr-smithers-excellent/docker-build-push@v3 + # with: + # image: dbgate/dbgate + # registry: docker.io + # dockerfile: docker/Dockerfile-alpine + # username: ${{ secrets.DOCKER_USERNAME }} + # password: ${{ secrets.DOCKER_PASSWORD }} + # tags: ${{ steps.alpmeta.outputs.tags }},beta-alpine