Merge pull request #212 from noelbundick/azure-managed-disk

Add details on mounting existing Azure Managed Disks
This commit is contained in:
k8s-ci-robot 2018-04-02 13:38:16 -07:00 committed by GitHub
commit 11aa742952
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 2 deletions

View File

@ -4,8 +4,9 @@ On Azure VM, create a Pod using the volume spec based on [azure](azure.yaml).
In the pod, you need to provide the following information:
- *diskName*: (required) the name of the VHD blob object.
- *diskURI*: (required) the URI of the vhd blob object.
- *diskName*: (required) the name of the VHD blob object OR the name of an Azure managed data disk if Kind is Managed.
- *diskURI*: (required) the URI of the vhd blob object OR the resourceID of an Azure managed data disk if Kind is Managed.
- *kind*: (optional) kind of disk. Must be one of Shared (multiple disks per storage account), Dedicated (single blob disk per storage account), or Managed (Azure managed data disk). Default is Shared.
- *cachingMode*: (optional) disk caching mode. Must be one of None, ReadOnly, or ReadWrite. Default is None.
- *fsType*: (optional) the filesystem type to mount. Default is ext4.
- *readOnly*: (optional) whether the filesystem is used as readOnly. Default is false.

View File

@ -0,0 +1,24 @@
kind: Pod
apiVersion: v1
metadata:
name: pod-uses-managed-ssd-5g
labels:
name: storage
spec:
containers:
- image: nginx
name: az-c-01
command:
- /bin/sh
- -c
- while true; do echo $(date) >> /mnt/managed/outfile; sleep 1; done
volumeMounts:
- name: managed01
mountPath: /mnt/managed
volumes:
- name: managed01
azureDisk:
kind: Managed
diskName: myDisk
diskURI: /subscriptions/<subscriptionID>/resourceGroups/<resourceGroup>/providers/Microsoft.Compute/disks/<diskName>