-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Timing #320
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@idlewis Thanks for the PR. Looks good for the most part. Added some comments.
if getErr != nil { | ||
return r.ManageError(getErr, common.StatusConditionTypeReconciled, instance) | ||
} | ||
secrets := sa.Secrets |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check on ImagePullSecret instead of Secrets
@@ -335,6 +335,35 @@ func (r *ReconcileOpenLiberty) Reconcile(ctx context.Context, request ctrl.Reque | |||
r.deletePVC(reqLogger, instance.Name+"-serviceability", instance.Namespace) | |||
} | |||
|
|||
// Check if the ServiceAccount has a valid pull secret before creating the deployment/statefulset |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It'll be good to do this check after line 239 (before knative, since that could also be affected by this issue).
Also, this should be added to RCO's util package, so both RCO and OLO controllers can call it.
@idlewis merged RCO PR. When you get a chance, please update (or open new PR) to use the utils from RCO. We will need the same for WLO. Thank you. |
Specifically the change to utils/utils.go which adds a function to check for pull secrets
The cluster automatically creates pull secrets for the service account. This can take a while. Sometimes, the controller creates the deployment before the pull secret is created. This causes the pods to go into an image pull backoff loop. Check that the pull secret exists before the deployment is created, to prevent this
To deal with the issue reported in #312