Add automatic docker build and push

This commit is contained in:
rung 2021-02-11 22:55:14 +09:00
parent 1106321636
commit 988a18617f
1 changed files with 33 additions and 0 deletions

33
.github/workflows/dockerpush.yml vendored Normal file
View File

@ -0,0 +1,33 @@
name: docker-push
on:
push:
branches: master
jobs:
multi-registries:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v2
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
-
name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.CR_PAT }}
-
name: Build and push
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64
push: true
tags: |
ghcr.io/rung/autorecon:latest