Merge "Rename robot docker from openecomp to onap"
authorMandeep Khinda <Mandeep.Khinda@amdocs.com>
Fri, 6 Apr 2018 15:30:07 +0000 (15:30 +0000)
committerGerrit Code Review <gerrit@onap.org>
Fri, 6 Apr 2018 15:30:07 +0000 (15:30 +0000)
24 files changed:
docs/oom_user_guide.rst
kubernetes/aaf/charts/aaf-cs/templates/deployment.yaml
kubernetes/aaf/charts/aaf-cs/values.yaml
kubernetes/aaf/charts/sms/Chart.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/Chart.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/templates/configmap.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/templates/pv.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/templates/pvc.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/templates/service.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/templates/statefulset.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/charts/vault/values.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/templates/configmap.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/templates/deployment.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/templates/service.yaml [new file with mode: 0644]
kubernetes/aaf/charts/sms/values.yaml [new file with mode: 0644]
kubernetes/aaf/templates/deployment.yaml
kubernetes/aaf/values.yaml
kubernetes/clamp/values.yaml
kubernetes/sdc/charts/sdc-wfd/.helmignore [new file with mode: 0644]
kubernetes/sdc/charts/sdc-wfd/Chart.yaml [new file with mode: 0644]
kubernetes/sdc/charts/sdc-wfd/templates/NOTES.txt [new file with mode: 0644]
kubernetes/sdc/charts/sdc-wfd/templates/deployment.yaml [new file with mode: 0644]
kubernetes/sdc/charts/sdc-wfd/templates/service.yaml [new file with mode: 0644]
kubernetes/sdc/charts/sdc-wfd/values.yaml [new file with mode: 0644]

index 97b2fde..1b9a3ea 100644 (file)
@@ -48,7 +48,48 @@ The OOM team with assistance from the ONAP project teams, have built a
 comprehensive set of Helm charts, yaml files very similar to TOSCA files, that
 describe the composition of each of the ONAP components and the relationship
 within and between components. Using this model Helm is able to deploy all of
-ONAP this simple command::
+ONAP with a few simple commands.
+
+Pre-requisites
+--------------
+Your environment must have both the Kubernetes `kubectl` and Helm setup as a one time activity.
+
+Install Kubectl
+~~~~~~~~~~~~~~~
+Enter the following to install kubectl (on Ubuntu, there are slight differences on other O/Ss), the Kubernetes command line interface used to manage a Kubernetes cluster::
+
+  > curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.8.6/bin/linux/amd64/kubectl
+  > chmod +x ./kubectl
+  > sudo mv ./kubectl /usr/local/bin/kubectl
+  > mkdir ~/.kube
+
+Paste kubectl config from Rancher (see the :ref:`cloud-setup-guide-label` for alternative Kubenetes environment setups) into the `~/.kube/config` file.
+
+Verify that the Kubernetes config is correct::
+
+  > kubectl get pods --all-namespaces
+
+At this point you should see six Kubernetes pods running.
+
+Install Helm
+~~~~~~~~~~~~
+Helm is used by OOM for package and configuration management. To install Helm, enter the following::
+
+  > wget http://storage.googleapis.com/kubernetes-helm/helm-v2.6.1-linux-amd64.tar.gz
+  > tar -zxvf helm-v2.6.1-linux-amd64.tar.gz
+  > sudo mv linux-amd64/helm /usr/local/bin/helm
+
+Verify the Helm version with::
+
+  > helm version
+
+Install the Helm Tiller application and initialize with::
+
+  > helm init
+
+Install the Helm Repo
+---------------------
+Once kubectl and Helm are setup, one needs to setup a local Helm server to server up the ONAP charts::
 
   > helm install osn/onap
 
@@ -68,10 +109,12 @@ stable which should be removed to avoid confusion::
 To prepare your system for an installation of ONAP, you'll need to::
 
   > git clone http://gerrit.onap.org/r/oom
-  > cd kubernetes
+  > cd oom/kubernetes
+
 
 To setup a local Helm server to server up the ONAP charts::
 
+  > helm init
   > helm serve &
 
 Note the port number that is listed and use it in the Helm repo add as follows::
