Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Commit

Permalink
fix: Wait for SA token to be populated
Browse files Browse the repository at this point in the history
Although normally very fast, generation of the SA token is async so poll
the SA token until it exists.
  • Loading branch information
jimmidyson committed Aug 8, 2022
1 parent c186056 commit 1b6e547
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/kubefedctl/join.go
Original file line number Diff line number Diff line change
Expand Up @@ -904,6 +904,10 @@ func populateSecretInHostCluster(clusterClientset, hostClientset kubeclient.Inte
return false, nil
}

if _, ok := joiningClusterSASecret.Data[ctlutil.TokenKey]; !ok {
return false, nil
}

secret = joiningClusterSASecret

return true, nil
Expand Down

0 comments on commit 1b6e547

Please sign in to comment.