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

Default webhook port (443) is problematic for operators running as non-root #1018

Closed
joelanford opened this issue Jun 24, 2020 · 3 comments · Fixed by #1076
Closed

Default webhook port (443) is problematic for operators running as non-root #1018

joelanford opened this issue Jun 24, 2020 · 3 comments · Fixed by #1076
Assignees
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Milestone

Comments

@joelanford
Copy link
Member

If left unset, the manager defaults to running the webhook server on port 443.

Since it is a security best practice to run pods as a non-root user, this default can cause unexpected problems for developers using controller-runtime directly (nonroot users typically can't open listeners on low-numbered ports).

In Kubebuilder, the default main.go scaffold hardcodes this value to 9443, which solves the problem for users of Kubebuilder that scaffolded their project somewhat recently, but all other users are left figuring this out on their own.

I'm wondering if we should change the default value to 9443 to match Kubebuilder's current scaffold configuration?

This would be a breaking change.

@vincepri
Copy link
Member

+1, we should change the port to 9443 or similar, let's do this in the next milestone. Anyone tackling this issue, you should title your PR as ⚠️, given that's a breaking change and it'll probably need release notes.

/milestone v0.7.x
/priority important-soon
/kind cleanup
/help
/good-first-issue

@k8s-ci-robot
Copy link
Contributor

@vincepri:
This request has been marked as suitable for new contributors.

Please ensure the request meets the requirements listed here.

If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-good-first-issue command.

In response to this:

+1, we should change the port to 9443 or similar, let's do this in the next milestone. Anyone tackling this issue, you should title your PR as ⚠️, given that's a breaking change and it'll probably need release notes.

/milestone v0.7.x
/priority important-soon
/kind cleanup
/help
/good-first-issue

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added this to the v0.7.x milestone Jul 22, 2020
@k8s-ci-robot k8s-ci-robot added priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. labels Jul 22, 2020
@jiachengxu
Copy link
Contributor

/assign

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants