Escape error in archived thread #453
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Build | |
on: | |
release: | |
types: | |
- published | |
push: | |
tags: | |
branches: | |
- main | |
- dev | |
jobs: | |
docker-build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Wait for checks to succeed | |
uses: lewagon/wait-on-check-action@master | |
with: | |
ref: ${{ github.ref }} | |
check-name: 'Docker build' | |
running-workflow-name: 'Verify' | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
allowed-conclusions: success | |
- uses: actions/checkout@v4 | |
- uses: gradle/wrapper-validation-action@v3 | |
- name: Build Image | |
run: docker build . -f docker/Dockerfile -t ghcr.io/rainbowdashlabs/reputation-bot:${{ github.sha }} | |
- name: Login to Registry | |
run: echo ${{ secrets.GITHUB_TOKEN }} | docker login -u $ --password-stdin ghcr.io | |
- name: Push image | |
run: | | |
docker push ghcr.io/rainbowdashlabs/reputation-bot:${{ github.sha }} | |
- name: Tag & Push branch image | |
run: | | |
docker image tag ghcr.io/rainbowdashlabs/reputation-bot:${{ github.sha }} ghcr.io/rainbowdashlabs/reputation-bot:${{ github.ref_name }} | |
docker push ghcr.io/rainbowdashlabs/reputation-bot:${{ github.ref_name }} | |
- name: Tag & Push latest image | |
if: github.ref_name == 'main' | |
run: | | |
docker image tag ghcr.io/rainbowdashlabs/reputation-bot:${{ github.sha }} ghcr.io/rainbowdashlabs/reputation-bot:latest | |
docker push ghcr.io/rainbowdashlabs/reputation-bot:latest |