cmd/tailscale: have web POST wait for authURL
Fixes #1939 Signed-off-by: David Crawshaw <crawshaw@tailscale.com>pull/1992/head^2
parent
50c976d3f1
commit
82b217f82e
|
@ -321,6 +321,10 @@ func tailscaleUpForceReauth(ctx context.Context) (authURL string, retErr error)
|
||||||
})
|
})
|
||||||
bc.StartLoginInteractive()
|
bc.StartLoginInteractive()
|
||||||
|
|
||||||
|
<-pumpCtx.Done() // wait for authURL or complete failure
|
||||||
|
if authURL == "" && retErr == nil {
|
||||||
|
retErr = pumpCtx.Err()
|
||||||
|
}
|
||||||
if authURL == "" && retErr == nil {
|
if authURL == "" && retErr == nil {
|
||||||
return "", fmt.Errorf("login failed with no backend error message")
|
return "", fmt.Errorf("login failed with no backend error message")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue