Skip to content

Commit

Permalink
Overall docs for CSI Migration feature (#12935)
Browse files Browse the repository at this point in the history
* Placeholder docs for CSI Migration feature

Signed-off-by: Deep Debroy <[email protected]>

* Address CR comments and update feature gates

Signed-off-by: Deep Debroy <[email protected]>

* Add mappings for CSI plugins

Signed-off-by: Deep Debroy <[email protected]>

* Add sections for AWS and GCE PD migration

Signed-off-by: Deep Debroy <[email protected]>

* Add docs for Cinder and CSI Migration info

Signed-off-by: Deep Debroy <[email protected]>

* Clarify scope to volumes with file system

Signed-off-by: Deep Debroy <[email protected]>

* Change the format of EBS and Cinder CSI Migration sections to follow the GCE template

Signed-off-by: Deep Debroy <[email protected]>
  • Loading branch information
ddebroy authored and k8s-ci-robot committed Mar 19, 2019
1 parent 965a801 commit cb0b9d0
Show file tree
Hide file tree
Showing 2 changed files with 90 additions and 0 deletions.
82 changes: 82 additions & 0 deletions content/en/docs/concepts/storage/volumes.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ Kubernetes supports several types of Volumes:
* [azureDisk](#azuredisk)
* [azureFile](#azurefile)
* [cephfs](#cephfs)
* [cinder](#cinder)
* [configMap](#configmap)
* [csi](#csi)
* [downwardAPI](#downwardapi)
Expand Down Expand Up @@ -148,6 +149,17 @@ spec:
fsType: ext4
```
#### CSI Migration
{{< feature-state for_k8s_version="v1.14" state="alpha" >}}
The CSI Migration feature for awsElasticBlockStore, when enabled, shims all plugin operations
from the existing in-tree plugin to the `ebs.csi.aws.com` Container
Storage Interface (CSI) Driver. In order to use this feature, the [AWS EBS CSI
Driver](https://github.com/kubernetes-sigs/aws-ebs-csi-driver)
must be installed on the cluster and the `CSIMigration` and `CSIMigrationAWS`
Alpha features must be enabled.

### azureDisk {#azuredisk}

A `azureDisk` is used to mount a Microsoft Azure [Data Disk](https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-linux-about-disks-vhds/) into a Pod.
Expand Down Expand Up @@ -176,6 +188,48 @@ You must have your own Ceph server running with the share exported before you ca

See the [CephFS example](https://github.com/kubernetes/examples/tree/{{< param "githubbranch" >}}/staging/volumes/cephfs/) for more details.

### cinder {#cinder}

{{< note >}}
Prerequisite: Kubernetes with OpenStack Cloud Provider configured. For cloudprovider
configuration please refer [cloud provider openstack](https://kubernetes.io/docs/concepts/cluster-administration/cloud-providers/#openstack).
{{< /note >}}

`cinder` is used to mount OpenStack Cinder Volume into your Pod.

#### Cinder Volume Example configuration

```yaml
apiVersion: v1
kind: Pod
metadata:
name: test-cinder
spec:
containers:
- image: k8s.gcr.io/test-webserver
name: test-cinder-container
volumeMounts:
- mountPath: /test-cinder
name: test-volume
volumes:
- name: test-volume
# This OpenStack volume must already exist.
cinder:
volumeID: <volume-id>
fsType: ext4
```

#### CSI Migration

{{< feature-state for_k8s_version="v1.14" state="alpha" >}}

The CSI Migration feature for Cinder, when enabled, shims all plugin operations
from the existing in-tree plugin to the `cinder.csi.openstack.org` Container
Storage Interface (CSI) Driver. In order to use this feature, the [Openstack Cinder CSI
Driver](https://github.com/kubernetes/cloud-provider-openstack/blob/master/docs/using-cinder-csi-plugin.md)
must be installed on the cluster and the `CSIMigration` and `CSIMigrationOpenStack`
Alpha features must be enabled.

### configMap {#configmap}

The [`configMap`](/docs/tasks/configure-pod-container/configure-pod-configmap/) resource
Expand Down Expand Up @@ -401,6 +455,17 @@ spec:
fsType: ext4
```

#### CSI Migration

{{< feature-state for_k8s_version="v1.14" state="alpha" >}}

The CSI Migration feature for GCE PD, when enabled, shims all plugin operations
from the existing in-tree plugin to the `pd.csi.storage.gke.io` Container
Storage Interface (CSI) Driver. In order to use this feature, the [GCE PD CSI
Driver](https://github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver)
must be installed on the cluster and the `CSIMigration` and `CSIMigrationGCE`
Alpha features must be enabled.

### gitRepo (deprecated) {#gitrepo}

{{< warning >}}
Expand Down Expand Up @@ -1267,6 +1332,23 @@ CSI ephemeral volumes are only supported by a subset of CSI drivers. Please see
For more information on how to develop a CSI driver, refer to the [kubernetes-csi
documentation](https://kubernetes-csi.github.io/docs/)

#### Migrating to CSI drivers from in-tree plugins

{{< feature-state for_k8s_version="v1.14" state="alpha" >}}

The CSI Migration feature, when enabled, directs operations against existing in-tree
plugins to corresponding CSI plugins (which are expected to be installed and configured).
The feature implements the necessary translation logic and shims to re-route the
operations in a seamless fashion. As a result, operators do not have to make any
configuration changes to existing Storage Classes, PVs or PVCs (referring to
in-tree plugins) when transitioning to a CSI driver that supersedes an in-tree plugin.

In the alpha state, the operations and features that are supported include
provisioning/delete, attach/detach and mount/unmount of volumes with `volumeMode` set to `filesystem`

In-tree plugins that support CSI Migration and have a corresponding CSI driver implemented
are listed in the "Types of Volumes" section above.

### Flexvolume {#flexVolume}

Flexvolume is an out-of-tree plugin interface that has existed in Kubernetes
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ different Kubernetes components.
| `CSIDriverRegistry` | `false` | Alpha | 1.12 | 1.13 |
| `CSIDriverRegistry` | `true` | Beta | 1.14 | |
| `CSIInlineVolume` | `false` | Alpha | 1.14 | - |
| `CSIMigration` | `false` | Alpha | 1.14 | |
| `CSIMigrationAWS` | `false` | Alpha | 1.14 | |
| `CSIMigrationGCE` | `false` | Alpha | 1.14 | |
| `CSIMigrationOpenStack` | `false` | Alpha | 1.14 | |
| `CSINodeInfo` | `false` | Alpha | 1.12 | 1.13 |
| `CSINodeInfo` | `true` | Beta | 1.14 | |
| `CSIPersistentVolume` | `false` | Alpha | 1.9 | 1.9 |
Expand Down Expand Up @@ -221,6 +225,10 @@ Each feature gate is designed for enabling/disabling a specific feature:
- `CRIContainerLogRotation`: Enable container log rotation for cri container runtime.
- `CSIBlockVolume`: Enable external CSI volume drivers to support block storage. See the [`csi` raw block volume support](/docs/concepts/storage/volumes/#csi-raw-block-volume-support) documentation for more details.
- `CSIDriverRegistry`: Enable all logic related to the CSIDriver API object in csi.storage.k8s.io.
- `CSIMigration`: Enables shims and translation logic to route volume operations from in-tree plugins to corresponding pre-installed CSI plugins
- `CSIMigrationAWS`: Enables shims and translation logic to route volume operations from the AWS-EBS in-tree plugin to EBS CSI plugin
- `CSIMigrationGCE`: Enables shims and translation logic to route volume operations from the GCE-PD in-tree plugin to PD CSI plugin
- `CSIMigrationOpenStack`: Enables shims and translation logic to route volume operations from the Cinder in-tree plugin to Cinder CSI plugin
- `CSINodeInfo`: Enable all logic related to the CSINodeInfo API object in csi.storage.k8s.io.
- `CSIPersistentVolume`: Enable discovering and mounting volumes provisioned through a
[CSI (Container Storage Interface)](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/storage/container-storage-interface.md)
Expand Down

0 comments on commit cb0b9d0

Please sign in to comment.