diff --git a/.gitea/workflows/docker-publish.yml b/.gitea/workflows/docker-publish.yml new file mode 100644 index 0000000..ef21155 --- /dev/null +++ b/.gitea/workflows/docker-publish.yml @@ -0,0 +1,59 @@ +name: Docker + +on: + push: + branches: [master] + +env: + REGISTRY: gitea.coracle.social + +jobs: + build-and-push-image: + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + strategy: + matrix: + include: + - component: frontend + image: coracle/caravel-frontend + context: frontend + - component: backend + image: coracle/caravel-backend + context: backend + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Log in to the Container registry + uses: docker/login-action@v3 + with: + registry: ${{ env.REGISTRY }} + username: hodlbod + password: ${{ secrets.PACKAGE_TOKEN }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v5 + with: + images: ${{ env.REGISTRY }}/${{ matrix.image }} + tags: | + type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }} + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + with: + driver: docker-container + + - name: Build and push Docker image + id: push + uses: docker/build-push-action@v5 + with: + context: ${{ matrix.context }} + push: true + platforms: linux/amd64,linux/arm64 + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} diff --git a/README.md b/README.md index a37bbbd..818dc19 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ docker run -it \ -v ./config:/app/config \ -v ./media:/app/media \ -v ./data:/app/data \ - ghcr.io/coracle-social/zooid + gitea.coracle.social/coracle/zooid ``` ### 2. Configure the backend