mirror of
https://github.com/juanfont/headscale.git
synced 2024-12-02 03:33:05 +00:00
only print stdout on err
Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
This commit is contained in:
parent
54e3a0d372
commit
fe4e05b0bc
1 changed files with 4 additions and 4 deletions
|
@ -121,6 +121,10 @@ func (t *TailscaleInContainer) Execute(
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Printf("command stderr: %s\n", stderr)
|
log.Printf("command stderr: %s\n", stderr)
|
||||||
|
|
||||||
|
if stdout != "" {
|
||||||
|
log.Printf("command stdout: %s\n", stdout)
|
||||||
|
}
|
||||||
|
|
||||||
if strings.Contains(stderr, "NeedsLogin") {
|
if strings.Contains(stderr, "NeedsLogin") {
|
||||||
return "", errTailscaleNotLoggedIn
|
return "", errTailscaleNotLoggedIn
|
||||||
}
|
}
|
||||||
|
@ -128,10 +132,6 @@ func (t *TailscaleInContainer) Execute(
|
||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
|
||||||
if stdout != "" {
|
|
||||||
log.Printf("command stdout: %s\n", stdout)
|
|
||||||
}
|
|
||||||
|
|
||||||
return stdout, nil
|
return stdout, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue