Docker-Release #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker-Release | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
releaseVersion: | ||
description: "Default version to use when preparing a release." | ||
required: true | ||
default: "X.Y.Z" | ||
developmentVersion: | ||
description: "Default version to use for new local working copy." | ||
required: true | ||
default: "X.Y.Z-SNAPSHOT" | ||
jobs: | ||
release-docker: | ||
Check failure on line 15 in .github/workflows/docker-release.yml
|
||
runs-on: 'ubuntu-latest' | ||
needs: | ||
- release-maven | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.releaseVersion }} | ||
fetch-depth: 1 | ||
submodules: recursive | ||
- name: Docker meta | ||
id: meta | ||
uses: docker/metadata-action@v5 | ||
with: | ||
images: | | ||
${{ github.repository }} | ||
ghcr.io/${{ github.repository }}/${{ github.event.repository.name }} | ||
tags: | | ||
type=raw,value=latest | ||
type=raw,value=${{ github.event.inputs.releaseVersion }} | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- name: Login to DockerHub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
- name: Login to GHCR | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Build and push image | ||
uses: docker/build-push-action@v5 | ||
continue-on-error: true | ||
with: | ||
context: ./openam-distribution/openam-distribution-docker | ||
file: ./openam-distribution/openam-distribution-docker/Dockerfile | ||
build-args: | | ||
VERSION=${{ github.event.inputs.releaseVersion }} | ||
platforms: linux/amd64, linux/arm64, linux/ppc64le, linux/s390x | ||
push: true | ||
tags: ${{ steps.meta.outputs.tags }} | ||
labels: ${{ steps.meta.outputs.labels }} |