Add more debug logging when waiting for pending strategies.
Signed-off-by: Matt Moyer <moyerm@vmware.com>
This commit is contained in:
parent
0cb1538b39
commit
005133fbfb
@ -310,6 +310,7 @@ func waitForCredentialIssuer(ctx context.Context, clientset conciergeclientset.I
|
|||||||
if !hasPendingStrategy(credentialIssuer) {
|
if !hasPendingStrategy(credentialIssuer) {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
logStrategies(credentialIssuer, deps.log)
|
||||||
deps.log.Info("waiting for CredentialIssuer pending strategies to finish",
|
deps.log.Info("waiting for CredentialIssuer pending strategies to finish",
|
||||||
"attempts", attempts,
|
"attempts", attempts,
|
||||||
"remaining", time.Until(deadline).Round(time.Second).String(),
|
"remaining", time.Until(deadline).Round(time.Second).String(),
|
||||||
@ -332,14 +333,7 @@ func discoverConciergeParams(credentialIssuer *configv1alpha1.CredentialIssuer,
|
|||||||
// Autodiscover the --concierge-mode.
|
// Autodiscover the --concierge-mode.
|
||||||
frontend, err := getConciergeFrontend(credentialIssuer, flags.concierge.mode)
|
frontend, err := getConciergeFrontend(credentialIssuer, flags.concierge.mode)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
for _, strategy := range credentialIssuer.Status.Strategies {
|
logStrategies(credentialIssuer, log)
|
||||||
log.Info("found CredentialIssuer strategy",
|
|
||||||
"type", strategy.Type,
|
|
||||||
"status", strategy.Status,
|
|
||||||
"reason", strategy.Reason,
|
|
||||||
"message", strategy.Message,
|
|
||||||
)
|
|
||||||
}
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -383,6 +377,17 @@ func discoverConciergeParams(credentialIssuer *configv1alpha1.CredentialIssuer,
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func logStrategies(credentialIssuer *configv1alpha1.CredentialIssuer, log logr.Logger) {
|
||||||
|
for _, strategy := range credentialIssuer.Status.Strategies {
|
||||||
|
log.Info("found CredentialIssuer strategy",
|
||||||
|
"type", strategy.Type,
|
||||||
|
"status", strategy.Status,
|
||||||
|
"reason", strategy.Reason,
|
||||||
|
"message", strategy.Message,
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func discoverAuthenticatorParams(authenticator metav1.Object, flags *getKubeconfigParams, log logr.Logger) error {
|
func discoverAuthenticatorParams(authenticator metav1.Object, flags *getKubeconfigParams, log logr.Logger) error {
|
||||||
switch auth := authenticator.(type) {
|
switch auth := authenticator.(type) {
|
||||||
case *conciergev1alpha1.WebhookAuthenticator:
|
case *conciergev1alpha1.WebhookAuthenticator:
|
||||||
|
Loading…
Reference in New Issue
Block a user