From be57cd72bff282cffba6d51037a95be3b2f8ac85 Mon Sep 17 00:00:00 2001 From: Kimmo Lehto Date: Thu, 27 Jun 2024 09:33:06 +0300 Subject: [PATCH] Hide kubeconfig content from logs Signed-off-by: Kimmo Lehto --- phase/get_kubeconfig.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phase/get_kubeconfig.go b/phase/get_kubeconfig.go index 2b291d9b..19943fe9 100644 --- a/phase/get_kubeconfig.go +++ b/phase/get_kubeconfig.go @@ -24,7 +24,7 @@ func (p *GetKubeconfig) Title() string { } var readKubeconfig = func(h *cluster.Host) (string, error) { - output, err := h.ExecOutput(h.Configurer.K0sCmdf("kubeconfig admin --data-dir=%s", shellescape.Quote(h.K0sDataDir())), exec.Sudo(h)) + output, err := h.ExecOutput(h.Configurer.K0sCmdf("kubeconfig admin --data-dir=%s", shellescape.Quote(h.K0sDataDir())), exec.Sudo(h), exec.HideOutput()) if err != nil { return "", fmt.Errorf("get kubeconfig from host: %w", err) }