-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
kubeadm-setup: add page about control plane flags #9067
kubeadm-setup: add page about control plane flags #9067
Conversation
Deploy preview for kubernetes-io-master-staging ready! Built with commit dd838ab https://deploy-preview-9067--kubernetes-io-master-staging.netlify.com |
Deploy preview for kubernetes-io-master-staging ready! Built with commit 4e5e3de https://deploy-preview-9067--kubernetes-io-master-staging.netlify.com |
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.
Thanks @neolit123 for this. A couple of comments
Example usage: | ||
```yaml | ||
schedulerExtraArgs: | ||
address: 192.168.0.104 |
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.
I'd do 0.0.0.0 as a generic reasonable value for this
schedulerExtraArgs: | ||
address: 192.168.0.104 | ||
config: /home/johndoe/schedconfig | ||
master: 192.168.0.103 |
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.
this should be a URL, e.g. https://my-api-server.domain.com:6443
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.
but preferably, I'd set kubeconfig
to something here instead...
```yaml | ||
schedulerExtraArgs: | ||
address: 192.168.0.104 | ||
config: /home/johndoe/schedconfig |
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.
.yaml
```yaml | ||
controllerManagerExtraArgs: | ||
cluster-signing-key-file: /home/johndoe/keys/ca.key | ||
bind-address: 192.168.0.101 |
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.
0.0.0.0
controllerManagerExtraArgs: | ||
cluster-signing-key-file: /home/johndoe/keys/ca.key | ||
bind-address: 192.168.0.101 | ||
deployment-controller-sync-period: 50 |
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.
this is a duration right? 50s?
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.
yes.
```yaml | ||
apiServerExtraArgs: | ||
advertise-address: 192.168.0.103 | ||
allow-privileged: true |
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 deprecated I think... some other common value like enable-admission-control
?
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.
The most common uses are:
adding admission controllers
configuring audit log (soon to be webhook)
- `ControllerManagerExtraArgs` | ||
- `SchedulerExtraArgs` | ||
|
||
The fields can contain a list of `key: value` pairs. To override flags for a specific control plane component just include one of the fields above and start adding flags for it. |
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.
you can add a (it's serialized as a map[string]string
, like Kubernetes labels or annotations)`
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.
s/just/
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.
What value for a user does the content that luxas suggests add? This seems like an implementation detail that does not belong here. We've already got a larger confusion in the kubeadm docs between what a user needs and what a dev needs; let's not perpetuate it here.
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.
Larger scale edit:
These fields consist of key: value
pairs. To override a flag for a control plane component:
- Add the appropriate field to your configuration.
- Add the flags to override to the field.
|
||
Example usage: | ||
```yaml | ||
apiServerExtraArgs: |
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.
include full typemeta information in every example please
- fabriziopandini | ||
- luxas | ||
- timothysc | ||
title: Customizing control plane flags with kubeadm |
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.
Customizing control plane configuration with kubeadm
is more generic and future-proof
/assign |
Is this the right location? |
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.
minor comments.
- `ControllerManagerExtraArgs` | ||
- `SchedulerExtraArgs` | ||
|
||
The fields can contain a list of `key: value` pairs. To override flags for a specific control plane component just include one of the fields above and start adding flags for it. |
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.
s/just/
```yaml | ||
apiServerExtraArgs: | ||
advertise-address: 192.168.0.103 | ||
allow-privileged: true |
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.
The most common uses are:
adding admission controllers
configuring audit log (soon to be webhook)
controllerManagerExtraArgs: | ||
cluster-signing-key-file: /home/johndoe/keys/ca.key | ||
bind-address: 192.168.0.101 | ||
deployment-controller-sync-period: 50 |
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.
yes.
@luxas, @timstclair thanks for the reviews. i will update this tomorrow.
it felt right to me to under setup and not tasks or cmd reference. |
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.
Copyedits for readability and usability, plus a question about requested information that doesn't seem to belong here.
- `ControllerManagerExtraArgs` | ||
- `SchedulerExtraArgs` | ||
|
||
The fields can contain a list of `key: value` pairs. To override flags for a specific control plane component just include one of the fields above and start adding flags for it. |
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.
What value for a user does the content that luxas suggests add? This seems like an implementation detail that does not belong here. We've already got a larger confusion in the kubeadm docs between what a user needs and what a dev needs; let's not perpetuate it here.
|
||
{{< note >}} | ||
In later versions of the kubeadm configuration these fields will be replaced by usage of a ComponentConfig and a ConfigMap. | ||
{{< /note >}} |
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.
Remove entire note. Future statements are dangerous, and of no use to current users. (Again, this is one of those user/developer confusions.)
|
||
## APIServer flags | ||
|
||
The list of possible APIServer flags and their descriptions can be found [here](https://kubernetes.io/docs/reference/command-line-tools-reference/kube-apiserver/). |
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.
edit to:
"For details, see the reference documentation for kube-apiserver."
(note formation of link also)
- `ControllerManagerExtraArgs` | ||
- `SchedulerExtraArgs` | ||
|
||
The fields can contain a list of `key: value` pairs. To override flags for a specific control plane component just include one of the fields above and start adding flags for it. |
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.
Larger scale edit:
These fields consist of key: value
pairs. To override a flag for a control plane component:
- Add the appropriate field to your configuration.
- Add the flags to override to the field.
|
||
## ControllerManager flags | ||
|
||
The list of possible ControllerManager flags and their descriptions can be found [here](https://kubernetes.io/docs/reference/command-line-tools-reference/kube-controller-manager/). |
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.
See comment at line 27 -- follow the same pattern here.
|
||
## Scheduler flags | ||
|
||
The list of possible Scheduler flags and their descriptions can be found [here](https://kubernetes.io/docs/reference/command-line-tools-reference/kube-scheduler/). |
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.
See line 27, follow pattern.
i'm going to have to delay the edits for the weekend or monday. |
hi, @timstclair @luxas @Bradamant3 in terms of location i'm leaving this as is, unless someone objects? @Bradamant3 thanks for taking the time to write the document: do we have a tracking issue for the kubeadm docs folder restructuring and if not do you want me to create one? also in which repo |
@neolit123 - only comment is the addition of the meta-data @luxas mentioned earlier, other |
i've included |
@neolit123 I think adding:
is useful to the readers w/possible link to https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.10/#objectmeta-v1-meta optional params. |
added the |
/lgtm |
2245450
to
47a05ee
Compare
47a05ee
to
f504ae2
Compare
squashed commits. waiting on approval. |
|
||
{{% capture overview %}} | ||
|
||
kubeadm’s configuration exposes the following fields that can be used to override the default flags passed to control plane components such as the APISever, ControllerManager and Scheduler: |
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.
s/APISever/APIServer
approved review changes, not adding hold but in case anybody else is looking here: author is still fixing a typo and some template problems. I don't have commit access (GH ftw ...) |
f504ae2
to
580d3e4
Compare
ed0de5e
to
953bdea
Compare
This page adds instructions on how to use the kubeadm config to pass flags to control plane components. The provided examples are pretty basic. Later this can be expanded with actual user stories.
953bdea
to
4e5e3de
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Bradamant3 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 |
This page adds instructions on how to use the kubeadm config
to pass flags to control plane components.
The provided examples are pretty basic. Later this can be expanded with
actual user stories.
Updates kubernetes/kubeadm#849
/cc @fabriziopandini @luxas @timstclair @kubernetes/sig-cluster-lifecycle-pr-reviews
/assign @Bradamant3
notes:
setup/independent
as the location for this.