Skip to content
Open
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
72 changes: 72 additions & 0 deletions config/v1/types_controllermanager.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
package v1

import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

// +genclient
// +genclient:nonNamespaced
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

// ControllerManager holds cluster-wide config information to run the Kubernetes controller manager
// and influence its placement decisions. The canonical name for this config is `cluster`.
//
// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
// +openshift:compatibility-gen:level=1
// +openshift:api-approved.openshift.io=https://github.com/openshift/api/pull/2668
// +openshift:file-pattern=cvoRunLevel=0000_10,operatorName=config-operator,operatorOrdering=01
// +kubebuilder:object:root=true
// +kubebuilder:resource:path=controllermanagers,scope=Cluster
// +kubebuilder:subresource:status
// +kubebuilder:metadata:annotations=release.openshift.io/bootstrap-required=true
type ControllerManager struct {
metav1.TypeMeta `json:",inline"`

// metadata is the standard object's metadata.
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
metav1.ObjectMeta `json:"metadata,omitempty"`
// spec holds user settable values for configuration
// +required
Spec ControllerManagerSpec `json:"spec"`
// status holds observed values from the cluster. They may not be overridden.
// +optional
Status ControllerManagerStatus `json:"status"`
}

type ControllerManagerSpec struct {
// ForceDetachOnTimeout allows the admin to enable or disable
// force detaching volumes based on a timeout.
// Valid values are Enabled, Disabled and omitted.
// Omitted means no opinion and the platform is left to choose
// a reasonable default, which is subject to change over time.
// The current default is Enabled.
// +optional
ForceDetachOnTimeout ForceDetachOnTimeoutPolicy `json:"forceDetachOnTimeout"`
}

// +kubebuilder:validation:Enum="";Enabled;Disabled
type ForceDetachOnTimeoutPolicy string

var (
// ForceDetachOnTimeoutEnabled will allow KCM to force detach volumes
// based on maximum unmount time and node status.
ForceDetachOnTimeoutEnabled ForceDetachOnTimeoutPolicy = "Enabled"
// ForceDetachOnTimeoutDisabled will prevent KCM from force detaching
// volumes by using the disable-force-detach-on-timeout option.
ForceDetachOnTimeoutDisabled ForceDetachOnTimeoutPolicy = "Disabled"
)

type ControllerManagerStatus struct {
}

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
// +openshift:compatibility-gen:level=1
type ControllerManagerList struct {
metav1.TypeMeta `json:",inline"`

// metadata is the standard list's metadata.
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
metav1.ListMeta `json:"metadata"`

Items []ControllerManager `json:"items"`
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.openshift.io: https://github.com/openshift/api/pull/2668
api.openshift.io/merged-by-featuregates: "true"
include.release.openshift.io/ibm-cloud-managed: "true"
include.release.openshift.io/self-managed-high-availability: "true"
release.openshift.io/bootstrap-required: "true"
name: controllermanagers.config.openshift.io
spec:
group: config.openshift.io
names:
kind: ControllerManager
listKind: ControllerManagerList
plural: controllermanagers
singular: controllermanager
scope: Cluster
versions:
- name: v1
schema:
openAPIV3Schema:
description: |-
ControllerManager holds cluster-wide config information to run the Kubernetes controller manager
and influence its placement decisions. The canonical name for this config is `cluster`.

Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
properties:
apiVersion:
description: |-
APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string
kind:
description: |-
Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string
metadata:
type: object
spec:
description: spec holds user settable values for configuration
properties:
forceDetachOnTimeout:
description: |-
ForceDetachOnTimeout allows the admin to enable or disable
force detaching volumes based on a timeout.
Valid values are Enabled, Disabled and omitted.
Omitted means no opinion and the platform is left to choose
a reasonable default, which is subject to change over time.
The current default is Enabled.
enum:
- ""
- Enabled
- Disabled
type: string
type: object
status:
description: status holds observed values from the cluster. They may not
be overridden.
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
93 changes: 93 additions & 0 deletions config/v1/zz_generated.deepcopy.go

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

22 changes: 22 additions & 0 deletions config/v1/zz_generated.featuregated-crd-manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,28 @@ consoles.config.openshift.io:
TopLevelFeatureGates: []
Version: v1

controllermanagers.config.openshift.io:
Annotations:
release.openshift.io/bootstrap-required: "true"
ApprovedPRNumber: https://github.com/openshift/api/pull/2668
CRDName: controllermanagers.config.openshift.io
Capability: ""
Category: ""
FeatureGates: []
FilenameOperatorName: config-operator
FilenameOperatorOrdering: "01"
FilenameRunLevel: "0000_10"
GroupName: config.openshift.io
HasStatus: true
KindName: ControllerManager
Labels: {}
PluralName: controllermanagers
PrinterColumns: []
Scope: Cluster
ShortNames: null
TopLevelFeatureGates: []
Version: v1

dnses.config.openshift.io:
Annotations:
release.openshift.io/bootstrap-required: "true"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.openshift.io: https://github.com/openshift/api/pull/2668
api.openshift.io/filename-cvo-runlevel: "0000_10"
api.openshift.io/filename-operator: config-operator
api.openshift.io/filename-ordering: "01"
feature-gate.release.openshift.io/: "true"
release.openshift.io/bootstrap-required: "true"
name: controllermanagers.config.openshift.io
spec:
group: config.openshift.io
names:
kind: ControllerManager
listKind: ControllerManagerList
plural: controllermanagers
singular: controllermanager
scope: Cluster
versions:
- name: v1
schema:
openAPIV3Schema:
description: |-
ControllerManager holds cluster-wide config information to run the Kubernetes controller manager
and influence its placement decisions. The canonical name for this config is `cluster`.

Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).
properties:
apiVersion:
description: |-
APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string
kind:
description: |-
Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string
metadata:
type: object
spec:
description: spec holds user settable values for configuration
properties:
forceDetachOnTimeout:
description: |-
ForceDetachOnTimeout allows the admin to enable or disable
force detaching volumes based on a timeout.
Valid values are Enabled, Disabled and omitted.
Omitted means no opinion and the platform is left to choose
a reasonable default, which is subject to change over time.
The current default is Enabled.
enum:
- ""
- Enabled
- Disabled
type: string
type: object
status:
description: status holds observed values from the cluster. They may not
be overridden.
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
28 changes: 28 additions & 0 deletions 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.

Loading