Skip to content

Commit 8fd5e81

Browse files
committed
Cancel running builds
Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
1 parent d347fce commit 8fd5e81

30 files changed

Lines changed: 60 additions & 150 deletions

.github/workflows/.container.template.j2

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: <{ repository_path }>-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: <{ repository_path }>-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/almalinux-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/almalinux-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/almalinux-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/amazonlinux-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/amazonlinux-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/amazonlinux-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/archlinux-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/archlinux-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/archlinux-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/busybox-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/busybox-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/busybox-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/centos-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/centos-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/centos-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/centos-stream-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/centos-stream-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/centos-stream-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/consul-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/consul-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/consul-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/debian-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/debian-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/debian-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

.github/workflows/etcd-v2-containers.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ env:
2222

2323

2424
concurrency:
25-
# Concurrency is defined in a way that concurrent builds against branches do
26-
# not cancel previous builds.
27-
# However, for every new build against the same pull request source branch,
28-
# all older builds against that same branch get canceled.
29-
group: mirrors/etcd-v2-${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.run_id }}
25+
# New builds always cancel previous, still running, builds
26+
group: mirrors/etcd-v2-${{ github.workflow }}-${{ github.ref }}
3027
cancel-in-progress: true
3128

3229
jobs:

0 commit comments

Comments
 (0)