-
Notifications
You must be signed in to change notification settings - Fork 4.8k
add logic for openshift webconsole operator #19498
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
add logic for openshift webconsole operator #19498
Conversation
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: deads2k The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
| } | ||
| existing.Spec = *required.Spec.DeepCopy() | ||
|
|
||
| actual, err := client.Deployments(required.Namespace).Update(existing) |
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.
where do we handle conflicts? does the controller just re-apply on next sync?
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.
where do we handle conflicts? does the controller just re-apply on next sync?
Yes, and it is logged and put into the CRD status.
| } | ||
|
|
||
| func ReadConfigMapOrDie(objBytes []byte) *corev1.ConfigMap { | ||
| requiredObj, err := runtime.Decode(coreCodecs.UniversalDecoder(corev1.SchemeGroupVersion), []byte(objBytes)) |
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.
[]byte(objByte) is a noop here right?
| if err != nil { | ||
| panic(err) | ||
| } | ||
| return requiredObj.(*corev1.ConfigMap) |
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.
can we also panic when requiredObj != corev1.ConfigMap ?
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.
can we also panic when requiredObj != corev1.ConfigMap ?
Yeah. it's a coding error.
| webconsole: "true" | ||
| spec: | ||
| strategy: | ||
| type: Recreate |
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.
is there reason this is Recreate and not Rollout ?
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 was discussed some time ago, web-console switched to recreate some time ago, iirc.
Cluster up tests when you modify cluster up indicate it here: https://openshift-gce-devel.appspot.com/build/origin-ci-test/pr-logs/pull/19498/test_pull_request_origin_extended_clusterup/1021/ |
|
/retest |
|
/retest |
|
I can't figure out why catalog is failing to start in the extended clusterup test. Other PRs seem to be successfully passing. |
|
/retest |
| // TODO wait until the webconsole is up | ||
| // wait until the webconsole to an available endpoint | ||
| WaitCondition: func() (bool, error) { | ||
| glog.V(2).Infof("polling for service catalog api server endpoint availability") |
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.
polling for webconsole availability?
|
@deads2k I think this is failing because you use the Always as the OPENSHIFT_PULL_POLICY which means the |
|
ah, image layout changed |
|
/retest |
|
/lgtm this is a good starting point |
Adds a simple operator that creates a webconsole deployment. It manages conflicts with the workload controller by actively stomping it when the generation doesn't match. Errors appear on the status of the subresource