From 065b96a244f2abae8802ddf26add7b3cb8c82fbc Mon Sep 17 00:00:00 2001 From: Cole Mickens Date: Wed, 31 Jan 2018 14:44:32 -0800 Subject: [PATCH] respond to feedback --- docs/admin/admission-controllers.md | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/docs/admin/admission-controllers.md b/docs/admin/admission-controllers.md index 175229e257ee1..ffd6e7d4faaa6 100644 --- a/docs/admin/admission-controllers.md +++ b/docs/admin/admission-controllers.md @@ -434,7 +434,7 @@ This admission controller defaults and limits what node selectors may be used wi #### Configuration File Format -PodNodeSelector uses a configuration file to set options for the behavior of the backend. +`PodNodeSelector` uses a configuration file to set options for the behavior of the backend. Note that the configuration file format will move to a versioned file in a future release. This file may be json or yaml and has the following format: @@ -445,7 +445,7 @@ podNodeSelectorPluginConfig: namespace2: ``` -Reference the PodNodeSelector configuration file from the file provided to the API server's command line flag `--admission-control-config-file`: +Reference the `PodNodeSelector` configuration file from the file provided to the API server's command line flag `--admission-control-config-file`: ```yaml kind: AdmissionConfiguration @@ -457,7 +457,7 @@ plugins: ``` #### Configuration Annotation Format -PodNodeSelector uses the annotation key `scheduler.kubernetes.io/node-selector` to assign node selectors to namespaces. +`PodNodeSelector` uses the annotation key `scheduler.kubernetes.io/node-selector` to assign node selectors to namespaces. ```yaml apiVersion: v1 @@ -470,15 +470,16 @@ metadata: #### Internal Behavior This admission controller has the following behavior: - 1. If the namespace has an annotation with a key `scheduler.kubernetes.io/nodeSelector`, use its value as the - namespace node selector. - 2. If the namespace lacks such an annotation, use the `clusterDefaultNodeSelector` defined in the plugin - configuration file as the namespace node selector. - 3. Evaluate the pod's node selector against the namespace node selector for conflicts. Conflicts result in rejection. - 4. Evaluate the pod's node selector against the namespace-specific whitelist defined the plugin configuration file. + 1. If the `Namespace` has an annotation with a key `scheduler.kubernetes.io/nodeSelector`, use its value as the + node selector. + 1. If the namespace lacks such an annotation, use the `clusterDefaultNodeSelector` defined in the `PodNodeSelector` + plugin configuration file as the node selector. + 1. Evaluate the pod's node selector against the namespace node selector for conflicts. Conflicts result in rejection. + 1. Evaluate the pod's node selector against the namespace-specific whitelist defined the plugin configuration file. Conflicts result in rejection. -Note: PodTolerationRestriction is more versatile and powerful than PodNodeSelector and can encompass the scenarios supported by PodNodeSelector. +**Note:** `PodTolerationRestriction` is more versatile and powerful than `PodNodeSelector` and can encompass the scenarios supported by `PodNodeSelector`. +{: .note} ### PersistentVolumeClaimResize