Terraform-provider-kubernetes: Feature Request: Container Storage Interface Support for Persistent Volumes

Created on 3 Feb 2019  ·  8Comments  ·  Source: hashicorp/terraform-provider-kubernetes

Container Storage Interface (CSI) has been promoted to GA in the Kubernetes v1.13 release. This would add support for multiple cloud providers/custom solutions with one spec.

The API is relatively simple since most of the work is handled by the external driver.

acknowledged enhancement needs investigation sizL themcoverage

Most helpful comment

Would really appreciate if the above PRs were reviewed and accepted soon. Similar to what others have already noted, this blocks us from terraforming EKS-EFS integration: https://github.com/kubernetes-sigs/aws-efs-csi-driver

All 8 comments

As this is the new recommend way to use AWS EFS with EKS. Would like to use it via terraform.

apiVersion: storage.k8s.io/v1beta1
kind: CSIDriver
metadata:
name: efs.csi.aws.com
spec:
attachRequired: false

ref: https://github.com/kubernetes-sigs/aws-efs-csi-driver/blob/master/deploy/kubernetes/base/csidriver.yaml

Supporting CSI is the only way AFAIK that we can use terraform with Longhorn volumes.

apiVersion: v1
kind: PersistentVolume
metadata:
  name: longhorn-vol-pv
spec:
  capacity:
    storage: 2Gi
  volumeMode: Filesystem
  accessModes:
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Delete
  storageClassName: longhorn
  csi:
    driver: driver.longhorn.io
    fsType: ext4
    volumeAttributes:
      numberOfReplicas: '3'
      staleReplicaTimeout: '2880'
    volumeHandle: existing-longhorn-volume

Hi, is there a plan to have support for this?

i opened up 2 PRs that are relevant for this:

  1. support csi for persistent volumes - #817
  2. support for creating a CSI driver - #825

Would really appreciate if the above PRs were reviewed and accepted soon. Similar to what others have already noted, this blocks us from terraforming EKS-EFS integration: https://github.com/kubernetes-sigs/aws-efs-csi-driver

Both related PRs merged, thanks @jrhouston!

Given #817 and #825 are merged, I believe this can now be closed. Thanks for your help @DrFaust92

I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

Was this page helpful?
0 / 5 - 0 ratings