cryptgeon/.github/workflows/docker.yml

42 lines
1.1 KiB
YAML
Raw Normal View History

2021-05-02 14:08:14 +02:00
name: ci
on:
2021-05-02 14:10:53 +02:00
workflow_dispatch:
2021-05-02 14:08:14 +02:00
push:
2021-05-02 15:12:04 +02:00
tags:
- "v*.*.*"
2021-05-02 14:08:14 +02:00
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
2021-05-19 11:29:33 +02:00
with:
install: true
2021-05-02 15:12:04 +02:00
- name: Docker Labels
id: meta
uses: crazy-max/ghaction-docker-meta@v2
with:
images: cupcakearmy/cryptgeon
tags: |
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
2021-05-02 18:50:43 +02:00
type=semver,pattern={{major}}
2021-05-02 14:08:14 +02:00
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
2021-05-19 11:29:33 +02:00
platforms: linux/amd64,linux/arm64
2021-05-02 14:08:14 +02:00
push: true
2021-05-02 15:12:04 +02:00
tags: ${{ steps.meta.outputs.tags }}
2021-05-02 14:08:14 +02:00
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}