Skip to content

Commit

Permalink
ci: add docker build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
lconsuegra committed Apr 2, 2024
1 parent 02021e2 commit 37ef4c7
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/ghcr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Build a Docker image and publish it to GHCR

on:
push:
tags:
- '*'

jobs:
build-and-push:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Log in to the Container registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@v3
with:
context: .
push: true
tags: ghcr.io/${{ github.repository }}:${{ github.ref_name }}

0 comments on commit 37ef4c7

Please sign in to comment.