Skip to content

Commit daf9482

Browse files
feat: check if support bundle contains expected files (#413)
check if we have some expected files and directories inside the generated support bundle.
1 parent 413e843 commit daf9482

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

e2e/scripts/collect-support-bundle.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,22 @@ main() {
77
return 1
88
fi
99

10+
tar -zxvf host.tar.gz
11+
if ! ls host/host-collectors/run-host/k0s-sysinfo.txt; then
12+
echo "Failed to find 'k0s sysinfo' inside the host support bundle"
13+
return 1
14+
fi
15+
1016
if ! kubectl support-bundle --output cluster.tar.gz --interactive=false --load-cluster-specs; then
1117
echo "Failed to collect cluster support bundle"
1218
return 1
1319
fi
20+
21+
tar -zxvf cluster.tar.gz
22+
if ! ls cluster/podlogs/embedded-cluster-operator; then
23+
echo "Failed to find operator logs inside the cluster support bundle"
24+
return 1
25+
fi
1426
}
1527

1628
export KUBECONFIG=/var/lib/k0s/pki/admin.conf

0 commit comments

Comments
 (0)