Scheduler can recieve its policy configuration from a ConfigMap
This commit is contained in:
@@ -599,6 +599,16 @@ type KubeSchedulerConfiguration struct {
|
||||
LockObjectNamespace string
|
||||
// LockObjectName defines the lock object name
|
||||
LockObjectName string
|
||||
// PolicyConfigMapName is the name of the ConfigMap object that specifies
|
||||
// the scheduler's policy config. If UseLegacyPolicyConfig is true, scheduler
|
||||
// uses PolicyConfigFile. If UseLegacyPolicyConfig is false and
|
||||
// PolicyConfigMapName is not empty, the ConfigMap object with this name must
|
||||
// exist in the default system namespace ("kube-system") before scheduler
|
||||
// initialization.
|
||||
PolicyConfigMapName string
|
||||
// UseLegacyPolicyConfig tells the scheduler to ignore Policy ConfigMap and
|
||||
// to use PolicyConfigFile if available.
|
||||
UseLegacyPolicyConfig bool
|
||||
}
|
||||
|
||||
// LeaderElectionConfiguration defines the configuration of leader election
|
||||
|
||||
@@ -134,6 +134,16 @@ type KubeSchedulerConfiguration struct {
|
||||
LockObjectNamespace string `json:"lockObjectNamespace"`
|
||||
// LockObjectName defines the lock object name
|
||||
LockObjectName string `json:"lockObjectName"`
|
||||
// PolicyConfigMapName is the name of the ConfigMap object that specifies
|
||||
// the scheduler's policy config. If UseLegacyPolicyConfig is true, scheduler
|
||||
// uses PolicyConfigFile. If UseLegacyPolicyConfig is false and
|
||||
// PolicyConfigMapName is not empty, the ConfigMap object with this name must
|
||||
// exist in the default system namespace ("kube-system") before scheduler
|
||||
// initialization.
|
||||
PolicyConfigMapName string `json:"policyConfigMapName"`
|
||||
// UseLegacyPolicyConfig tells the scheduler to ignore Policy ConfigMap and
|
||||
// to use PolicyConfigFile if available.
|
||||
UseLegacyPolicyConfig bool `json:"useLegacyPolicyConfig"`
|
||||
}
|
||||
|
||||
// HairpinMode denotes how the kubelet should configure networking to handle
|
||||
|
||||
@@ -12913,6 +12913,20 @@ func GetOpenAPIDefinitions(ref openapi.ReferenceCallback) map[string]openapi.Ope
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"policyConfigMapName": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "PolicyConfigMapName is the name of the ConfigMap object that specifies the scheduler's policy config. If UseLegacyPolicyConfig is true, scheduler uses PolicyConfigFile. If UseLegacyPolicyConfig is false and PolicyConfigMapName is not empty, the ConfigMap object with this name must exist in the default system namespace (\"kube-system\") before scheduler initialization.",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"useLegacyPolicyConfig": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "UseLegacyPolicyConfig tells the scheduler to ignore Policy ConfigMap and to use PolicyConfigFile if available.",
|
||||
Type: []string{"boolean"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
},
|
||||
Required: []string{"port", "address", "algorithmProvider", "policyConfigFile", "enableProfiling", "enableContentionProfiling", "contentType", "kubeAPIQPS", "kubeAPIBurst", "schedulerName", "hardPodAffinitySymmetricWeight", "failureDomains", "leaderElection", "lockObjectNamespace", "lockObjectName"},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user