mirror of
https://git.vectorsigma.ru/public/k3s.git
synced 2026-08-02 00:49:51 +00:00
Add context to agent token validation error
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit c11c06cad4)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
This commit is contained in:
committed by
Brad Davidson
parent
51fb5b7843
commit
f13bf11348
@@ -351,7 +351,7 @@ func createProxyAndValidateToken(ctx context.Context, cfg *cmds.Agent) (proxy.Pr
|
||||
for {
|
||||
newToken, err := clientaccess.ParseAndValidateToken(proxy.SupervisorURL(), cfg.Token, options...)
|
||||
if err != nil {
|
||||
logrus.Error(err)
|
||||
logrus.Errorf("Failed to validate connection to cluster at %s: %v", cfg.ServerURL, err)
|
||||
select {
|
||||
case <-ctx.Done():
|
||||
return nil, ctx.Err()
|
||||
|
||||
Reference in New Issue
Block a user