Skip to content

Commit

Permalink
Building package only if it's tagged.
Browse files Browse the repository at this point in the history
  • Loading branch information
alee-ntap committed Nov 27, 2023
1 parent 8df8887 commit dd74c7e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/build_pkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ on:
message:
type: string
default: ""

env:
GH_TOKEN: ${{ github.token }}

jobs:
source:
name: source package
Expand All @@ -51,6 +55,11 @@ jobs:
repository: ${{ inputs.repository }}
ref: ${{ inputs.ref }}
path: input
- name: Check if workflow is triggered by a tag
if: startsWith(github.ref, 'refs/tags/')
run: echo "Workflow is triggered by a tag"
else:
run: echo "Not triggered by tag. Cancel workflow." && gh run cancel ${{ github.run_id }}
- name: pull build container
run: podman pull "${{ inputs.build_container }}:amd64"
- name: fetch dependencies
Expand Down

0 comments on commit dd74c7e

Please sign in to comment.