diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml new file mode 100644 index 0000000..37e1b91 --- /dev/null +++ b/.gitea/workflows/ci.yaml @@ -0,0 +1,27 @@ +name: Build and Deploy + +on: + push: + branches: [master] + +jobs: + build-and-push: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Docker login + uses: docker/login-action@v2 + with: + registry: ${{ secrets.REGISTRY_URL }} + username: ${{ secrets.REGISTRY_USER }} + password: ${{ secrets.REGISTRY_PASSWORD }} + + - name: Build and push + uses: docker/build-push-action@v4 + with: + context: . + push: true + tags: | + ${{ secrets.REGISTRY_URL }}/${{ vars.GITEA_REPOSITORY }}:${{ github.sha }} + ${{ secrets.REGISTRY_URL }}/${{ vars.GITEA_REPOSITORY }}:latest