forked from ArcadeData/arcadedb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add release workflow for cutting tagged images to our registries
Added a new `release` workflow that cuts a GitHub release for the given tag (input from user), and builds and pushes the tag to GHCR and SSF registries.
- Loading branch information
Showing
2 changed files
with
67 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: docker | ||
name: dev | ||
|
||
on: | ||
push: | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
name: release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
tag: | ||
required: true | ||
type: string | ||
description: "Tag to be released, without leading 'v' (will be added for git tag but omitted from image tag). Ex: 1.0.0-rc1, 1.0.0" | ||
|
||
env: | ||
GHCR_REGISTRY: ghcr.io | ||
GHCR_IMAGE: raft-tech/arcadedb | ||
SSF_REGISTRY: nexus.ssf.sclzdev.net | ||
SSF_IMAGE: raft/arcadedb | ||
IB_REGISTRY: registry1.dso.mil | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Login to GHCR | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ${{ env.GHCR_REGISTRY }} | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GHCR_PAT }} | ||
|
||
- name: Login to SSF Nexus | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ${{ env.SSF_REGISTRY }} | ||
username: ${{ secrets.SSF_REGISTRY_USER }} | ||
password: ${{ secrets.SSF_REGISTRY_PASS }} | ||
|
||
- name: Login to Iron Bank | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ${{ env.IB_REGISTRY }} | ||
username: ${{ secrets.IB_USER }} | ||
password: ${{ secrets.IB_PASS }} | ||
|
||
- name: Build and push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ env.GHCR_REGISTRY }}/${{ env.GHCR_IMAGE }}:${{ inputs.tag }} | ||
${{ env.SSF_REGISTRY }}/${{ env.SSF_IMAGE }}:${{ inputs.tag }} | ||
- name: Create Release | ||
uses: ncipollo/release-action@v1 | ||
with: | ||
generateReleaseNotes: true | ||
tag: v${{ inputs.tag }} |