-
Notifications
You must be signed in to change notification settings - Fork 609
STOR 437- Create API for vsphere CSI topology configuration #1271
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
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 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -96,6 +96,57 @@ type ClusterCSIDriverSpec struct { | |||||||||
| // The current default behaviour is Managed. | ||||||||||
| // +optional | ||||||||||
| StorageClassState StorageClassStateName `json:"storageClassState,omitempty"` | ||||||||||
|
|
||||||||||
| // driverConfig can be used to specify platform specific driver configuration. | ||||||||||
| // When omitted, this means no opinion and the platform is left to choose reasonable | ||||||||||
| // defaults. These defaults are subject to change over time. | ||||||||||
| // +optional | ||||||||||
| DriverConfig CSIDriverConfigSpec `json:"driverConfig"` | ||||||||||
| } | ||||||||||
|
|
||||||||||
| // CSIDriverType indicates type of CSI driver being configured. | ||||||||||
| // +kubebuilder:validation:Enum="";vSphere | ||||||||||
| type CSIDriverType string | ||||||||||
|
|
||||||||||
| const ( | ||||||||||
| VSphereDriverType CSIDriverType = "vSphere" | ||||||||||
| ) | ||||||||||
|
|
||||||||||
| // CSIDriverConfigSpec defines configuration spec that can be | ||||||||||
| // used to optionally configure a specific CSI Driver. | ||||||||||
| // +union | ||||||||||
| type CSIDriverConfigSpec struct { | ||||||||||
| // driverType indicates type of CSI driver for which the | ||||||||||
| // driverConfig is being applied to. | ||||||||||
| // | ||||||||||
| // Valid values are: | ||||||||||
| // | ||||||||||
| // * vSphere | ||||||||||
| // | ||||||||||
| // Allows configuration of vsphere CSI driver topology. | ||||||||||
| // | ||||||||||
| // --- | ||||||||||
| // Consumers should treat unknown values as a NO-OP. | ||||||||||
| // | ||||||||||
| // +kubebuilder:validation:Required | ||||||||||
| // +unionDiscriminator | ||||||||||
| DriverType CSIDriverType `json:"driverType"` | ||||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As this enum is expected over time, you need to add a developer note to explain what consumers should do when they observe an unknown value, there's typically two options there
Suggested change
|
||||||||||
|
|
||||||||||
| // vsphere is used to configure the vsphere CSI driver. | ||||||||||
| // +optional | ||||||||||
| VSphere *VSphereCSIDriverConfigSpec `json:"vSphere,omitempty"` | ||||||||||
| } | ||||||||||
|
|
||||||||||
| // VSphereCSIDriverConfigSpec defines properties that | ||||||||||
| // can be configured for vsphere CSI driver. | ||||||||||
| type VSphereCSIDriverConfigSpec struct { | ||||||||||
| // topologyCategories indicates tag categories with which | ||||||||||
| // vcenter resources such as hostcluster or datacenter were tagged with. | ||||||||||
| // If cluster Infrastructure object has a topology, values specified in | ||||||||||
| // Infrastructure object will be used and modifications to topologyCategories | ||||||||||
| // will be rejected. | ||||||||||
| // +optional | ||||||||||
| TopologyCategories []string `json:"topologyCategories,omitempty"` | ||||||||||
| } | ||||||||||
|
|
||||||||||
| // ClusterCSIDriverStatus is the observed status of CSI driver operator | ||||||||||
|
|
||||||||||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Uh oh!
There was an error while loading. Please reload this page.