Skip to content

Commit

Permalink
Create release.yml
Browse files Browse the repository at this point in the history
Fixes #257
  • Loading branch information
oxisto authored Dec 20, 2023
1 parent e86118a commit 627bfac
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Publish Docker image

on:
release:
types: [published]

jobs:
push_to_registries:
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Login to GHCR
uses: docker/login-action@v5
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract tags
id: meta
uses: docker/metadata-action@v5
with:
images: |
ghcr.io/oxisto/money-gopher
tags: |
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}

0 comments on commit 627bfac

Please sign in to comment.