Actions workflow
This commit is contained in:
parent
2cd840c20c
commit
7243ca28c0
1 changed files with 44 additions and 0 deletions
44
.github/workflows/docker-publish.yml
vendored
Normal file
44
.github/workflows/docker-publish.yml
vendored
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
name: Docker
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "main" ]
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
|
||||
env:
|
||||
IMAGE_NAME: watchyourlan
|
||||
TAGS: v0.5
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Build and Push Docker Image to ghcr.io
|
||||
uses: mr-smithers-excellent/docker-build-push@v5
|
||||
with:
|
||||
image: ${{ env.IMAGE_NAME }}
|
||||
tags: ${{ env.TAGS }}
|
||||
addLatest: true
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and Push Docker Image to docker.io
|
||||
uses: mr-smithers-excellent/docker-build-push@v5
|
||||
with:
|
||||
image: ${{ secrets.DOCKER_USERNAME }}/${{ env.IMAGE_NAME }}
|
||||
tags: ${{ env.TAGS }}
|
||||
addLatest: true
|
||||
registry: docker.io
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
Loading…
Reference in a new issue