Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
fix(t2): classify invalid bootstrap manifests
Alfredo Lopeza1a773ac29da
diff --git a/scripts/minikube/t2-common.sh b/scripts/minikube/t2-common.shindex 41f8754c1..8c93741ea 100755--- a/scripts/minikube/t2-common.sh+++ b/scripts/minikube/t2-common.sh@@ -327,6 +327,11 @@ if not source or not tag:print(source + "\t" + tag)PY)"; then+ if [ "$T2_BOOTSTRAP_REQUIRED" = true ]; then+ T2_PLAN_STATE=full-bootstrap+ T2_PLAN_REASON='image manifest is invalid or has no source/tag; bootstrap will replace it'+ return 0+ fiT2_NEXT_COMMAND="MINIKUBE_PROFILE=$T2_PROFILE make minikube-setup-local"t2_fail IMAGE_MANIFEST_MISMATCH 'image manifest is invalid or has no source/tag'fidiff --git a/scripts/tests/test-minikube-t2-scenarios.sh b/scripts/tests/test-minikube-t2-scenarios.shindex 2b3783341..fc23fd375 100755--- a/scripts/tests/test-minikube-t2-scenarios.sh+++ b/scripts/tests/test-minikube-t2-scenarios.sh@@ -133,6 +133,12 @@ expect_code IMAGE_MANIFEST_MISMATCH stale-image stale-image \env "${repo_env[@]}" T2_IMAGE_MANIFEST="$manifest" T2_IMAGE_SOURCE=local T2_IMAGE_TAG=old \bash -c 'source "$1"; T2_IMAGE_SOURCE=local; T2_IMAGE_TAG=old; t2_image_check' bash "$COMMON"+invalid_manifest="$tmp/invalid-image-manifest.json"+printf '{"imageSource":"local","imageTag":""}\n' >"$invalid_manifest"+bootstrap_manifest_state="$(env "${repo_env[@]}" T2_IMAGE_MANIFEST="$invalid_manifest" T2_BOOTSTRAP_REQUIRED=true \+ bash -c 'source "$1"; T2_BOOTSTRAP_REQUIRED=true; t2_image_check; printf "%s" "$T2_PLAN_STATE"' bash "$COMMON")"+[ "$bootstrap_manifest_state" = full-bootstrap ] || fail "invalid bootstrap manifest selected $bootstrap_manifest_state instead of full-bootstrap"+expect_code SECRET_MISSING missing-secret missing-secret \env "${repo_env[@]}" T2_BOOTSTRAP_REQUIRED=false T2_REQUIRED_NAMESPACES=control-plane \T2_REQUIRED_SERVICES=control-plane/control-api T2_REQUIRED_SECRETS=control-plane/absent \