Adding vShpere volume section to Volumes doc
This documentation is being added in reference to vSphere cloud provider support work (issue #23932)
This commit is contained in:
@@ -69,6 +69,7 @@ Kubernetes supports several types of Volumes:
|
|||||||
* `persistentVolumeClaim`
|
* `persistentVolumeClaim`
|
||||||
* `downwardAPI`
|
* `downwardAPI`
|
||||||
* `azureFileVolume`
|
* `azureFileVolume`
|
||||||
|
* `vsphereVirtualDisk`
|
||||||
|
|
||||||
We welcome additional contributions.
|
We welcome additional contributions.
|
||||||
|
|
||||||
@@ -379,6 +380,44 @@ into a Pod.
|
|||||||
|
|
||||||
More details can be found [here](https://github.com/kubernetes/kubernetes/tree/{{page.githubbranch}}/examples/azure_file/README.md)
|
More details can be found [here](https://github.com/kubernetes/kubernetes/tree/{{page.githubbranch}}/examples/azure_file/README.md)
|
||||||
|
|
||||||
|
### vsphereVirtualDisk
|
||||||
|
|
||||||
|
A `VSphereVirtualDisk` is used to mount a vSphere VMDK Volume into your Pod. The contents
|
||||||
|
of a volume are preserved when it is unmounted.
|
||||||
|
|
||||||
|
__Important: You must create a VMDK volume using `vmware-vdiskmanager -c` or
|
||||||
|
the VSphere API before you can use it__
|
||||||
|
|
||||||
|
#### Creating a VMDK volume
|
||||||
|
|
||||||
|
Before you can use a vSphere volume with a pod, you need to create it.
|
||||||
|
|
||||||
|
```shell
|
||||||
|
vmware-vdiskmanager -c -t 0 -s 40GB -a lsilogic myDisk.vmdk
|
||||||
|
```
|
||||||
|
|
||||||
|
#### vSphere VMDK Example configuration
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Pod
|
||||||
|
metadata:
|
||||||
|
name: test-vmdk
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- image: gcr.io/google_containers/test-webserver
|
||||||
|
name: test-container
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /test-vmdk
|
||||||
|
name: test-volume
|
||||||
|
volumes:
|
||||||
|
- name: test-volume
|
||||||
|
# This VMDK volume must already exist.
|
||||||
|
vsphereVirtualDisk:
|
||||||
|
volumePath: myDisk
|
||||||
|
fsType: ext4
|
||||||
|
```
|
||||||
|
|
||||||
## Resources
|
## Resources
|
||||||
|
|
||||||
The storage media (Disk, SSD, etc) of an `emptyDir` volume is determined by the
|
The storage media (Disk, SSD, etc) of an `emptyDir` volume is determined by the
|
||||||
|
|||||||
Reference in New Issue
Block a user