Skip to content

Commit

Permalink
ci: use 'concurrency' feature in fuzzing.yml
Browse files Browse the repository at this point in the history
It looks like we just missed the fuzzing.yml workflow when worked on
adding this feature to our CI process in tarantool#6446.

Follows up tarantool/tarantool-qa#100

NO_DOC=ci
NO_CHANGELOG=ci
NO_TEST=ci
  • Loading branch information
ylobankov committed Mar 18, 2022
1 parent 88b46b4 commit dbaf03d
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/fuzzing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,26 @@ on:
pull_request:
types: [opened, reopened, synchronize, labeled]

concurrency:
# Update of a developer branch cancels the previously scheduled workflow
# run for this branch. However, the 'master' branch, release branch (1.10,
# 2.8, etc.), and tag workflow runs are never canceled.
#
# We use a trick here: define the concurrency group as 'workflow run ID' +
# 'workflow run attempt' because it is a unique combination for any run.
# So it effectively discards grouping.
#
# Important: we cannot use `github.sha` as a unique identifier because
# pushing a tag may cancel a run that works on a branch push event.
group: ${{ (
github.ref == 'refs/heads/master' ||
github.ref == 'refs/heads/1.10' ||
startsWith(github.ref, 'refs/heads/2.') ||
startsWith(github.ref, 'refs/tags/')) &&
format('{0}-{1}', github.run_id, github.run_attempt) ||
format('{0}-{1}', github.workflow, github.ref) }}
cancel-in-progress: true

jobs:
fuzzing:
# Run on push to the 'master' and release branches of tarantool/tarantool
Expand Down

0 comments on commit dbaf03d

Please sign in to comment.