aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml
diff options
context:
space:
mode:
authorHao Kuang <Hao.Kuang@amdocs.com>2017-12-15 20:38:03 +0000
committerHao Kuang <Hao.Kuang@amdocs.com>2017-12-20 16:43:29 +0000
commit27af4a308d56795eddb08d07cbb86d8651c4f5a2 (patch)
treea2acc5bff9251f6f5c00f859488c289c7f3211c2 /kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml
parenta6eb9be0e091746c824b169a46242ef0943a2b05 (diff)
Single K8S Node Of Deploying SDNC Cluster POC
It's a reference of how to deploy sdnc cluster under single node k8s environment. Currently the config of nfs for mysql db only supports one k8s node. For mutiple nodes, because of dockernfs mount, nfs provisioner has conflict with it, which fails mount operation of SDNC pod. Also, if SDNC needs to fully utilize mysql cluster under k8s, in core project, DbLibService.java should be enhanced to support that writing to master only and reading from them. Issue-ID: SDNC-163 Change-Id: I85ad327f2fe04fe8e9a135289d7c25a917234438 Signed-off-by: Hao Kuang <Hao.Kuang@amdocs.com>
Diffstat (limited to 'kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml')
-rw-r--r--kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml55
1 files changed, 55 insertions, 0 deletions
diff --git a/kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml b/kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml
new file mode 100644
index 0000000000..9d3feeff9c
--- /dev/null
+++ b/kubernetes/sdnc/templates/nfs-provisoner-deployment.yaml
@@ -0,0 +1,55 @@
+#{{ if not .Values.disableSdncSdncDbhost }}
+kind: Deployment
+apiVersion: extensions/v1beta1
+metadata:
+ name: nfs-provisioner
+ namespace: "{{ .Values.nsPrefix }}-sdnc"
+spec:
+ replicas: 1
+ strategy:
+ type: Recreate
+ template:
+ metadata:
+ labels:
+ app: nfs-provisioner
+ spec:
+ containers:
+ - name: nfs-provisioner
+ image: quay.io/kubernetes_incubator/nfs-provisioner:v1.0.8
+ ports:
+ - name: nfs
+ containerPort: 2049
+ - name: mountd
+ containerPort: 20048
+ - name: rpcbind
+ containerPort: 111
+ - name: rpcbind-udp
+ containerPort: 111
+ protocol: UDP
+ securityContext:
+ capabilities:
+ add:
+ - DAC_READ_SEARCH
+ - SYS_RESOURCE
+ args:
+ - "-provisioner=sdnc/nfs"
+ env:
+ - name: POD_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ - name: SERVICE_NAME
+ value: nfs-provisioner
+ - name: POD_NAMESPACE
+ valueFrom:
+ fieldRef:
+ fieldPath: metadata.namespace
+ imagePullPolicy: "IfNotPresent"
+ volumeMounts:
+ - name: export-volume
+ mountPath: /export
+ volumes:
+ - name: export-volume
+ hostPath:
+ path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdnc/data
+#{{ end }}