Skip to content

Commit b31b6ba

Browse files
authored
Fix ability to resume restores (#1837)
1 parent d816151 commit b31b6ba

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

cmd/installer/cli/install.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,7 @@ func preRunInstall(cmd *cobra.Command, flags *InstallCmdFlags) error {
220220
flags.isAirgap = flags.airgapBundle != ""
221221

222222
runtimeconfig.ApplyFlags(cmd.Flags())
223+
os.Setenv("KUBECONFIG", runtimeconfig.PathToKubeConfig()) // this is needed for restore as well since it shares this function
223224
os.Setenv("TMPDIR", runtimeconfig.EmbeddedClusterTmpSubDir())
224225

225226
if err := runtimeconfig.WriteToDisk(); err != nil {
@@ -616,9 +617,6 @@ func installAndStartCluster(ctx context.Context, networkInterface string, airgap
616617
return nil, fmt.Errorf("wait for node: %w", err)
617618
}
618619

619-
// init the kubeconfig
620-
os.Setenv("KUBECONFIG", runtimeconfig.PathToKubeConfig())
621-
622620
loading.Infof("Node installation finished!")
623621
return cfg, nil
624622
}

0 commit comments

Comments
 (0)