Skip to content

Commit

Permalink
Use docker release command
Browse files Browse the repository at this point in the history
  • Loading branch information
vardius committed Sep 28, 2020
1 parent 5929cca commit 793bfdf
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 21 deletions.
6 changes: 2 additions & 4 deletions .github/workflow-templates/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ jobs:
TAG: ${{steps.tmp.outputs.tag}}
- name: Docker login
run: docker login docker.pkg.github.com -u $GITHUB_ACTOR -p ${{ secrets.GITHUB_TOKEN }}
- name: Build image
run: make docker-build BIN=$IMAGE_NAME
- name: Publish image
run: make docker-publish BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
- name: Release images
run: make docker-release BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
6 changes: 2 additions & 4 deletions .github/workflows/auth-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ jobs:
TAG: ${{steps.tmp.outputs.tag}}
- name: Docker login
run: docker login docker.pkg.github.com -u $GITHUB_ACTOR -p ${{ secrets.GITHUB_TOKEN }}
- name: Build image
run: make docker-build BIN=$IMAGE_NAME
- name: Publish image
run: make docker-publish BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
- name: Release images
run: make docker-release BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
6 changes: 2 additions & 4 deletions .github/workflows/migrate-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ jobs:
TAG: ${{steps.tmp.outputs.tag}}
- name: Docker login
run: docker login docker.pkg.github.com -u $GITHUB_ACTOR -p ${{ secrets.GITHUB_TOKEN }}
- name: Build image
run: make docker-build BIN=$IMAGE_NAME
- name: Publish image
run: make docker-publish BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
- name: Release images
run: make docker-release BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
6 changes: 2 additions & 4 deletions .github/workflows/user-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ jobs:
TAG: ${{steps.tmp.outputs.tag}}
- name: Docker login
run: docker login docker.pkg.github.com -u $GITHUB_ACTOR -p ${{ secrets.GITHUB_TOKEN }}
- name: Build image
run: make docker-build BIN=$IMAGE_NAME
- name: Publish image
run: make docker-publish BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
- name: Release images
run: make docker-release BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
6 changes: 2 additions & 4 deletions .github/workflows/web-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ jobs:
TAG: ${{steps.tmp.outputs.tag}}
- name: Docker login
run: docker login docker.pkg.github.com -u $GITHUB_ACTOR -p ${{ secrets.GITHUB_TOKEN }}
- name: Build image
run: make docker-build BIN=$IMAGE_NAME
- name: Publish image
run: make docker-publish BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
- name: Release images
run: make docker-release BIN=$IMAGE_NAME REGISTRY=docker.pkg.github.com/$GITHUB_REPOSITORY VERSION=${{ steps.vars.outputs.tag }}
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ docker-publish: docker-tag-latest docker-tag-version docker-publish-latest docke

docker-publish-latest:
@echo 'publish latest to $(REGISTRY)'
docker push $(REGISTRY)/$(BIN):latest
docker push $(REGISTRY)/go-api-boilerplate-$(BIN):latest

docker-publish-version:
@echo 'publish $(VERSION) to $(REGISTRY)'
Expand Down

0 comments on commit 793bfdf

Please sign in to comment.