Skip to content

Commit 4973447

Browse files
committed
Added retries to getting k8s logs in CI.
1 parent 9c2a9c1 commit 4973447

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

.github/workflows/pipeline.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -167,12 +167,16 @@ jobs:
167167
dotnet test ./tests/Contrast.K8s.AgentOperator.FunctionalTests/Contrast.K8s.AgentOperator.FunctionalTests.csproj
168168
shell: bash
169169
- name: Dump Operator Logs
170+
uses: nick-fields/retry@v2
170171
if: ${{ always() }}
171-
run: |
172-
set -xe
173-
kubectl --namespace testing-agent-operator get deployment contrast-agent-operator -o yaml
174-
kubectl --namespace testing-agent-operator logs deployment/contrast-agent-operator
175-
shell: bash
172+
with:
173+
timeout_minutes: 10
174+
max_attempts: 5
175+
command: |
176+
set -xe
177+
kubectl --namespace testing-agent-operator get deployment contrast-agent-operator -o yaml
178+
kubectl --namespace testing-agent-operator logs deployment/contrast-agent-operator
179+
shell: bash
176180
test-manifests:
177181
runs-on: ubuntu-latest
178182
needs:

0 commit comments

Comments
 (0)