mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-30 17:23:40 -04:00
run release build only if MY_TOKEN secret is set and not empty
This commit is contained in:
parent
c1401cf6db
commit
f48d5bfedf
13
.github/workflows/docker.yml
vendored
13
.github/workflows/docker.yml
vendored
@ -6,9 +6,22 @@ env:
|
|||||||
REGISTRY: ghcr.io
|
REGISTRY: ghcr.io
|
||||||
IMAGE_NAME: ${{ github.repository }}
|
IMAGE_NAME: ${{ github.repository }}
|
||||||
jobs:
|
jobs:
|
||||||
|
check-token:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
outputs:
|
||||||
|
token: ${{ steps.token.outputs.defined }}
|
||||||
|
steps:
|
||||||
|
- id: token
|
||||||
|
env:
|
||||||
|
MY_TOKEN: ${{ secrets.MY_TOKEN }}
|
||||||
|
if: "${{ env.MY_TOKEN != '' }}"
|
||||||
|
run: echo "::set-output name=defined::true"
|
||||||
|
|
||||||
build:
|
build:
|
||||||
name: Release
|
name: Release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
needs: [check-token]
|
||||||
|
if: needs.check-token.outputs.token == 'true'
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
Loading…
x
Reference in New Issue
Block a user