diff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.yml new file mode 100644 index 0000000..386092d --- /dev/null +++ b/.github/workflows/docker-publish.yml @@ -0,0 +1,30 @@ +name: Build and Publish Docker Image + +on: + push: + branches: + - main + workflow_dispatch: + +jobs: + build-and-publish: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Log in to GitHub 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@v5 + with: + context: . + file: ./Dockerfile + push: true + tags: ghcr.io/${{ github.repository_owner }}/${{ github.repository }}:latest diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..a1eb3e8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,3 @@ +FROM thehale/python-poetry:1.8.5-py3.13-slim AS base + +RUN apt-get update && apt-get -y install libpq5