Updated Env launch and storage setup
Variables updated to be similar to other scripts.
Updated the headers to be similar to other scripts.
Change-Id: I0c2778f126a3e65ecde894ca364ef5f28ced6cec
Signed-off-by: Alanny Lopez <alannyglopez@gmail.com>
diff --git a/kubernetes/storage-setup.sh b/kubernetes/storage-setup.sh
index 10ac76a..fa5cc46 100755
--- a/kubernetes/storage-setup.sh
+++ b/kubernetes/storage-setup.sh
@@ -15,30 +15,37 @@
###############################################################################
#
# The script expects a few variables which are needed to define PV's and PVC's
-# ns = Namespace under which to create the mounts on the cluster
-# nfsip = Server IP for NFS server that will be used
-# nfspath = Path of the directory that will be mounted from NFS server
-# size = The size of the volume, numeric value followed by Gi or Mi
-# name = The name of the PV and PVC that will be used by the Kubernetes
-# system to refer to PV/PVC
-# mode = ReadWriteOnce|ReadOnlyMany|ReadWriteMany
-# Access Mode used by NFS normally uses ReadWriteMany
-# reclaim = recycle|delete|retain
-# The policy, defines what occurs when claim on PV is released, can
-# be either: recycle, delete, or retain.
+# mode ReadWriteOnce|ReadOnlyMany|ReadWriteMany
+# Access Mode used by NFS normally uses ReadWriteMany
+# Default: ReadWriteMany
+# name The name of the PV and PVC that will be used by the Kubernetes
+# system to refer to PV/PVC
+# Default: "placeholder"
+# nfs_ip Server IP for NFS server that will be used
+# Default: "NFS-Server"
+# nfs_path Path of the directory that will be mounted from NFS server
+# Default: "/san/dir"
+# ns Namespace under which to create the mounts on the cluster
+# Default: "openbmc"
+# reclaim recycle|delete|retain
+# The policy, defines what occurs when claim on PV is released, can
+# be either: recycle, delete, or retain.
+# Default: "Retain"
+# size The size of the volume, numeric value followed by Gi or Mi
+# Default: "10Gi"
#
# Note: Kubernetes Systems permissions vary by implementation
# some will require permissions to create PV's or PVC's
#
###############################################################################
-ns=${ns:-openbmc}
-nfsip=${nfsip:-NFS-Server}
-nfspath=${nfspath:-/san/dir}
-size=${size:-10Gi}
-name=${name:-placeholder}
mode=${mode:-ReadWriteMany}
+name=${name:-placeholder}
+nfs_ip=${nfs_ip:-NFS-Server}
+nfs_path=${nfs_path:-/san/dir}
+ns=${ns:-openbmc}
reclaim=${reclaim:-Retain}
+size=${size:-10Gi}
# Generate the PV
pv=$(cat << EOF
@@ -55,8 +62,8 @@
capacity:
storage: ${size}
nfs:
- path: ${nfspath}
- server: ${nfsip}
+ path: ${nfs_path}
+ server: ${nfs_ip}
persistentVolumeReclaimPolicy: ${reclaim}
EOF
)