index 80b99b2..15e574f 100644 (file)
@@ -36,7 +36,7 @@ spec:
       hostname: {{ include "common.name" . }}
       containers:
       - args:
-        image: "{{ .Values.repository | default .Values.global.repository }}/{{ .Values.image }}"
+        image: "{{ include "common.repository" . }}/{{ .Values.image }}"
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}
         volumeMounts:
index ea5445f..89b83cd 100644 (file)
 global:
   nodePortPrefix: 302
   repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
-  
-# If mountPath is over NFS (e.g. /dockerdata-nfs is NFS mounted between the nodes), uncomment following lines.
-#  persistence:
-#    mountPath: /dockerdata
+
 
 #################################################################
 # Application configuration defaults.
diff --git a/kubernetes/aaf/charts/sms/Chart.yaml b/kubernetes/aaf/charts/sms/Chart.yaml
new file mode 100644 (file)
index 0000000..962ef38
--- /dev/null
@@ -0,0 +1,18 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+description: ONAP Secret Management Service
+name: sms
+version: 2.0.0
diff --git a/kubernetes/aaf/charts/sms/charts/vault/Chart.yaml b/kubernetes/aaf/charts/sms/charts/vault/Chart.yaml
new file mode 100644 (file)
index 0000000..bf1af99
--- /dev/null
@@ -0,0 +1,19 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+description: Chart to launch Vault as SMS backend
+name: vault
+appVersion: 0.9.5
+version: 2.0.0
diff --git a/kubernetes/aaf/charts/sms/charts/vault/templates/configmap.yaml b/kubernetes/aaf/charts/sms/charts/vault/templates/configmap.yaml
new file mode 100644 (file)
index 0000000..daf8cad
--- /dev/null
@@ -0,0 +1,41 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: {{ include "common.fullname" . }}-vault
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+data:
+  config.json: |
+    {{ .Values.config.vault | toJson }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: {{ include "common.fullname" . }}-consul
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+data:
+  config.json: |
+    {{ .Values.config.consul | toJson }}
diff --git a/kubernetes/aaf/charts/sms/charts/vault/templates/pv.yaml b/kubernetes/aaf/charts/sms/charts/vault/templates/pv.yaml
new file mode 100644 (file)
index 0000000..37ed28e
--- /dev/null
@@ -0,0 +1,37 @@
+{{/*
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+*/}}
+
+{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}}
+kind: PersistentVolume
+apiVersion: v1
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}"
+    release: "{{ .Release.Name }}"
+    heritage: "{{ .Release.Service }}"
+    name: {{ include "common.fullname" . }}
+spec:
+  capacity:
+    storage: {{ .Values.persistence.size}}
+  accessModes:
+    - {{ .Values.persistence.accessMode }}
+  persistentVolumeReclaimPolicy: {{ .Values.persistence.volumeReclaimPolicy }}
+  hostPath:
+    path: {{ .Values.global.persistence.mountPath | default .Values.persistence.mountPath }}/{{ .Release.Name }}/{{ .Values.persistence.mountSubPath }}
+{{- end -}}
\ No newline at end of file
diff --git a/kubernetes/aaf/charts/sms/charts/vault/templates/pvc.yaml b/kubernetes/aaf/charts/sms/charts/vault/templates/pvc.yaml
new file mode 100644 (file)
index 0000000..e6aacd1
--- /dev/null
@@ -0,0 +1,48 @@
+{{/*
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+*/}}
+
+{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}}
+kind: PersistentVolumeClaim
+apiVersion: v1
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
+    release: "{{ .Release.Name }}"
+    heritage: "{{ .Release.Service }}"
+{{- if .Values.persistence.annotations }}
+  annotations:
+{{ toYaml .Values.persistence.annotations | indent 4 }}
+{{- end }}
+spec:
+  selector:
+    matchLabels:
+      name: {{ include "common.fullname" . }}
+  accessModes:
+    - {{ .Values.persistence.accessMode }}
+  resources:
+    requests:
+      storage: {{ .Values.persistence.size }}
+{{- if .Values.persistence.storageClass }}
+{{- if (eq "-" .Values.persistence.storageClass) }}
+  storageClassName: ""
+{{- else }}
+  storageClassName: "{{ .Values.persistence.storageClass }}"
+{{- end }}
+{{- end }}
+{{- end -}}
diff --git a/kubernetes/aaf/charts/sms/charts/vault/templates/service.yaml b/kubernetes/aaf/charts/sms/charts/vault/templates/service.yaml
new file mode 100644 (file)
index 0000000..cb2f286
--- /dev/null
@@ -0,0 +1,39 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.fullname" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - name: {{ .Values.service.name }}
+    {{if eq .Values.service.type "NodePort" -}}
+    port: {{ .Values.service.internalPort }}
+    nodePort: {{ .Values.global.nodePortPrefix | default "302" }}{{ .Values.service.nodePort }}
+    {{- else -}}
+    port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    {{- end}}
+    protocol: TCP
+  selector:
+    app: {{ include "common.name" . }}
+    release: {{ .Release.Name }}
diff --git a/kubernetes/aaf/charts/sms/charts/vault/templates/statefulset.yaml b/kubernetes/aaf/charts/sms/charts/vault/templates/statefulset.yaml
new file mode 100644 (file)
index 0000000..26f0304
--- /dev/null
@@ -0,0 +1,78 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: apps/v1beta1
+kind: StatefulSet
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+spec:
+  replicas: {{ .Values.replicaCount }}
+  serviceName:
+  template:
+    metadata:
+      labels:
+        app: {{ include "common.name" . }}
+        release: {{ .Release.Name }}
+    spec:
+      containers:
+      - image: "{{ include "common.repository" . }}/{{ .Values.image.vault }}"
+        name: {{ include "common.name" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        command: ["vault","server","-config","/vault/config/config.json"]
+        ports:
+        - containerPort: {{ .Values.service.internalPort }}
+        volumeMounts:
+        - mountPath: /vault/config/config.json
+          name: {{ include "common.fullname" . }}-vault
+          subPath: config.json
+        - mountPath: /etc/localtime
+          name: localtime
+          readOnly: true
+
+      - image: "{{ include "common.repository" . }}/{{ .Values.image.consul }}"
+        name: {{ include "common.name" . }}-backend
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        command: ["consul","agent","-server","-client","0.0.0.0","-bootstrap-expect=1","-config-file","/consul/config/config.json"]
+        ports:
+        - name: http
+          containerPort: 8500
+        volumeMounts:
+        - mountPath: /consul/data
+          name: {{ include "common.fullname" . }}-consuldata
+        - mountPath: /consul/config/config.json
+          name: {{ include "common.fullname" . }}-consulconfiguration
+          subPath: config.json
+        - mountPath: /etc/localtime
+          name: localtime
+          readOnly: true
+      volumes:
+        - name: {{ include "common.fullname" . }}-consuldata
+          persistentVolumeClaim:
+            claimName: {{ include "common.fullname" . }}
+        - name: {{ include "common.fullname" . }}-consulconfiguration
+          configMap:
+            name: {{ include "common.fullname" . }}-consul
+        - name: {{ include "common.fullname" . }}-vault
+          configMap:
+            name: {{ include "common.fullname" . }}-vault
+        - name: localtime
+          hostPath:
+            path: /etc/localtime
+
diff --git a/kubernetes/aaf/charts/sms/charts/vault/values.yaml b/kubernetes/aaf/charts/sms/charts/vault/values.yaml
new file mode 100644 (file)
index 0000000..c65e6e1
--- /dev/null
@@ -0,0 +1,112 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+  nodePortPrefix: 302
+  repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+  persistence: {}
+
+# application image
+repository: docker.io
+image:
+  consul: consul:1.0.6
+  vault: vault:0.9.6
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+config:
+  consul:
+    server: true
+    log_level: INFO
+    server: true
+    data_dir: '/consul/data'
+    ports:
+      http: 8500
+      https: -1
+
+  vault:
+    storage:
+      consul:
+        address: localhost:8500
+        path: smsvault
+    listener:
+      tcp:
+        address: '[::]:8200'
+        tls_disable: true
+    disable_mlock: true
+
+# default number of instances
+replicaCount: 1
+
+nodeSelector: {}
+
+affinity: {}
+
+# probe configuration parameters
+liveness:
+  initialDelaySeconds: 10
+  periodSeconds: 10
+  # necessary to disable liveness probe when setting breakpoints
+  # in debugger so K8s doesn't restart unresponsive container
+  enabled: true
+
+readiness:
+  initialDelaySeconds: 10
+  periodSeconds: 10
+
+persistence:
+  enabled: true
+
+  volumeReclaimPolicy: Retain
+
+  accessMode: ReadWriteMany
+  size: 2Gi
+  mountPath: /dockerdata-nfs
+  mountSubPath: sms/consul/data
+
+service:
+  type: NodePort
+  name: vault
+  internalPort: 8200
+  nodePort: 44
+
+ingress:
+  enabled: false
+
+resources: {}
+  # We usually recommend not to specify default resources and to leave this as a conscious
+  # choice for the user. This also increases chances charts run on environments with little
+  # resources, such as Minikube. If you do want to specify resources, uncomment the following
+  # lines, adjust them as necessary, and remove the curly braces after 'resources:'.
+  #
+  # Example:
+  # Configure resource requests and limits
+  # ref: http://kubernetes.io/docs/user-guide/compute-resources/
+  # Minimum memory for development is 2 CPU cores and 4GB memory
+  # Minimum memory for production is 4 CPU cores and 8GB memory
+#resources:
+#  limits:
+#    cpu: 2
+#    memory: 4Gi
+#  requests:
+#    cpu: 2
+#    memory: 4Gi
diff --git a/kubernetes/aaf/charts/sms/templates/configmap.yaml b/kubernetes/aaf/charts/sms/templates/configmap.yaml
new file mode 100644 (file)
index 0000000..72ce6fb
--- /dev/null
@@ -0,0 +1,27 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+data:
+  smsconfig.json: |
+    {{ .Values.config | toJson }}
diff --git a/kubernetes/aaf/charts/sms/templates/deployment.yaml b/kubernetes/aaf/charts/sms/templates/deployment.yaml
new file mode 100644 (file)
index 0000000..66c649c
--- /dev/null
@@ -0,0 +1,81 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+spec:
+  replicas: {{ .Values.replicaCount }}
+  template:
+    metadata:
+      labels:
+        app: {{ include "common.name" . }}
+        release: {{ .Release.Name }}
+    spec:
+      containers:
+      - image: "{{ .Values.repository }}/{{ .Values.image }}"
+        name: {{ include "common.name" . }}
+        imagePullPolicy: {{ .Values.pullPolicy }}
+        command: ["/sms/bin/sms"]
+        workingDir: /sms/
+        env:
+        - name: {{ .Values.config.smsdburlenv }}
+          value: "http://{{ include "common.namespace" . }}-smsdb:8200"
+        ports:
+        - containerPort: {{ .Values.service.internalPort }}
+        {{- if eq .Values.liveness.enabled true }}
+        livenessProbe:
+          tcpSocket:
+            port: {{ .Values.service.internalPort }}
+          initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
+          periodSeconds: {{ .Values.liveness.periodSeconds }}
+        {{ end -}}
+        readinessProbe:
+          tcpSocket:
+            port: {{ .Values.service.internalPort }}
+          initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
+          periodSeconds: {{ .Values.readiness.periodSeconds }}
+        volumeMounts:
+          - mountPath: /etc/localtime
+            name: localtime
+            readOnly: true
+          - mountPath: /sms/smsconfig.json
+            name: {{ include "common.name" .}}
+            subPath: smsconfig.json
+        resources:
+{{ toYaml .Values.resources | indent 12 }}
+        {{- if .Values.nodeSelector }}
+        nodeSelector:
+{{ toYaml .Values.nodeSelector | indent 10 }}
+        {{- end -}}
+        {{- if .Values.affinity }}
+        affinity:
+{{ toYaml .Values.affinity | indent 10 }}
+        {{- end }}
+      volumes:
+      - name: localtime
+        hostPath:
+          path: /etc/localtime
+      - name : {{ include "common.name" . }}
+        configMap:
+          name: {{ include "common.fullname" . }}
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
diff --git a/kubernetes/aaf/charts/sms/templates/service.yaml b/kubernetes/aaf/charts/sms/templates/service.yaml
new file mode 100644 (file)
index 0000000..cb2f286
--- /dev/null
@@ -0,0 +1,39 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.fullname" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+  - name: {{ .Values.service.name }}
+    {{if eq .Values.service.type "NodePort" -}}
+    port: {{ .Values.service.internalPort }}
+    nodePort: {{ .Values.global.nodePortPrefix | default "302" }}{{ .Values.service.nodePort }}
+    {{- else -}}
+    port: {{ .Values.service.externalPort }}
+    targetPort: {{ .Values.service.internalPort }}
+    {{- end}}
+    protocol: TCP
+  selector:
+    app: {{ include "common.name" . }}
+    release: {{ .Release.Name }}
diff --git a/kubernetes/aaf/charts/sms/values.yaml b/kubernetes/aaf/charts/sms/values.yaml
new file mode 100644 (file)
index 0000000..3db9b9a
--- /dev/null
@@ -0,0 +1,95 @@
+# Copyright 2018 Intel Corporation, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+  nodePortPrefix: 302
+  repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+  readinessRepository: oomk8s
+  readinessImage: readiness-check:1.1.1
+  loggingRepository: docker.elastic.co
+  loggingImage: beats/filebeat:5.5.0
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/aaf/sms
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# application configuration
+# Example:
+config:
+  smsdburlenv: "SMSDB_URL"
+  cafile: "/sms/auth/selfsignedca.pem"
+  servercert: "/sms/auth/server.cert"
+  serverkey: "/sms/auth/server.key"
+  disable_tls: true
+
+# subchart configuration
+vault:
+  nameOverride: smsdb
+
+# default number of instances
+replicaCount: 1
+
+nodeSelector: {}
+
+affinity: {}
+
+# probe configuration parameters
+liveness:
+  initialDelaySeconds: 10
+  periodSeconds: 20
+  # necessary to disable liveness probe when setting breakpoints
+  # in debugger so K8s doesn't restart unresponsive container
+  enabled: true
+
+readiness:
+  initialDelaySeconds: 10
+  periodSeconds: 20
+
+service:
+  type: NodePort
+  name: sms
+  internalPort: 10443
+  nodePort: 43
+
+ingress:
+  enabled: false
+
+resources: {}
+  # We usually recommend not to specify default resources and to leave this as a conscious
+  # choice for the user. This also increases chances charts run on environments with little
+  # resources, such as Minikube. If you do want to specify resources, uncomment the following
+  # lines, adjust them as necessary, and remove the curly braces after 'resources:'.
+  #
+  # Example:
+  # Configure resource requests and limits
+  # ref: http://kubernetes.io/docs/user-guide/compute-resources/
+  # Minimum memory for development is 2 CPU cores and 4GB memory
+  # Minimum memory for production is 4 CPU cores and 8GB memory
+#resources:
+#  limits:
+#    cpu: 2
+#    memory: 4Gi
+#  requests:
+#    cpu: 2
+#    memory: 4Gi
index 03506b5..2a4e7d2 100644 (file)
@@ -52,7 +52,7 @@ spec:
       - env:
         - name: CASSANDRA_CLUSTER
           value: cassandra_container
-        image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.image }}"
+        image: "{{ include "common.repository" . }}/{{ .Values.image }}"
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         volumeMounts:
         - mountPath: /data
