Skip to content

Commit 159f6fd

Browse files
authored
Merge pull request #1628 from splunk/CSPL-4282-fix-pipeline-misconfiguration
CSPL-4282 fix pipeline race condition and misconfiguration
2 parents 64ce364 + f39eefb commit 159f6fd

19 files changed

+212
-55
lines changed
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: 'Set EKS Test Cluster Name'
2+
description: 'Generate a shortened, standardized EKS test cluster name'
3+
inputs:
4+
test-type:
5+
description: 'Type of test (e.g., smoke, integration)'
6+
required: true
7+
platform:
8+
description: 'Platform variant (e.g., distroless, arm-ubuntu, arm-rhel, arm-al2023, helm, namespace, nightly, manual, or empty for standard)'
9+
required: false
10+
default: ''
11+
test-name:
12+
description: 'Test name from matrix (e.g., basic, managerappframeworkc3)'
13+
required: true
14+
run-id:
15+
description: 'GitHub run ID for uniqueness'
16+
required: true
17+
outputs:
18+
cluster-name:
19+
description: 'The generated cluster name'
20+
value: ${{ steps.generate-name.outputs.cluster_name }}
21+
runs:
22+
using: "composite"
23+
steps:
24+
- name: Generate cluster name
25+
id: generate-name
26+
shell: bash
27+
run: |
28+
TEST_NAME="${{ inputs.test-name }}"
29+
30+
# Shorten long test names
31+
case "$TEST_NAME" in
32+
managerappframeworkc3) TEST_NAME="mgr-appfw-c3" ;;
33+
managerappframeworkm4) TEST_NAME="mgr-appfw-m4" ;;
34+
appframeworksS1) TEST_NAME="appfw-s1" ;;
35+
managersecret) TEST_NAME="mgr-secret" ;;
36+
managermc) TEST_NAME="mgr-mc" ;;
37+
esac
38+
39+
# Build cluster name based on platform
40+
if [ -z "${{ inputs.platform }}" ]; then
41+
# Standard platform (no platform suffix)
42+
CLUSTER_NAME="eks-test-${{ inputs.test-type }}-${TEST_NAME}-${{ inputs.run-id }}"
43+
else
44+
# Platform-specific
45+
CLUSTER_NAME="eks-test-${{ inputs.test-type }}-${{ inputs.platform }}-${TEST_NAME}-${{ inputs.run-id }}"
46+
fi
47+
48+
echo "cluster_name=${CLUSTER_NAME}" >> $GITHUB_OUTPUT
49+
echo "Generated cluster name: ${CLUSTER_NAME}"
50+

