Skip to content

chore: release 2.1.0 #52

chore: release 2.1.0

chore: release 2.1.0 #52

Workflow file for this run

---
name: docker
"on":
push:
branches:
- master
tags:
- v*
pull_request:
branches:
- master
workflow_dispatch:
jobs:
docker:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- platform: linux/amd64
arch: amd64
- platform: linux/arm64
arch: arm64
steps:
- name: Checkout source
id: source
uses: actions/checkout@v4
- name: Install java
id: java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 18
- name: Download mods
id: packwiz
run: make server
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: |
crafthippie/boergers
quay.io/crafthippie/boergers
ghcr.io/crafthippie/boergers
labels: |
org.opencontainers.image.vendor=Crafthippie
maintainer=Thomas Boerger <[email protected]>
tags: |
type=ref,event=pr
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
flavor: |
suffix=-${{ matrix.arch }}
- name: Setup qemu
id: qemu
uses: docker/setup-qemu-action@v3
- name: Setup buildx
id: buildx
uses: docker/setup-buildx-action@v3
- name: Hub login
id: login1
uses: docker/login-action@v3
if: github.event_name != 'pull_request'
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Quay login
id: login2
uses: docker/login-action@v3
if: github.event_name != 'pull_request'
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
- name: Ghcr login
id: login3
uses: docker/login-action@v3
if: github.event_name != 'pull_request'
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build image
id: publish
uses: docker/build-push-action@v6
with:
builder: ${{ steps.buildx.outputs.name }}
context: .
provenance: false
file: docker/Dockerfile.${{ matrix.arch }}
platforms: ${{ matrix.platform }}
push: ${{ github.event_name != 'pull_request' }}
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ steps.meta.outputs.tags }}
manifest:
runs-on: ubuntu-latest
needs: docker
steps:
- name: Checkout source
id: source
uses: actions/checkout@v4
- name: Hub tags
id: hubTags
uses: docker/metadata-action@v5
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: crafthippie/boergers
tags: |
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
- name: Hub manifest
id: hub
if: github.event_name != 'pull_request'
uses: actionhippie/manifest@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
platforms: linux/amd64,linux/arm64
template: crafthippie/boergers:VERSION-ARCH
target: ${{ steps.hubTags.outputs.tags }}
ignore_missing: true
- name: Quay tags
id: quayTags
uses: docker/metadata-action@v5
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: quay.io/crafthippie/boergers
tags: |
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
- name: Quay manifest
id: quay
if: github.event_name != 'pull_request'
uses: actionhippie/manifest@v1
with:
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
platforms: linux/amd64,linux/arm64
template: quay.io/crafthippie/boergers:VERSION-ARCH
target: ${{ steps.quayTags.outputs.tags }}
ignore_missing: true
- name: Ghcr tags
id: ghcrTags
uses: docker/metadata-action@v5
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
images: ghcr.io/crafthippie/boergers
tags: |
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
- name: Ghcr manifest
id: ghcr
if: github.event_name != 'pull_request'
uses: actionhippie/manifest@v1
with:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
platforms: linux/amd64,linux/arm64
template: ghcr.io/crafthippie/boergers:VERSION-ARCH
target: ${{ steps.ghcrTags.outputs.tags }}
ignore_missing: true
readme:
runs-on: ubuntu-latest
needs: docker
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Hub readme
id: hub
if: github.event_name != 'pull_request'
uses: actionhippie/pushrm@v1
with:
provider: dockerhub
target: crafthippie/boergers
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
description: Boergers
readme: README.md
- name: Quay readme
id: quay
if: github.event_name != 'pull_request'
uses: actionhippie/pushrm@v1
with:
provider: quay
target: quay.io/crafthippie/boergers
apikey: ${{ secrets.QUAY_APIKEY }}
readme: README.md
...