Skip to content
Merged
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
14 changes: 14 additions & 0 deletions cmd/openshift-install/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,20 @@ func clusterCreatePostRun(ctx context.Context) (int, error) {
}
timer.StopTimer("Bootstrap Complete")

// In CI, we want to collect an installer log bundle so we can examine bootstrap logs that aren't
// collectable anywhere else.
if gatherBootstrap, ok := os.LookupEnv("OPENSHIFT_INSTALL_GATHER_BOOTSTRAP"); ok && gatherBootstrap != "" {
timer.StartTimer("Bootstrap Gather")
logrus.Infof("OPENSHIFT_INSTALL_GATHER_BOOTSTRAP is set, will attempt to gather a log bundle")
bundlePath, gatherErr := runGatherBootstrapCmd(ctx, command.RootOpts.Dir)
if gatherErr != nil {
logrus.Warningf("Attempted to gather debug logs, and it failed: %q ", gatherErr)
} else {
logrus.Infof("Bootstrap gather logs captured here %q", bundlePath)
}
timer.StopTimer("Bootstrap Gather")
}

//
// Wait for the bootstrap to be destroyed.
//
Expand Down