.github/workflows/arm-AL2023-build-test-push-workflow-AL2023.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,11 +146,19 @@ jobs:
146146
ARM64: "true"
147147
GRAVITON_TESTING: "true"
148148
steps:
149-
- name: Set Test Cluster Name
150-
run: |
151-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
152149
- name: Chekcout code
153150
uses: actions/checkout@v2
151+
- name: Set Test Cluster Name
152+
id: set-cluster-name
153+
uses: ./.github/actions/set-cluster-name
154+
with:
155+
test-type: smoke
156+
platform: arm-al2023
157+
test-name: ${{ matrix.test }}
158+
run-id: ${{ github.run_id }}
159+
- name: Export cluster name to environment
160+
run: |
161+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
154162
- name: Dotenv Action
155163
id: dotenv
156164
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/arm-AL2023-int-test-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ jobs:
9494
ARM64: "true"
9595
GRAVITON_TESTING: "true"
9696
steps:
97-
- name: Set Test Cluster Name
98-
run: |
99-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
10097
- name: Set Test Cluster Nodes and Parallel Runs
10198
run: >-
10299
if grep -q "appframework" <<< "${{ matrix.test }}"; then
@@ -105,6 +102,17 @@ jobs:
105102
fi
106103
- name: Checkcout code
107104
uses: actions/checkout@v2
105+
- name: Set Test Cluster Name
106+
id: set-cluster-name
107+
uses: ./.github/actions/set-cluster-name
108+
with:
109+
test-type: integration
110+
platform: arm-al2023
111+
test-name: ${{ matrix.test }}
112+
run-id: ${{ github.run_id }}
113+
- name: Export cluster name to environment
114+
run: |
115+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
108116
- name: Dotenv Action
109117
id: dotenv
110118
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/arm-RHEL-build-test-push-workflow.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: ARM RHEL Integration Test WorkFlow
1+
name: ARM RHEL Smoke Test WorkFlow
22
permissions:
33
contents: read
44
packages: write
@@ -54,7 +54,7 @@ jobs:
5454
export BASE_IMAGE_VERSION=9.5
5555
export IMG=${{ secrets.ECR_REPOSITORY }}/${{ env.SPLUNK_OPERATOR_IMAGE_NAME }}:$GITHUB_SHA
5656
make docker-buildx PLATFORMS=$PLATFORMS BASE_IMAGE=$BASE_IMAGE BASE_IMAGE_VERSION=$BASE_IMAGE_VERSION IMG=$IMG
57-
int-tests-arm-rhel:
57+
smoke-tests-arm-rhel:
5858
strategy:
5959
fail-fast: false
6060
matrix:
@@ -79,8 +79,8 @@ jobs:
7979
SPLUNK_OPERATOR_IMAGE_NAME: splunk/splunk-operator
8080
SPLUNK_OPERATOR_IMAGE_FILENAME: splunk-operator
8181
TEST_FOCUS: "${{ matrix.test }}"
82-
# This regex matches any string not containing integration keyword
83-
TEST_TO_SKIP: "^(?:[^i]+|i(?:$|[^n]|n(?:$|[^t]|t(?:$|[^e]|e(?:$|[^g]|g(?:$|[^r]|r(?:$|[^a]|a(?:$|[^t]|t(?:$|[^i]|i(?:$|[^o]|o(?:$|[^n])))))))))))*$"
82+
# This regex matches any string not containing smoke keyword
83+
TEST_TO_SKIP: "^(?:[^s]+|s(?:$|[^m]|m(?:$|[^o]|o(?:$|[^k]|k(?:$|[^e])))))*$"
8484
TEST_CLUSTER_PLATFORM: eks
8585
EKS_VPC_PRIVATE_SUBNET_STRING: ${{ secrets.EKS_VPC_PRIVATE_SUBNET_STRING }}
8686
EKS_VPC_PUBLIC_SUBNET_STRING: ${{ secrets.EKS_VPC_PUBLIC_SUBNET_STRING }}
@@ -94,9 +94,6 @@ jobs:
9494
ARM64: "true"
9595
GRAVITON_TESTING: "true"
9696
steps:
97-
- name: Set Test Cluster Name
98-
run: |
99-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
10097
- name: Set Test Cluster Nodes and Parallel Runs
10198
run: >-
10299
if grep -q "appframework" <<< "${{ matrix.test }}"; then
@@ -105,6 +102,17 @@ jobs:
105102
fi
106103
- name: Checkcout code
107104
uses: actions/checkout@v2
105+
- name: Set Test Cluster Name
106+
id: set-cluster-name
107+
uses: ./.github/actions/set-cluster-name
108+
with:
109+
test-type: smoke
110+
platform: arm-rhel
111+
test-name: ${{ matrix.test }}
112+
run-id: ${{ github.run_id }}
113+
- name: Export cluster name to environment
114+
run: |
115+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
108116
- name: Dotenv Action
109117
id: dotenv
110118
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359
@@ -180,7 +188,7 @@ jobs:
180188
sudo snap install kustomize
181189
mkdir -p ./bin
182190
cp /snap/bin/kustomize ./bin/kustomize
183-
- name: Run Integration test
191+
- name: Run smoke test
184192
run: |
185193
make int-test
186194
- name: Collect Test Logs

