mirror of https://github.com/k3s-io/k3s
CSI - Generated source code
This commit tracks all auto-generated sources.pull/6/head
parent
af0c2bda94
commit
c4a17304d5
|
@ -73464,6 +73464,27 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
"io.k8s.api.core.v1.CSIPersistentVolumeSource": {
|
||||
"description": "Represents storage that is managed by an external CSI volume driver",
|
||||
"required": [
|
||||
"driver",
|
||||
"volumeHandle"
|
||||
],
|
||||
"properties": {
|
||||
"driver": {
|
||||
"description": "Driver is the name of the driver to use for this volume. Required.",
|
||||
"type": "string"
|
||||
},
|
||||
"readOnly": {
|
||||
"description": "Optional: The value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write).",
|
||||
"type": "boolean"
|
||||
},
|
||||
"volumeHandle": {
|
||||
"description": "VolumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required.",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"io.k8s.api.core.v1.Capabilities": {
|
||||
"description": "Adds and removes POSIX capabilities from running containers.",
|
||||
"properties": {
|
||||
|
@ -75812,6 +75833,10 @@
|
|||
"description": "ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding",
|
||||
"$ref": "#/definitions/io.k8s.api.core.v1.ObjectReference"
|
||||
},
|
||||
"csi": {
|
||||
"description": "CSI represents storage that handled by an external CSI driver",
|
||||
"$ref": "#/definitions/io.k8s.api.core.v1.CSIPersistentVolumeSource"
|
||||
},
|
||||
"fc": {
|
||||
"description": "FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.",
|
||||
"$ref": "#/definitions/io.k8s.api.core.v1.FCVolumeSource"
|
||||
|
|
|
@ -20592,6 +20592,10 @@
|
|||
"$ref": "v1.StorageOSPersistentVolumeSource",
|
||||
"description": "StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md"
|
||||
},
|
||||
"csi": {
|
||||
"$ref": "v1.CSIPersistentVolumeSource",
|
||||
"description": "CSI represents storage that handled by an external CSI driver"
|
||||
},
|
||||
"accessModes": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
|
@ -21250,6 +21254,28 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"v1.CSIPersistentVolumeSource": {
|
||||
"id": "v1.CSIPersistentVolumeSource",
|
||||
"description": "Represents storage that is managed by an external CSI volume driver",
|
||||
"required": [
|
||||
"driver",
|
||||
"volumeHandle"
|
||||
],
|
||||
"properties": {
|
||||
"driver": {
|
||||
"type": "string",
|
||||
"description": "Driver is the name of the driver to use for this volume. Required."
|
||||
},
|
||||
"volumeHandle": {
|
||||
"type": "string",
|
||||
"description": "VolumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required."
|
||||
},
|
||||
"readOnly": {
|
||||
"type": "boolean",
|
||||
"description": "Optional: The value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write)."
|
||||
}
|
||||
}
|
||||
},
|
||||
"v1.PersistentVolumeStatus": {
|
||||
"id": "v1.PersistentVolumeStatus",
|
||||
"description": "PersistentVolumeStatus is the current status of a persistent volume.",
|
||||
|
|
|
@ -3651,6 +3651,54 @@ The resulting set of endpoints can be viewed as:<br>
|
|||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<div class="sect2">
|
||||
<h3 id="_v1_csipersistentvolumesource">v1.CSIPersistentVolumeSource</h3>
|
||||
<div class="paragraph">
|
||||
<p>Represents storage that is managed by an external CSI volume driver</p>
|
||||
</div>
|
||||
<table class="tableblock frame-all grid-all" style="width:100%; ">
|
||||
<colgroup>
|
||||
<col style="width:20%;">
|
||||
<col style="width:20%;">
|
||||
<col style="width:20%;">
|
||||
<col style="width:20%;">
|
||||
<col style="width:20%;">
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="tableblock halign-left valign-top">Name</th>
|
||||
<th class="tableblock halign-left valign-top">Description</th>
|
||||
<th class="tableblock halign-left valign-top">Required</th>
|
||||
<th class="tableblock halign-left valign-top">Schema</th>
|
||||
<th class="tableblock halign-left valign-top">Default</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">driver</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">Driver is the name of the driver to use for this volume. Required.</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">true</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">string</p></td>
|
||||
<td class="tableblock halign-left valign-top"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">volumeHandle</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">VolumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required.</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">true</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">string</p></td>
|
||||
<td class="tableblock halign-left valign-top"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">readOnly</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">Optional: The value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write).</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">false</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">boolean</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">false</p></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<div class="sect2">
|
||||
<h3 id="_v1_persistentvolumeclaimcondition">v1.PersistentVolumeClaimCondition</h3>
|
||||
|
@ -7745,6 +7793,13 @@ Examples:<br>
|
|||
<td class="tableblock halign-left valign-top"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">csi</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">CSI represents storage that handled by an external CSI driver</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">false</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="#_v1_csipersistentvolumesource">v1.CSIPersistentVolumeSource</a></p></td>
|
||||
<td class="tableblock halign-left valign-top"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">accessModes</p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">AccessModes contains all ways the volume can be mounted. More info: <a href="https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes">https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes</a></p></td>
|
||||
<td class="tableblock halign-left valign-top"><p class="tableblock">false</p></td>
|
||||
|
|
|
@ -55,6 +55,8 @@ func RegisterConversions(scheme *runtime.Scheme) error {
|
|||
Convert_core_AzureFileVolumeSource_To_v1_AzureFileVolumeSource,
|
||||
Convert_v1_Binding_To_core_Binding,
|
||||
Convert_core_Binding_To_v1_Binding,
|
||||
Convert_v1_CSIPersistentVolumeSource_To_core_CSIPersistentVolumeSource,
|
||||
Convert_core_CSIPersistentVolumeSource_To_v1_CSIPersistentVolumeSource,
|
||||
Convert_v1_Capabilities_To_core_Capabilities,
|
||||
Convert_core_Capabilities_To_v1_Capabilities,
|
||||
Convert_v1_CephFSPersistentVolumeSource_To_core_CephFSPersistentVolumeSource,
|
||||
|
@ -600,6 +602,30 @@ func Convert_core_Binding_To_v1_Binding(in *core.Binding, out *v1.Binding, s con
|
|||
return autoConvert_core_Binding_To_v1_Binding(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1_CSIPersistentVolumeSource_To_core_CSIPersistentVolumeSource(in *v1.CSIPersistentVolumeSource, out *core.CSIPersistentVolumeSource, s conversion.Scope) error {
|
||||
out.Driver = in.Driver
|
||||
out.VolumeHandle = in.VolumeHandle
|
||||
out.ReadOnly = in.ReadOnly
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1_CSIPersistentVolumeSource_To_core_CSIPersistentVolumeSource is an autogenerated conversion function.
|
||||
func Convert_v1_CSIPersistentVolumeSource_To_core_CSIPersistentVolumeSource(in *v1.CSIPersistentVolumeSource, out *core.CSIPersistentVolumeSource, s conversion.Scope) error {
|
||||
return autoConvert_v1_CSIPersistentVolumeSource_To_core_CSIPersistentVolumeSource(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_core_CSIPersistentVolumeSource_To_v1_CSIPersistentVolumeSource(in *core.CSIPersistentVolumeSource, out *v1.CSIPersistentVolumeSource, s conversion.Scope) error {
|
||||
out.Driver = in.Driver
|
||||
out.VolumeHandle = in.VolumeHandle
|
||||
out.ReadOnly = in.ReadOnly
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_core_CSIPersistentVolumeSource_To_v1_CSIPersistentVolumeSource is an autogenerated conversion function.
|
||||
func Convert_core_CSIPersistentVolumeSource_To_v1_CSIPersistentVolumeSource(in *core.CSIPersistentVolumeSource, out *v1.CSIPersistentVolumeSource, s conversion.Scope) error {
|
||||
return autoConvert_core_CSIPersistentVolumeSource_To_v1_CSIPersistentVolumeSource(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1_Capabilities_To_core_Capabilities(in *v1.Capabilities, out *core.Capabilities, s conversion.Scope) error {
|
||||
out.Add = *(*[]core.Capability)(unsafe.Pointer(&in.Add))
|
||||
out.Drop = *(*[]core.Capability)(unsafe.Pointer(&in.Drop))
|
||||
|
@ -3144,6 +3170,7 @@ func autoConvert_v1_PersistentVolumeSource_To_core_PersistentVolumeSource(in *v1
|
|||
out.ScaleIO = (*core.ScaleIOPersistentVolumeSource)(unsafe.Pointer(in.ScaleIO))
|
||||
out.Local = (*core.LocalVolumeSource)(unsafe.Pointer(in.Local))
|
||||
out.StorageOS = (*core.StorageOSPersistentVolumeSource)(unsafe.Pointer(in.StorageOS))
|
||||
out.CSI = (*core.CSIPersistentVolumeSource)(unsafe.Pointer(in.CSI))
|
||||
return nil
|
||||
}
|
||||
|
||||
|
@ -3174,6 +3201,7 @@ func autoConvert_core_PersistentVolumeSource_To_v1_PersistentVolumeSource(in *co
|
|||
out.ScaleIO = (*v1.ScaleIOPersistentVolumeSource)(unsafe.Pointer(in.ScaleIO))
|
||||
out.Local = (*v1.LocalVolumeSource)(unsafe.Pointer(in.Local))
|
||||
out.StorageOS = (*v1.StorageOSPersistentVolumeSource)(unsafe.Pointer(in.StorageOS))
|
||||
out.CSI = (*v1.CSIPersistentVolumeSource)(unsafe.Pointer(in.CSI))
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
@ -1318,7 +1318,7 @@ func validateStorageOSPersistentVolumeSource(storageos *core.StorageOSPersistent
|
|||
return allErrs
|
||||
}
|
||||
|
||||
func validateCSIPersistentVolumeSource(csi *api.CSIPersistentVolumeSource, fldPath *field.Path) field.ErrorList {
|
||||
func validateCSIPersistentVolumeSource(csi *core.CSIPersistentVolumeSource, fldPath *field.Path) field.ErrorList {
|
||||
allErrs := field.ErrorList{}
|
||||
|
||||
if !utilfeature.DefaultFeatureGate.Enabled(features.CSIPersistentVolume) {
|
||||
|
|
|
@ -246,6 +246,22 @@ func (in *Binding) DeepCopyObject() runtime.Object {
|
|||
}
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *CSIPersistentVolumeSource) DeepCopyInto(out *CSIPersistentVolumeSource) {
|
||||
*out = *in
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CSIPersistentVolumeSource.
|
||||
func (in *CSIPersistentVolumeSource) DeepCopy() *CSIPersistentVolumeSource {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(CSIPersistentVolumeSource)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *Capabilities) DeepCopyInto(out *Capabilities) {
|
||||
*out = *in
|
||||
|
@ -3159,6 +3175,15 @@ func (in *PersistentVolumeSource) DeepCopyInto(out *PersistentVolumeSource) {
|
|||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
}
|
||||
if in.CSI != nil {
|
||||
in, out := &in.CSI, &out.CSI
|
||||
if *in == nil {
|
||||
*out = nil
|
||||
} else {
|
||||
*out = new(CSIPersistentVolumeSource)
|
||||
**out = **in
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -108,6 +108,7 @@ filegroup(
|
|||
"//pkg/volume/cephfs:all-srcs",
|
||||
"//pkg/volume/cinder:all-srcs",
|
||||
"//pkg/volume/configmap:all-srcs",
|
||||
"//pkg/volume/csi:all-srcs",
|
||||
"//pkg/volume/downwardapi:all-srcs",
|
||||
"//pkg/volume/empty_dir:all-srcs",
|
||||
"//pkg/volume/fc:all-srcs",
|
||||
|
|
|
@ -0,0 +1,33 @@
|
|||
load("@io_bazel_rules_go//go:def.bzl", "go_library")
|
||||
|
||||
go_library(
|
||||
name = "go_default_library",
|
||||
srcs = [
|
||||
"csi_attacher.go",
|
||||
"csi_mounter.go",
|
||||
"csi_plugin.go",
|
||||
],
|
||||
importpath = "k8s.io/kubernetes/pkg/volume/csi",
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [
|
||||
"//pkg/util/mount:go_default_library",
|
||||
"//pkg/util/strings:go_default_library",
|
||||
"//pkg/volume:go_default_library",
|
||||
"//vendor/k8s.io/api/core/v1:go_default_library",
|
||||
"//vendor/k8s.io/apimachinery/pkg/types:go_default_library",
|
||||
],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "package-srcs",
|
||||
srcs = glob(["**"]),
|
||||
tags = ["automanaged"],
|
||||
visibility = ["//visibility:private"],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "all-srcs",
|
||||
srcs = [":package-srcs"],
|
||||
tags = ["automanaged"],
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
File diff suppressed because it is too large
Load Diff
|
@ -170,6 +170,23 @@ message Binding {
|
|||
optional ObjectReference target = 2;
|
||||
}
|
||||
|
||||
// Represents storage that is managed by an external CSI volume driver
|
||||
message CSIPersistentVolumeSource {
|
||||
// Driver is the name of the driver to use for this volume.
|
||||
// Required.
|
||||
optional string driver = 1;
|
||||
|
||||
// VolumeHandle is the unique volume name returned by the CSI volume
|
||||
// plugin’s CreateVolume to refer to the volume on all subsequent calls.
|
||||
// Required.
|
||||
optional string volumeHandle = 2;
|
||||
|
||||
// Optional: The value to pass to ControllerPublishVolumeRequest.
|
||||
// Defaults to false (read/write).
|
||||
// +optional
|
||||
optional bool readOnly = 3;
|
||||
}
|
||||
|
||||
// Adds and removes POSIX capabilities from running containers.
|
||||
message Capabilities {
|
||||
// Added capabilities
|
||||
|
@ -2356,6 +2373,10 @@ message PersistentVolumeSource {
|
|||
// More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md
|
||||
// +optional
|
||||
optional StorageOSPersistentVolumeSource storageos = 21;
|
||||
|
||||
// CSI represents storage that handled by an external CSI driver
|
||||
// +optional
|
||||
optional CSIPersistentVolumeSource csi = 22;
|
||||
}
|
||||
|
||||
// PersistentVolumeSpec is the specification of a persistent volume.
|
||||
|
|
|
@ -116,6 +116,17 @@ func (Binding) SwaggerDoc() map[string]string {
|
|||
return map_Binding
|
||||
}
|
||||
|
||||
var map_CSIPersistentVolumeSource = map[string]string{
|
||||
"": "Represents storage that is managed by an external CSI volume driver",
|
||||
"driver": "Driver is the name of the driver to use for this volume. Required.",
|
||||
"volumeHandle": "VolumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required.",
|
||||
"readOnly": "Optional: The value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write).",
|
||||
}
|
||||
|
||||
func (CSIPersistentVolumeSource) SwaggerDoc() map[string]string {
|
||||
return map_CSIPersistentVolumeSource
|
||||
}
|
||||
|
||||
var map_Capabilities = map[string]string{
|
||||
"": "Adds and removes POSIX capabilities from running containers.",
|
||||
"add": "Added capabilities",
|
||||
|
@ -1212,6 +1223,7 @@ var map_PersistentVolumeSource = map[string]string{
|
|||
"scaleIO": "ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.",
|
||||
"local": "Local represents directly-attached storage with node affinity",
|
||||
"storageos": "StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md",
|
||||
"csi": "CSI represents storage that handled by an external CSI driver",
|
||||
}
|
||||
|
||||
func (PersistentVolumeSource) SwaggerDoc() map[string]string {
|
||||
|
|
|
@ -246,6 +246,22 @@ func (in *Binding) DeepCopyObject() runtime.Object {
|
|||
}
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *CSIPersistentVolumeSource) DeepCopyInto(out *CSIPersistentVolumeSource) {
|
||||
*out = *in
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CSIPersistentVolumeSource.
|
||||
func (in *CSIPersistentVolumeSource) DeepCopy() *CSIPersistentVolumeSource {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(CSIPersistentVolumeSource)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *Capabilities) DeepCopyInto(out *Capabilities) {
|
||||
*out = *in
|
||||
|
@ -3145,6 +3161,15 @@ func (in *PersistentVolumeSource) DeepCopyInto(out *PersistentVolumeSource) {
|
|||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
}
|
||||
if in.CSI != nil {
|
||||
in, out := &in.CSI, &out.CSI
|
||||
if *in == nil {
|
||||
*out = nil
|
||||
} else {
|
||||
*out = new(CSIPersistentVolumeSource)
|
||||
**out = **in
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue