Skip to content

MCO-1663: add explicit opt-out for boot image update in 4.18 #2303

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

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion openapi/generated_openapi/zz_generated.openapi.go

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

5 changes: 4 additions & 1 deletion openapi/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -29738,7 +29738,7 @@
],
"properties": {
"mode": {
"description": "mode determines how machine managers will be selected for updates. Valid values are All and Partial. All means that every resource matched by the machine manager will be updated. Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated.",
"description": "mode determines how machine managers will be selected for updates. Valid values are All and Partial. All means that every resource matched by the machine manager will be updated. Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated. None means that every resource matched by the machine manager will not be updated.",
"type": "string",
"default": ""
},
Expand Down Expand Up @@ -31169,6 +31169,9 @@
"com.github.openshift.api.operator.v1.PartialSelector": {
"description": "PartialSelector provides label selector(s) that can be used to match machine management resources.",
"type": "object",
"required": [
"machineResourceSelector"
],
"properties": {
"machineResourceSelector": {
"description": "machineResourceSelector is a label selector that can be used to select machine resources like MachineSets.",
Expand Down
10 changes: 7 additions & 3 deletions operator/v1/types_machineconfiguration.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,9 @@ type MachineManagerSelector struct {
// Valid values are All and Partial.
// All means that every resource matched by the machine manager will be updated.
// Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated.
// None means that every resource matched by the machine manager will not be updated.
// +unionDiscriminator
// +kubebuilder:validation:Required
// +required
Mode MachineManagerSelectorMode `json:"mode"`

// partial provides label selector(s) that can be used to match machine management resources.
Expand All @@ -165,12 +166,12 @@ type MachineManagerSelector struct {
// PartialSelector provides label selector(s) that can be used to match machine management resources.
type PartialSelector struct {
// machineResourceSelector is a label selector that can be used to select machine resources like MachineSets.
// +kubebuilder:validation:Required
// +required
MachineResourceSelector *metav1.LabelSelector `json:"machineResourceSelector,omitempty"`
}

// MachineManagerSelectorMode is a string enum used in the MachineManagerSelector union discriminator.
// +kubebuilder:validation:Enum:="All";"Partial"
// +kubebuilder:validation:Enum:="All";"Partial";"None"
type MachineManagerSelectorMode string

const (
Expand All @@ -180,6 +181,9 @@ const (
// Partial represents a configuration mode that will register resources specified by the parent MachineManager only
// if they match with the label selector.
Partial MachineManagerSelectorMode = "Partial"

// None represents a configuration mode that excludes all resources specified by the parent MachineManager from boot image updates.
None MachineManagerSelectorMode = "None"
)

// MachineManagerManagedResourceType is a string enum used in the MachineManager type to describe the resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,11 @@ spec:
Valid values are All and Partial.
All means that every resource matched by the machine manager will be updated.
Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated.
None means that every resource matched by the machine manager will not be updated.
enum:
- All
- Partial
- None
type: string
partial:
description: |-
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,11 @@ spec:
Valid values are All and Partial.
All means that every resource matched by the machine manager will be updated.
Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated.
None means that every resource matched by the machine manager will not be updated.
enum:
- All
- Partial
- None
type: string
partial:
description: |-
Expand Down
2 changes: 1 addition & 1 deletion operator/v1/zz_generated.swagger_doc_generated.go

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

Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,11 @@ spec:
Valid values are All and Partial.
All means that every resource matched by the machine manager will be updated.
Partial requires specified selector(s) and allows customisation of which resources matched by the machine manager will be updated.
None means that every resource matched by the machine manager will not be updated.
enum:
- All
- Partial
- None
type: string
partial:
description: |-
Expand Down