Create README.md #50
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Master branch push | |
on: | |
push: | |
branches: [ master ] | |
jobs: | |
image: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: PrepareReg Names | |
run: | | |
echo IMAGE_REPOSITORY=$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV | |
echo IMAGE_TAG=$(echo ${{ github.ref }} | tr '[:upper:]' '[:lower:]' | awk '{split($0,a,"/"); print a[3]}') >> $GITHUB_ENV | |
- name: Set up Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@v1 | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: 1.18 | |
- name: GHCR Login | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: GHCR Push | |
uses: docker/build-push-action@v2 | |
with: | |
push: true | |
tags: | | |
ghcr.io/${{ env.IMAGE_REPOSITORY }}:${{ github.sha }} |