From f294dd421126be758569b6fc9d9834f85251a0d1 Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 07:45:31 +0100 Subject: [PATCH 1/6] Update show-pod-logs.sh --- testdata/e2e/show-pod-logs.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testdata/e2e/show-pod-logs.sh b/testdata/e2e/show-pod-logs.sh index 874c141..879e7aa 100755 --- a/testdata/e2e/show-pod-logs.sh +++ b/testdata/e2e/show-pod-logs.sh @@ -3,5 +3,5 @@ set -e echo "## Pod adguardhome-origin logs" >> $GITHUB_STEP_SUMMARY echo '```' >> $GITHUB_STEP_SUMMARY -kubectl logs -l app.kubernetes.io/instance=java-truststore-injection-webhook >> $GITHUB_STEP_SUMMARY +kubectl logs -l app.kubernetes.io/instance=java-truststore-injection-webhook --namespace jti >> $GITHUB_STEP_SUMMARY echo '```' >> $GITHUB_STEP_SUMMARY From a54f87b9afd04aebd81647027cd708ff3e8aea85 Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 07:54:03 +0100 Subject: [PATCH 2/6] Update build.yml --- .github/workflows/build.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 178d3dc..91f269a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -74,10 +74,18 @@ jobs: java-version: '17' - name: 🛃 Test generated trust stores + id: test_generated_stores run: ./testdata/e2e/testConfigMaps.sh + continue-on-error: true - - name: 📜 Show pod logs + - name: 📜 Print pod logs run: ./testdata/e2e/show-pod-logs.sh + + - name: 🛃 Fail if 'Test generated trust stores' failed + if: steps.test_generated_stores.outcome=='failure' + run: | + echo "Step 'Test generated trust stores' failed: Check 'Test generated trust storesr' and 'Print pod logs' as well as the job summary for errors" + exit 1 helm: name: Helm Checks From 0478759fe918b6d9f9c41814b5d824f2a259ea66 Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 07:55:05 +0100 Subject: [PATCH 3/6] Update build.yml --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 91f269a..da9ce03 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -81,7 +81,7 @@ jobs: - name: 📜 Print pod logs run: ./testdata/e2e/show-pod-logs.sh - - name: 🛃 Fail if 'Test generated trust stores' failed + - name: ❌ Fail if 'Test generated trust stores' failed if: steps.test_generated_stores.outcome=='failure' run: | echo "Step 'Test generated trust stores' failed: Check 'Test generated trust storesr' and 'Print pod logs' as well as the job summary for errors" From 14260b4e89451d39d6fb7704ae09d9dc92b82fdc Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 08:00:03 +0100 Subject: [PATCH 4/6] Update installChart.sh --- testdata/e2e/installChart.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/testdata/e2e/installChart.sh b/testdata/e2e/installChart.sh index 086ffac..2856986 100755 --- a/testdata/e2e/installChart.sh +++ b/testdata/e2e/installChart.sh @@ -5,5 +5,7 @@ helm upgrade --install java-truststore-injection-webhook chart \ --namespace jti \ --create-namespace \ -f testdata/e2e/e2e-values.yaml \ - --atomic + --atomic \ + --wait \ + --timeout 60 kubectl get pods -n jti From 594b720b07d50de777ac1f446021f77c16646e51 Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 08:04:06 +0100 Subject: [PATCH 5/6] Update installChart.sh --- testdata/e2e/installChart.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testdata/e2e/installChart.sh b/testdata/e2e/installChart.sh index 2856986..f5de10e 100755 --- a/testdata/e2e/installChart.sh +++ b/testdata/e2e/installChart.sh @@ -7,5 +7,5 @@ helm upgrade --install java-truststore-injection-webhook chart \ -f testdata/e2e/e2e-values.yaml \ --atomic \ --wait \ - --timeout 60 + --timeout 60s kubectl get pods -n jti From 2aac07b8da4bddf8f8bf941a9f9d152198663b34 Mon Sep 17 00:00:00 2001 From: Marc Brugger Date: Mon, 13 Nov 2023 08:12:28 +0100 Subject: [PATCH 6/6] Update testConfigMaps.sh --- testdata/e2e/testConfigMaps.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testdata/e2e/testConfigMaps.sh b/testdata/e2e/testConfigMaps.sh index 729bd26..ed842cb 100755 --- a/testdata/e2e/testConfigMaps.sh +++ b/testdata/e2e/testConfigMaps.sh @@ -1,6 +1,6 @@ #!/bin/bash set -e - +kubectl get svc -n jti echo "💾 Creating ConfigMaps" kubectl apply -n jti -f testdata/e2e/testConfigMaps.yaml