Skip to content
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

Move management of webhook configurations to operator #105

Merged
merged 1 commit into from Jun 27, 2019
Merged

Move management of webhook configurations to operator #105

merged 1 commit into from Jun 27, 2019

Conversation

bison
Copy link
Contributor

@bison bison commented Jun 26, 2019

This moves the management of the webhook configurations under the
control of the operator rather than the CVO. Unfortunately the CA
bundle fields in the webhook configurations are not known until
runtime. If the CVO manages the configuration resources, the CA field
cannot be updated as the CVO would overwrite any changes.

@openshift-ci-robot openshift-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jun 26, 2019
install/03_rbac.yaml Show resolved Hide resolved
return nil, err
}

failurePolicy := admissionregistrationv1beta1.Ignore
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why should this be ignore?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because the validations are really (or will be when we're not doing allow-all) a nice-to-have. We have OpenAPI validation on the fields where we're able to do that, and other errors will be reported in events or in status conditions after the resource is created. So, we shouldn't completely block the functioning of the operator if the connection to the webhook server is not working -- e.g. if there's some transient networking issue.

This moves the management of the webhook configurations under the
control of the operator rather than the CVO.  Unfortunately the CA
bundle fields in the webhook configurations are not known until
runtime.  If the CVO manages the configuration resources, the CA field
cannot be updated as the CVO would overwrite any changes.
@enxebre
Copy link
Member

enxebre commented Jun 26, 2019

more context https://coreos.slack.com/archives/C68TNFWA2/p1561560240498300 on why this is needed

@enxebre
Copy link
Member

enxebre commented Jun 27, 2019

This will only create the webhook once and won't take care of reconciling/recreation. If we find no way to drive this via cvo we'll need to make it more robust via local controller soon.
/approve

@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: enxebre

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 27, 2019
@ingvagabund
Copy link
Member

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jun 27, 2019
@openshift-merge-robot openshift-merge-robot merged commit 10dcdad into openshift:master Jun 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants