Skip to content

Commit 68678fa

Browse files
committed
Only run CI jobs on PRs to main and dev branch
1 parent 490790b commit 68678fa

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/push.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Install applications on Kubernets
22

33
on:
4-
push:
4+
pull_request:
55
workflow_dispatch:
66
inputs:
77
debug_enabled:
@@ -15,6 +15,8 @@ jobs:
1515
strategy:
1616
matrix:
1717
KUBECTL_VERSION: ["v1.27.0", "v1.28.0", "v1.29.0", "v1.30.0"]
18+
isMain:
19+
- ${{ contains(github.ref, 'main') }}
1820
include:
1921
- KUBECTL_VERSION: "v1.27.0"
2022
K3S_VERSION: "v1.27.14+k3s1"
@@ -25,7 +27,8 @@ jobs:
2527
- KUBECTL_VERSION: "v1.30.0"
2628
K3S_VERSION: "v1.30.1+k3s1"
2729
exclude:
28-
- KUBECTL_VERSION: ${{ github.base_ref != 'refs/heads/main' && 'v1.27.0' }}
30+
- KUBECTL_VERSION: "v1.27.0"
31+
isMain: false
2932
- KUBECTL_VERSION: ${{ github.base_ref != 'refs/heads/main' && 'v1.28.0' }}
3033
- KUBECTL_VERSION: ${{ github.base_ref != 'refs/heads/main' && 'v1.29.0' }}
3134
runs-on: self-hosted

0 commit comments

Comments
 (0)