Skip to content

shisui release image #1

shisui release image

shisui release image #1

Workflow file for this run

name: shisui release image
on:
release:
types: [created]
defaults:
run:
shell: bash
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: write
env:
releaseBuild: ${{ github.event_name == 'push' && contains(github.ref, 'refs/tags/') }}
REGISTRY: ghcr.io
TAG_NAME: ${{ github.ref | replace('refs/tags/', '') }}

Check failure on line 21 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / shisui release image

Invalid workflow file

The workflow is not valid. .github/workflows/release.yml (Line: 21, Col: 13): Unexpected symbol: '|'. Located at position 12 within expression: github.ref | replace('refs/tags/', '') .github/workflows/release.yml (Line: 28, Col: 9): Unrecognized named-value: 'env'. Located at position 1 within expression: env.releaseBuild == 'true'

Check failure on line 21 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / shisui release image

Invalid workflow file

The workflow is not valid. .github/workflows/release.yml (Line: 21, Col: 13): Unexpected symbol: '|'. Located at position 12 within expression: github.ref | replace('refs/tags/', '') .github/workflows/release.yml (Line: 28, Col: 9): Unrecognized named-value: 'env'. Located at position 1 within expression: env.releaseBuild == 'true'
jobs:
push_image_to_github:
name: Push Docker image to Github
runs-on: ubuntu-latest
permissions: write-all
if: ${{ env.releaseBuild == 'true' }} # Only run this job if releaseBuild is true
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ env.TAG_NAME }}