index 4f9c1c6..ffdfaa5 100644 (file)
@@ -17,7 +17,6 @@
 #################################################################
 global:
   nodePortPrefix: 302
-  repository: nexus3.onap.org:10001
   repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
   readinessRepository: oomk8s
   readinessImage: readiness-check:1.1.0
index 8e01f42..da29908 100644 (file)
@@ -40,10 +40,21 @@ debugEnabled: false
 config:
   mysqlPassword: strong_pitchou
   dataRootDir: /dockerdata-nfs
-  springApplicationJson: '{
-  "spring.datasource.camunda.url": "jdbc:mariadb:sequential://clamp-mariadb.{{include "common.namespace" .}}:3306/camundabpm?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true&retriesAllDown=2147483647&failoverLoopRetries=2147483647",
-  "spring.datasource.cldsdb.url": "jdbc:mariadb:sequential://clamp-mariadb.{{include "common.namespace" .}}:3306/cldsdb4?verifyServerCertificate=false&useSSL=false&requireSSL=false&autoReconnect=true&retriesAllDown=2147483647&failoverLoopRetries=2147483647"
-  }'
+  springApplicationJson: >
+    {
+        "spring.datasource.cldsdb.url": "jdbc:mariadb:sequential://clamp-mariadb.{{include "common.namespace" .}}:3306/cldsdb4?autoReconnect=true&connectTimeout=10000&socketTimeout=10000&retriesAllDown=3",
+        "clamp.config.sdc.catalog.url": "https://sdc-be.{{include "common.namespace" .}}.svc.cluster.local:8443/sdc/v1/catalog/",
+        "clamp.config.sdc.hostUrl": "https://sdc-be.{{include "common.namespace" .}}.svc.cluster.local:8443/",
+        "clamp.config.sdc.serviceUrl": "https://sdc-be.{{include "common.namespace" .}}.svc.cluster.local:8443/sdc/v1/catalog/services",
+        "clamp.config.sdc.serviceUsername": "clamp",
+        "clamp.config.sdc.servicePassword": "b7acccda32b98c5bb7acccda32b98c5b05D511BD6D93626E90D18E9D24D9B78CD34C7EE8012F0A189A28763E82271E50A5D4EC10C7D93E06E0A2D27CAE66B981",
+        "clamp.config.dcae.inventory.url": "http://dcaegen2.{{include "common.namespace" .}}.svc.cluster.local:8080",
+        "clamp.config.dcae.dispatcher.url": "http://dcaegen2.{{include "common.namespace" .}}.svc.cluster.local:8080",
+        "clamp.config.policy.pdpUrl1": "https://policy-pdp.{{include "common.namespace" .}}.svc.cluster.local:9091/pdp/ , testpdp, alpha123",
+        "clamp.config.policy.pdpUrl2": "https://policy-pdp.{{include "common.namespace" .}}.svc.cluster.local:9091/pdp/ , testpdp, alpha123",
+        "clamp.config.policy.papUrl": "https://policy-pap.{{include "common.namespace" .}}.svc.cluster.local:8443/pap/ , testpap, alpha123",
+        "clamp.config.policy.clientKey": "5CE79532B3A2CB4D132FC0C04BF916A7"
+    }
 
 # subchart configuration
 mariadb:
