title: Kubernetes : Dynamic Persistent Volume provisioning using NFS
body: <p>I have multi node kubernetes setup. I am trying to allocate a Persistent volume dynamically using storage classes with NFS volume plugin. 
  I found storage classes examples for glusterfs, aws-ebs, etc.but, I didn't find any example for NFS.
  If I create PV and PVC only then NFS works very well(Without storage class).
  I tried to write storage class file for NFS, by referring other plugins. please refer it below,</p>
  
  <p>nfs-storage-class.yaml</p>
  
  <pre><code>kind: StorageClass
  apiVersion: storage.k8s.io/v1beta1
  metadata:
    namespace: kube-system
    name: my-storage
    annotations:
      storageclass.beta.kubernetes.io/is-default-class: "true"
    labels:
      kubernetes.io/cluster-service: "true"
  
  provisioner: kubernetes.io/nfs
  parameters:
    path: /nfsfileshare
    server: &lt;nfs-server-ip&gt; 
  </code></pre>
  
  <p>nfs-pv-claim.yaml</p>
  
  <pre><code>apiVersion: v1
  metadata:
    name: demo-claim
    annotations:
      volume.beta.kubernetes.io/storage-class: my-storage
  spec:
    accessModes:
      - ReadWriteOnce
    resources:
      requests:
        storage: 3Gi
  </code></pre>
  
  <p>It didn't worked. So, my question is, Can we write a storage class for NFS? Does it support dynamic provisioing?</p>