4 * Version information
\r
7 root@proxy:~# cat /etc/issue
\r
8 Ubuntu 16.04.2 LTS \n \l
\r
12 * Version information
\r
15 root@proxy:~# docker version
\r
21 Built: Tue Jan 31 23:35:14 2017
\r
22 OS/Arch: linux/amd64
\r
29 Built: Tue Jan 31 23:35:14 2017
\r
30 OS/Arch: linux/amd64
\r
33 ### [kubernetes](https://github.com/kubernetes/kubernetes) local cluster
\r
34 * You can startup the v1.9.0 k8s local cluster by executing commands blow:
\r
38 git clone https://github.com/kubernetes/kubernetes.git
\r
42 echo alias kubectl='$HOME/kubernetes/cluster/kubectl.sh' >> /etc/profile
\r
43 ALLOW_PRIVILEGED=true FEATURE_GATES=CSIPersistentVolume=true,MountPropagation=true RUNTIME_CONFIG="storage.k8s.io/v1alpha1=true" LOG_LEVEL=5 hack/local-up-cluster.sh
\r
46 ### [opensds](https://github.com/opensds/opensds) local cluster
\r
47 * For testing purposes you can deploy OpenSDS refering to ```ansible/README.md```.
\r
51 * Change the workplace
\r
54 cd /opt/opensds-k8s-v0.1.0-linux-amd64
\r
57 * Configure opensds endpoint IP
\r
60 vim csi/deploy/kubernetes/csi-configmap-opensdsplugin.yaml
\r
63 The IP (127.0.0.1) should be replaced with the opensds actual endpoint IP.
\r
68 name: csi-configmap-opensdsplugin
\r
70 opensdsendpoint: http://127.0.0.1:50040
\r
73 * Create opensds CSI pods.
\r
76 kubectl create -f csi/deploy/kubernetes
\r
79 After this three pods can be found by ```kubectl get pods``` like below:
\r
81 - csi-provisioner-opensdsplugin
\r
82 - csi-attacher-opensdsplugin
\r
83 - csi-nodeplugin-opensdsplugin
\r
85 You can find more design details from
\r
86 [CSI Volume Plugins in Kubernetes Design Doc](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/storage/container-storage-interface.md)
\r
88 * Create example nginx application
\r
91 kubectl create -f csi/examples/kubernetes/nginx.yaml
\r
94 This example will mount a opensds volume into ```/var/lib/www/html```.
\r
96 You can use the following command to inspect into nginx container to verify it.
\r
99 docker exec -it <nginx container id> /bin/bash
\r
102 ## Clean up steps ##
\r
104 Clean up example nginx application and opensds CSI pods by the following commands.
\r
107 kubectl delete -f csi/examples/kubernetes/nginx.yaml
\r
108 kubectl delete -f csi/deploy/kubernetes
\r