.github/workflows/arm-RHEL-int-test-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ jobs:
9494
ARM64: "true"
9595
GRAVITON_TESTING: "true"
9696
steps:
97-
- name: Set Test Cluster Name
98-
run: |
99-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
10097
- name: Set Test Cluster Nodes and Parallel Runs
10198
run: >-
10299
if grep -q "appframework" <<< "${{ matrix.test }}"; then
@@ -105,6 +102,17 @@ jobs:
105102
fi
106103
- name: Checkcout code
107104
uses: actions/checkout@v2
105+
- name: Set Test Cluster Name
106+
id: set-cluster-name
107+
uses: ./.github/actions/set-cluster-name
108+
with:
109+
test-type: integration
110+
platform: arm-rhel
111+
test-name: ${{ matrix.test }}
112+
run-id: ${{ github.run_id }}
113+
- name: Export cluster name to environment
114+
run: |
115+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
108116
- name: Dotenv Action
109117
id: dotenv
110118
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/arm-Ubuntu-build-test-push-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,11 +146,19 @@ jobs:
146146
ARM64: "true"
147147
GRAVITON_TESTING: "true"
148148
steps:
149-
- name: Set Test Cluster Name
150-
run: |
151-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
152149
- name: Chekcout code
153150
uses: actions/checkout@v2
151+
- name: Set Test Cluster Name
152+
id: set-cluster-name
153+
uses: ./.github/actions/set-cluster-name
154+
with:
155+
test-type: smoke
156+
platform: arm-ubuntu
157+
test-name: ${{ matrix.test }}
158+
run-id: ${{ github.run_id }}
159+
- name: Export cluster name to environment
160+
run: |
161+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
154162
- name: Dotenv Action
155163
id: dotenv
156164
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/arm-Ubuntu-int-test-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ jobs:
9494
ARM64: "true"
9595
GRAVITON_TESTING: "true"
9696
steps:
97-
- name: Set Test Cluster Name
98-
run: |
99-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
10097
- name: Set Test Cluster Nodes and Parallel Runs
10198
run: >-
10299
if grep -q "appframework" <<< "${{ matrix.test }}"; then
@@ -105,6 +102,17 @@ jobs:
105102
fi
106103
- name: Checkcout code
107104
uses: actions/checkout@v2
105+
- name: Set Test Cluster Name
106+
id: set-cluster-name
107+
uses: ./.github/actions/set-cluster-name
108+
with:
109+
test-type: integration
110+
platform: arm-ubuntu
111+
test-name: ${{ matrix.test }}
112+
run-id: ${{ github.run_id }}
113+
- name: Export cluster name to environment
114+
run: |
115+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
108116
- name: Dotenv Action
109117
id: dotenv
110118
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/build-test-push-workflow.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -190,11 +190,18 @@ jobs:
190190
CLUSTER_WIDE: "true"
191191
DEPLOYMENT_TYPE: ""
192192
steps:
193-
- name: Set Test Cluster Name
194-
run: |
195-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
196193
- name: Chekcout code
197194
uses: actions/checkout@v2
195+
- name: Set Test Cluster Name
196+
id: set-cluster-name
197+
uses: ./.github/actions/set-cluster-name
198+
with:
199+
test-type: smoke
200+
test-name: ${{ matrix.test }}
201+
run-id: ${{ github.run_id }}
202+
- name: Export cluster name to environment
203+
run: |
204+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
198205
- name: Dotenv Action
199206
id: dotenv
200207
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/distroless-build-test-push-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,11 +191,19 @@ jobs:
191191
CLUSTER_WIDE: "true"
192192
DEPLOYMENT_TYPE: ""
193193
steps:
194-
- name: Set Test Cluster Name
195-
run: |
196-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
197194
- name: Chekcout code
198195
uses: actions/checkout@v2
196+
- name: Set Test Cluster Name
197+
id: set-cluster-name
198+
uses: ./.github/actions/set-cluster-name
199+
with:
200+
test-type: smoke
201+
platform: distroless
202+
test-name: ${{ matrix.test }}
203+
run-id: ${{ github.run_id }}
204+
- name: Export cluster name to environment
205+
run: |
206+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
199207
- name: Dotenv Action
200208
id: dotenv
201209
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

.github/workflows/distroless-int-test-workflow.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,6 @@ jobs:
8888
CLUSTER_WIDE: "true"
8989
DEPLOYMENT_TYPE: ""
9090
steps:
91-
- name: Set Test Cluster Name
92-
run: |
93-
echo "TEST_CLUSTER_NAME=eks-integration-test-cluster-${{ matrix.test }}-$GITHUB_RUN_ID" >> $GITHUB_ENV
9491
- name: Set Test Cluster Nodes and Parallel Runs
9592
run: >-
9693
if grep -q "appframework" <<< "${{ matrix.test }}"; then
@@ -99,6 +96,17 @@ jobs:
9996
fi
10097
- name: Checkcout code
10198
uses: actions/checkout@v2
99+
- name: Set Test Cluster Name
100+
id: set-cluster-name
101+
uses: ./.github/actions/set-cluster-name
102+
with:
103+
test-type: integration
104+
platform: distroless
105+
test-name: ${{ matrix.test }}
106+
run-id: ${{ github.run_id }}
107+
- name: Export cluster name to environment
108+
run: |
109+
echo "TEST_CLUSTER_NAME=${{ steps.set-cluster-name.outputs.cluster-name }}" >> $GITHUB_ENV
102110
- name: Dotenv Action
103111
id: dotenv
104112
uses: falti/dotenv-action@d4d12eaa0e1dd06d5bdc3d7af3bf4c8c93cb5359

0 commit comments

Comments
 (0)