Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable kubetest2 container logs for pull-aws-ebs-csi-driver-test-helm-chart #1871

Merged
merged 2 commits into from
Jan 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions hack/e2e/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,30 @@ if [[ "${HELM_CT_TEST}" == true ]]; then
fi
set -x
set +e

(
while true; do
if kubectl get pod ebs-csi-driver-test -n kube-system --kubeconfig "${KUBECONFIG}" &>/dev/null; then
echo "Pod found, waiting for it to become ready..."
if kubectl wait --for=condition=ready pod ebs-csi-driver-test -n kube-system --timeout=60s --kubeconfig "${KUBECONFIG}"; then
echo "Pod is ready, fetching logs..."
kubectl logs -f ebs-csi-driver-test -n kube-system -c kubetest2 --kubeconfig "${KUBECONFIG}"
fi
fi
sleep 30
done
) &
LOG_STREAM_PID=$!

KUBECONFIG="$KUBECONFIG" PATH="${BIN}:${PATH}" "${BIN}/ct" lint-and-install \
--config="${BASE_DIR}/../../tests/ct-config.yaml" \
--helm-extra-set-args="--set=image.repository=${IMAGE_NAME},image.tag=${IMAGE_TAG},node.tolerateAllTaints=false"
TEST_PASSED=$?

if kill -0 $LOG_STREAM_PID 2>/dev/null; then
kill $LOG_STREAM_PID
fi

set -e
set +x
else
Expand Down
4 changes: 2 additions & 2 deletions tests/ct-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ validate-maintainers: false
check-version-increment: false
charts:
- charts/aws-ebs-csi-driver
helm-extra-args: "--timeout 3000s"
helm-extra-args: "--timeout 600s"
upgrade: true
skip-missing-values: true
namespace: kube-system
release-label: release
kubectl-timeout: 3000s
kubectl-timeout: 600s
skip-clean-up: false
print-logs: true
debug: true
Loading