Clamp cannot connect to SDC 17/47817/1
authorac2550 <ac2550@intl.att.com>
Wed, 16 May 2018 12:31:23 +0000 (14:31 +0200)
committerac2550 <ac2550@intl.att.com>
Wed, 16 May 2018 12:45:12 +0000 (14:45 +0200)
Change-Id: Ib55827b52a4b46001ed15518efdec36756f99dfa
Issue-ID: CLAMP-151
Signed-off-by: ac2550 <ac2550@intl.att.com>
kubernetes/clamp/resources/config/sdc-controllers-config.json [new file with mode: 0644]
kubernetes/clamp/templates/configmap.yaml
kubernetes/clamp/templates/deployment.yaml
kubernetes/clamp/values.yaml

diff --git a/kubernetes/clamp/resources/config/sdc-controllers-config.json b/kubernetes/clamp/resources/config/sdc-controllers-config.json
new file mode 100644 (file)
index 0000000..3adda95
--- /dev/null
@@ -0,0 +1,18 @@
+{
+  "sdc-connections":{
+    "sdc-controller":{
+        "user": "clamp",
+        "consumerGroup": "clamp",
+        "consumerId": "clamp",
+        "environmentName": "AUTO",
+        "sdcAddress": "sdc-be.{{ include "common.namespace" . }}:8443",
+        "password": "b7acccda32b98c5bb7acccda32b98c5b05D511BD6D93626E90D18E9D24D9B78CD34C7EE8012F0A189A28763E82271E50A5D4EC10C7D93E06E0A2D27CAE66B981",
+        "pollingInterval":30,
+        "pollingTimeout":30,
+        "activateServerTLSAuth":"false",
+        "keyStorePassword":"",
+        "keyStorePath":"",
+        "messageBusAddresses":["message-router.{{ include "common.namespace" . }}"]
+    }
+  }
+}
index bee8f13..7a66c64 100644 (file)
@@ -23,4 +23,5 @@ metadata:
     release: {{ .Release.Name }}
     heritage: {{ .Release.Service }}
 data:
- spring_application_json: {{ tpl .Values.config.springApplicationJson . | quote }}
+{{ tpl (.Files.Glob "resources/config/*").AsConfig . | indent 2 }}
+  spring_application_json: {{ tpl .Values.config.springApplicationJson . | quote }}
index 4a3a0f9..38eabeb 100644 (file)
@@ -65,6 +65,10 @@ spec:
               port: {{ .Values.service.internalPort }}
             initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
             periodSeconds: {{ .Values.readiness.periodSeconds }}
+          volumeMounts:
+          - mountPath: /opt/clamp/sdc-controllers-config.json
+            name: {{ include "common.fullname" . }}-config
+            subPath: sdc-controllers-config.json
           env:
             - name: SPRING_APPLICATION_JSON
               valueFrom:
@@ -81,5 +85,12 @@ spec:
         affinity:
 {{ toYaml .Values.affinity | indent 10 }}
         {{- end }}
+      volumes:
+        - name: {{ include "common.fullname" . }}-config
+          configMap:
+            name: {{ include "common.fullname" . }}
+            items:
+            - key: sdc-controllers-config.json
+              path: sdc-controllers-config.json
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 06fe3d9..71752fc 100644 (file)
@@ -41,17 +41,18 @@ config:
   dataRootDir: /dockerdata-nfs
   springApplicationJson: >
     {
-        "spring.datasource.cldsdb.url": "jdbc:mariadb:sequential://clampdb:3306/cldsdb4?autoReconnect=true&connectTimeout=10000&socketTimeout=10000&retriesAllDown=3",
-        "clamp.config.sdc.catalog.url": "https://sdc-be:8443/sdc/v1/catalog/",
-        "clamp.config.sdc.hostUrl": "https://sdc-be:8443/",
-        "clamp.config.sdc.serviceUrl": "https://sdc-be:8443/sdc/v1/catalog/services",
+        "spring.datasource.cldsdb.url": "jdbc:mariadb:sequential://clampdb.{{ include "common.namespace" . }}:3306/cldsdb4?autoReconnect=true&connectTimeout=10000&socketTimeout=10000&retriesAllDown=3",
+        "clamp.config.sdc.catalog.url": "http://sdc-be.{{ include "common.namespace" . }}:8080/sdc/v1/catalog/",
+        "clamp.config.sdc.hostUrl": "http://sdc-be.{{ include "common.namespace" . }}:8080/",
+        "clamp.config.sdc.serviceUrl": "http://sdc-be.{{ include "common.namespace" . }}:8080/sdc/v1/catalog/services",
         "clamp.config.sdc.serviceUsername": "clamp",
         "clamp.config.sdc.servicePassword": "b7acccda32b98c5bb7acccda32b98c5b05D511BD6D93626E90D18E9D24D9B78CD34C7EE8012F0A189A28763E82271E50A5D4EC10C7D93E06E0A2D27CAE66B981",
-        "clamp.config.dcae.inventory.url": "http://dcaegen2:8080",
-        "clamp.config.dcae.dispatcher.url": "http://dcaegen2:8080",
-        "clamp.config.policy.pdpUrl1": "https://policy-pdp:9091/pdp/ , testpdp, alpha123",
-        "clamp.config.policy.pdpUrl2": "https://policy-pdp:9091/pdp/ , testpdp, alpha123",
-        "clamp.config.policy.papUrl": "https://policy-pap:8443/pap/ , testpap, alpha123",
+        "clamp.config.files.sdcController": "file:/opt/clamp/sdc-controllers-config.json",
+        "clamp.config.dcae.inventory.url": "http://dcaegen2.{{ include "common.namespace" . }}:8080",
+        "clamp.config.dcae.dispatcher.url": "http://dcaegen2.{{ include "common.namespace" . }}:8080",
+        "clamp.config.policy.pdpUrl1": "https://pdp.{{ include "common.namespace" . }}:9091/pdp/ , testpdp, alpha123",
+        "clamp.config.policy.pdpUrl2": "https://pdp.{{ include "common.namespace" . }}:9091/pdp/ , testpdp, alpha123",
+        "clamp.config.policy.papUrl": "https://pap.{{ include "common.namespace" . }}:8443/pap/ , testpap, alpha123",
         "clamp.config.policy.clientKey": "5CE79532B3A2CB4D132FC0C04BF916A7"
     }