diff --git a/kubernetes/sdc/charts/sdc-wfd/.helmignore b/kubernetes/sdc/charts/sdc-wfd/.helmignore
new file mode 100644 (file)
index 0000000..f0c1319
--- /dev/null
@@ -0,0 +1,21 @@
+# Patterns to ignore when building packages.
+# This supports shell glob matching, relative path matching, and
+# negation (prefixed with !). Only one pattern per line.
+.DS_Store
+# Common VCS dirs
+.git/
+.gitignore
+.bzr/
+.bzrignore
+.hg/
+.hgignore
+.svn/
+# Common backup files
+*.swp
+*.bak
+*.tmp
+*~
+# Various IDEs
+.project
+.idea/
+*.tmproj
diff --git a/kubernetes/sdc/charts/sdc-wfd/Chart.yaml b/kubernetes/sdc/charts/sdc-wfd/Chart.yaml
new file mode 100644 (file)
index 0000000..a04b2e5
--- /dev/null
@@ -0,0 +1,18 @@
+# Copyright © 2018 ZTE
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+description: Common Workflow Design
+name: sdc-wfd
+version: 2.0.0
\ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-wfd/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-wfd/templates/NOTES.txt
new file mode 100644 (file)
index 0000000..d83c152
--- /dev/null
@@ -0,0 +1,20 @@
+1. Get the application URL by running these commands:
+{{- if .Values.ingress.enabled }}
+{{- range .Values.ingress.hosts }}
+  http://{{ . }}
+{{- end }}
+{{- else if contains "NodePort" .Values.service.type }}
+  export NODE_PORT=$(kubectl get --namespace {{ include "common.namespace" . }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "common.fullname" . }})
+  export NODE_IP=$(kubectl get nodes --namespace {{ include "common.namespace" . }} -o jsonpath="{.items[0].status.addresses[0].address}")
+  echo http://$NODE_IP:$NODE_PORT
+{{- else if contains "LoadBalancer" .Values.service.type }}
+     NOTE: It may take a few minutes for the LoadBalancer IP to be available.
+           You can watch the status of by running 'kubectl get svc -w {{ include "common.fullname" . }}'
+  export SERVICE_IP=$(kubectl get svc --namespace {{ include "common.namespace" . }} {{ include "common.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
+  echo http://$SERVICE_IP:{{ .Values.service.externalPort }}
+{{- else if contains "ClusterIP" .Values.service.type }}
+  export POD_NAME=$(kubectl get pods --namespace {{ include "common.namespace" . }} -l "app={{ include "common.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
+  echo "Visit http://127.0.0.1:8080 to use your application"
+  kubectl port-forward $POD_NAME 8080:{{ .Values.service.internalPort }}
+{{- end }}
+
diff --git a/kubernetes/sdc/charts/sdc-wfd/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-wfd/templates/deployment.yaml
new file mode 100644 (file)
index 0000000..eb1f479
--- /dev/null
@@ -0,0 +1,54 @@
+# Copyright © 2018 ZTE
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+spec:
+  replicas: {{ .Values.replicaCount }}
+  template:
+    metadata:
+      labels:
+        app: {{ include "common.name" . }}
+        release: {{ .Release.Name }}
+    spec:
+      containers:
+        - name: {{ include "common.name" . }}
+          image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.image }}"
+          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+          ports:
+          - containerPort: {{ .Values.service.internalPort }}
+          # disable liveness probe when breakpoints set in debugger
+          # so K8s doesn't restart unresponsive container
+          {{- if eq .Values.liveness.enabled true }}
+          livenessProbe:
+            tcpSocket:
+              port: {{ .Values.service.internalPort }}
+            initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
+            periodSeconds: {{ .Values.liveness.periodSeconds }}
+          {{ end -}}
+          readinessProbe:
+            tcpSocket:
+              port: {{ .Values.service.internalPort }}
+            initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
+            periodSeconds: {{ .Values.readiness.periodSeconds }}
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
\ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-wfd/templates/service.yaml b/kubernetes/sdc/charts/sdc-wfd/templates/service.yaml
new file mode 100644 (file)
index 0000000..09c7e04
--- /dev/null
@@ -0,0 +1,54 @@
+# Copyright © 2018 ZTE
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ include "common.fullname" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+  annotations:
+    msb.onap.org/service-info: '[
+      {
+          "serviceName": "workflow-modeler",
+          "version": "v1",
+          "url": "/api/workflow-modeler/v1",
+          "protocol": "REST",
+          "port": "{{ .Values.service.internalPort }}",
+          "enable_ssl": true,
+          "visualRange":"1"
+      },
+      {
+          "serviceName": "workflow-modeler-ui",
+          "version": "v1",
+          "url": "/workflow-modeler",
+          "protocol": "UI",
+          "path": "/workflow-modeler",
+          "port": "{{ .Values.service.internalPort }}",
+          "visualRange":"1"
+      }
+      ]'
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+    - port: {{ .Values.service.internalPort }}
+      nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+      name: {{ .Values.service.name }}
+  selector:
+    app: {{ include "common.name" . }}
+    release: {{ .Release.Name }}
diff --git a/kubernetes/sdc/charts/sdc-wfd/values.yaml b/kubernetes/sdc/charts/sdc-wfd/values.yaml
new file mode 100644 (file)
index 0000000..507d7a3
--- /dev/null
@@ -0,0 +1,55 @@
+# Copyright © 2018 ZTE
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+  nodePortPrefix: 302
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/sdc/sdc-workflow-designer:1.1.0-STAGING-latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# default number of instances
+replicaCount: 1
+
+# probe configuration parameters
+liveness:
+  initialDelaySeconds: 10
+  periodSeconds: 10
+  # necessary to disable liveness probe when setting breakpoints
+  # in debugger so K8s doesn't restart unresponsive container
+  enabled: true
+
+readiness:
+  initialDelaySeconds: 10
+  periodSeconds: 10
+
+service:
+  type: NodePort
+  name: sdc-wfd
+  nodePort: "56"
+  internalPort: 8080
+
+ingress:
+  enabled: false
+