Skip to content

Commit

Permalink
Add workflow to build Docker image on tags
Browse files Browse the repository at this point in the history
  • Loading branch information
POTIER Frederic authored and bpedersen2 committed Aug 20, 2024
1 parent afd6b78 commit 978eb53
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Build release

on:
release:
tags:
- 'v*'
types:
- created

jobs:
build-release:
name: Build release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Login to GHCR
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Create image tags
id: meta
uses: docker/metadata-action@v5
with:
images: ghcr.io/scicatproject/landingpageserver
flavor: latest=false
tags: |
type=raw,value=stable
type=ref,event=tag
- name: Build and push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64/v8
push: true
tags: ${{ steps.meta.outputs.tags }}

0 comments on commit 978eb53

Please sign in to comment.