Skip to content

Debug on exit standalone

emmanuel wyckens requested to merge debug-on-exit-standalone into main

What does this MR do and why?

In this MR, the main changes are:

  • Notes: During reviewing session make sure that whole the latest modification are taking into account
  • Create debug and exit dump log function (environment, bootstrap, management cluster and workload cluster) working on standalone mode.
  • We’ve included run_command script function, which executes a given command and handles the output differently depending on whether it’s running in a continuous integration (CI) environment. This ensures that the command's output is properly managed and logged in both CI and non-CI contexts. So the kubectl command deals with like
Before
kubectl get events -A -o yaml | format_and_sort_events include-ns > $dump_dir/events.log 
Now
dump_command "kubectl get events -A -o yaml | format_and_sort_events include-ns" "$dump_dir/events.log"

Related reference(s)

close #1222

!1756 (closed)

!1707

Test coverage

Manual tests: run the script interactively from the bootstrap VM in the following setups:

  • environment
  • bootstrap cluster failed and failed management cluster install
  • management cluster deployed
  • management cluster deployed and failed workload cluster install
  • workload cluster deployed
Edited by emmanuel wyckens

Merge request reports