name: Build and push image on: push: branches: - master jobs: build-and-push: # Use the runner's default job image as-is: it's pre-configured with # DOCKER_HOST pointing at the runner's dind sidecar (and privileged # access). Overriding `container:` here loses that configuration. runs-on: docker steps: - name: Checkout uses: actions/checkout@v4 - name: Log in to Forgejo registry run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login git.rosenvold.tech -u "${{ github.actor }}" --password-stdin - name: Build image run: | docker build \ -t git.rosenvold.tech/lucas/rosenvold-core:latest \ -t git.rosenvold.tech/lucas/rosenvold-core:${{ github.sha }} \ -f Containerfile . - name: Push image run: docker push git.rosenvold.tech/lucas/rosenvold-core --all-tags