-
-
Save kincl/ed5efdb05e8a3f6bba004cdfc0f42d3f to your computer and use it in GitHub Desktop.
Simplified NFS storage for OpenShift
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git clone https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner.git | |
cd nfs-subdir-external-provisioner | |
sed -i.backup 's/nfs-client/nfs-storage/g' ./deploy/class.yaml | |
sed -i.backup 's/namespace:.*/namespace: nfs-storage/g' ./deploy/rbac.yaml | |
sed -i.backup 's/namespace:.*/namespace: nfs-storage/g' ./deploy/deployment.yaml | |
vi ./deploy/deployment.yaml | |
# Update NFS_SERVER and NFS_PATH values (4 edits required) | |
diff -U0 ./deploy/class.yaml{.backup,} | |
diff -U0 ./deploy/rbac.yaml{.backup,} | |
diff -U0 ./deploy/deployment.yaml{.backup,} | |
oc new-project nfs-storage | |
oc create -f ./deploy/rbac.yaml | |
oc adm policy add-scc-to-user hostmount-anyuid system:serviceaccount:nfs-storage:nfs-client-provisioner | |
oc create -f ./deploy/deployment.yaml | |
oc create -f ./deploy/class.yaml | |
oc annotate storageclass/nfs-storage storageclass.kubernetes.io/is-default-class=true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment