Skip to content

Commit

Permalink
Merge pull request #59 from cthit/workflow
Browse files Browse the repository at this point in the history
Add ghcr build workflow
  • Loading branch information
lutches authored Mar 5, 2024
2 parents 4bffdf7 + 8dadd47 commit 7efa159
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build and push Docker image

on:
push:
branches: [master]
pull_request:
branches: [master]

jobs:
build:
name: Build docker container

runs-on: ubuntu-latest

permissions:
packages: write

steps:
- uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to GitHub Container Registry
if: ${{ github.ref == 'refs/heads/master' }}
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build Docker image (and push on master)
uses: docker/[email protected]
with:
push: ${{ github.ref == 'refs/heads/master' }}
context: ./frontend
tags: ghcr.io/cthit/findit:latest

0 comments on commit 7efa159

Please sign in to comment.