Skip to content

Commit

Permalink
Merge pull request openshift#218 from ravisantoshgudimetla/add-defaul…
Browse files Browse the repository at this point in the history
…t-project-nodeselector

Add default project nodeselector
  • Loading branch information
openshift-merge-robot authored Mar 18, 2019
2 parents bfb0ed8 + 0c08902 commit 756349b
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
21 changes: 21 additions & 0 deletions config/v1/types_scheduling.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,27 @@ type SchedulerSpec struct {
// The namespace for this configmap is openshift-config.
// +optional
Policy ConfigMapNameReference `json:"policy"`
// defaultNodeSelector helps set the cluster-wide default node selector to
// restrict pod placement to specific nodes. This is applied to the pods
// created in all namespaces without a specified nodeSelector value.
// For example,
// defaultNodeSelector: "type=user-node,region=east" would set nodeSelector
// field in pod spec to "type=user-node,region=east" to all pods created
// in all namespaces. Namespaces having project-wide node selectors won't be
// impacted even if this field is set. This adds an annotation section to
// the namespace.
// For example, if a new namespace is created with
// node-selector='type=user-node,region=east',
// the annotation openshift.io/node-selector: type=user-node,region=east
// gets added to the project. When the openshift.io/node-selector annotation
// is set on the project the value is used in preference to the value we are setting
// for defaultNodeSelector field.
// For instance,
// openshift.io/node-selector: "type=user-node,region=west" means
// that the default of "type=user-node,region=east" set in defaultNodeSelector
// would not be applied.
// +optional
DefaultNodeSelector string `json:"defaultNodeSelector,omitempty"`
}

type SchedulerStatus struct {
Expand Down
3 changes: 2 additions & 1 deletion config/v1/zz_generated.swagger_doc_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 756349b

Please sign in to comment.