docker-pdns/.github/workflows/docker-image.yml

55 lines
1.4 KiB
YAML
Raw Normal View History

2021-10-05 19:53:01 +02:00
name: Docker Image CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check Out Repo
uses: actions/checkout@v2
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
- name: Build and push PDNS Recursor latest
id: docker_build_recursor_latest
uses: docker/build-push-action@v2
with:
context: ./pdns-recursor
file: ./Dockerfile
builder: ${{ steps.buildx.outputs.name }}
push: true
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/pdns-recursor:latest
- name: Image digest
run: echo ${{ steps.docker_build_recursor_latest.outputs.digest }}
- name: Build and push PDNS Recursor alpine
id: docker_build_recursor_alpine
uses: docker/build-push-action@v2
with:
context: ./pdns-recursor
file: ./Dockerfile.alpine
builder: ${{ steps.buildx.outputs.name }}
push: true
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/pdns-recursor:alpine
- name: Image digest
run: echo ${{ steps.docker_build_recursor_alpine.outputs.digest }}