Merge "BugFix:correct context path in ND Ctx builder"
authorAlexis de Talhouët <alexis.de_talhouet@bell.ca>
Fri, 21 Sep 2018 14:05:35 +0000 (14:05 +0000)
committerGerrit Code Review <gerrit@onap.org>
Fri, 21 Sep 2018 14:05:35 +0000 (14:05 +0000)
55 files changed:
kubernetes/aai/charts/aai-babel/templates/deployment.yaml
kubernetes/aai/charts/aai-babel/values.yaml
kubernetes/aai/charts/aai-champ/templates/deployment.yaml
kubernetes/aai/charts/aai-champ/values.yaml
kubernetes/aai/charts/aai-data-router/templates/deployment.yaml
kubernetes/aai/charts/aai-data-router/values.yaml
kubernetes/aai/charts/aai-elasticsearch/templates/deployment.yaml
kubernetes/aai/charts/aai-elasticsearch/values.yaml
kubernetes/aai/charts/aai-gizmo/templates/deployment.yaml
kubernetes/aai/charts/aai-gizmo/values.yaml
kubernetes/aai/charts/aai-graphadmin/templates/deployment.yaml
kubernetes/aai/charts/aai-graphadmin/values.yaml
kubernetes/aai/charts/aai-modelloader/templates/deployment.yaml
kubernetes/aai/charts/aai-modelloader/values.yaml
kubernetes/aai/charts/aai-resources/templates/deployment.yaml
kubernetes/aai/charts/aai-resources/values.yaml
kubernetes/aai/charts/aai-search-data/templates/deployment.yaml
kubernetes/aai/charts/aai-search-data/values.yaml
kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml
kubernetes/aai/charts/aai-sparky-be/values.yaml
kubernetes/aai/charts/aai-spike/templates/deployment.yaml
kubernetes/aai/charts/aai-spike/values.yaml
kubernetes/aai/charts/aai-traversal/templates/deployment.yaml
kubernetes/aai/charts/aai-traversal/values.yaml
kubernetes/common/controller-blueprints/.helmignore [new file with mode: 0644]
kubernetes/common/controller-blueprints/Chart.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/requirements.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/resources/config/application.properties [new file with mode: 0644]
kubernetes/common/controller-blueprints/resources/config/logback.xml [new file with mode: 0644]
kubernetes/common/controller-blueprints/templates/configmap.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/templates/deployment.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/templates/secrets.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/templates/service.yaml [new file with mode: 0644]
kubernetes/common/controller-blueprints/values.yaml [new file with mode: 0644]
kubernetes/oof/charts/oof-has/charts/oof-has-api/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-api/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-cassandra/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-cassandra/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-controller/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-controller/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-data/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-data/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-music/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-music/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-reservation/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-reservation/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-solver/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-solver/values.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-zookeeper/templates/deployment.yaml
kubernetes/oof/charts/oof-has/charts/oof-has-zookeeper/values.yaml
kubernetes/oof/templates/deployment.yaml
kubernetes/oof/values.yaml
kubernetes/sdnc/requirements.yaml
kubernetes/sdnc/resources/config/conf/blueprints-processor-adaptor.properties [new file with mode: 0644]
kubernetes/sdnc/templates/statefulset.yaml

index 7778324..2f8f60f 100644 (file)
@@ -85,7 +85,7 @@ spec:
             name: {{ include "common.fullname" . }}-config
             subPath: logback.xml
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 7ba1c6b..01b4dfc 100644 (file)
@@ -27,6 +27,8 @@ global:
 # application image
 image: onap/babel:1.3-STAGING-latest
 
+flavor: small
+
 # application configuration
 config:
   keyStorePassword: OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
@@ -61,4 +63,18 @@ service:
 ingress:
   enabled: false
 
-resources: {}
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index d2f7bca..4987e4a 100644 (file)
@@ -86,7 +86,7 @@ spec:
           - mountPath: /var/log/onap
             name: {{ include "common.fullname" . }}-logs
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index a6435dd..75ecffb 100644 (file)
@@ -27,6 +27,8 @@ global:
 # application image
 image: onap/champ:1.3-STAGING-latest
 
+flavor: small
+
 # application configuration
 config:
   keyStorePassword: OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
@@ -60,7 +62,21 @@ service:
 ingress:
   enabled: false
 
-resources: {}
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
 
 # XML beans configuration
 event:
index 4b58c73..585cc4f 100644 (file)
@@ -110,6 +110,8 @@ spec:
             port: {{ .Values.service.internalPort }}
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
+        resources:
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       volumes:
       - name: localtime
         hostPath:
index 10521ab..06c64c3 100644 (file)
@@ -24,7 +24,7 @@ repository: nexus3.onap.org:10001
 image: onap/data-router:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 dockerhubRepository: registry.hub.docker.com
 ubuntuInitImage: oomk8s/ubuntu-init:2.0.0
 
@@ -82,7 +82,6 @@ persistence:
   mountPath: /dockerdata-nfs
   mountSubPath: aai/data-router/logs
 
-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
@@ -100,3 +99,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index acb0599..e1f3b39 100644 (file)
@@ -87,7 +87,7 @@ spec:
           - name: elasticsearch-data
             mountPath: /usr/share/elasticsearch/data
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index 0cb1a36..c6afbb5 100644 (file)
@@ -23,6 +23,8 @@ dockerhubRepository: docker.io
 image: elasticsearch:2.4.1
 pullPolicy: Always
 
+flavor: small
+
 # application configuration
 config:
   tcpPort: 8443
@@ -78,7 +80,6 @@ persistence:
   mountPath: /dockerdata-nfs
   mountSubPath: aai/elasticsearch/data
 
-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
@@ -96,3 +97,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index 0fb8552..d36ae2f 100644 (file)
@@ -89,7 +89,7 @@ spec:
             name: {{ include "common.fullname" . }}-logback-config
             subPath: logback.xml
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 50c9d77..d34ff2b 100644 (file)
@@ -24,7 +24,7 @@ global:
 
 # application image
 image: onap/gizmo:1.3-STAGING-latest
-
+flavor: small
 # application configuration
 config:
   keyStorePassword: OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
@@ -59,4 +59,18 @@ service:
 ingress:
   enabled: false
 
-resources: {}
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index 9b0ec63..69aeb32 100644 (file)
@@ -123,7 +123,7 @@ spec:
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index 6b7997f..3b7bd60 100644 (file)
@@ -31,7 +31,7 @@ repository: nexus3.onap.org:10001
 image: onap/aai-graphadmin:1.0-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 # default number of instances
 replicaCount: 1
 
@@ -107,7 +107,6 @@ service:
 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
@@ -125,3 +124,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index fe989b9..cee0818 100644 (file)
@@ -59,6 +59,8 @@ spec:
         ports:
         - containerPort: {{ .Values.service.internalPort }}
         - containerPort: {{ .Values.service.internalPort2 }}
+        resources:
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
 
       # side car containers
       - name: filebeat-onap
index 977860f..e406443 100644 (file)
@@ -24,7 +24,7 @@ repository: nexus3.onap.org:10001
 image: onap/model-loader:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 # application configuration
 config: {}
 
@@ -61,7 +61,6 @@ service:
 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
@@ -79,3 +78,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index 7df214f..065e130 100644 (file)
@@ -520,7 +520,7 @@ spec:
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index 943ace8..e9a0063 100644 (file)
@@ -25,7 +25,7 @@ repository: nexus3.onap.org:10001
 image: onap/aai-resources:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 # default number of instances
 replicaCount: 1
 
@@ -79,7 +79,6 @@ service:
 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
@@ -97,3 +96,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index dffc9cf..e486143 100644 (file)
@@ -93,7 +93,7 @@ spec:
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index 08bdbdb..bfde398 100644 (file)
@@ -26,7 +26,7 @@ repository: nexus3.onap.org:10001
 image: onap/search-data-service:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 # application configuration
 config:
   elasticsearchHttpPort: 9200
@@ -61,7 +61,6 @@ service:
 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
@@ -79,3 +78,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 1
+      memory: 2Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index 48235bc..a6414dd 100644 (file)
@@ -117,7 +117,7 @@ spec:
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index 50c624d..47b5a1d 100644 (file)
@@ -31,7 +31,7 @@ repository: nexus3.onap.org:10001
 image: onap/sparky-be:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 dockerhubRepository: registry.hub.docker.com
 ubuntuInitImage: oomk8s/ubuntu-init:2.0.0
 # application configuration
@@ -82,7 +82,6 @@ service:
 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
@@ -100,3 +99,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
index edf6ce8..a6801e1 100644 (file)
@@ -103,7 +103,7 @@ spec:
           - mountPath: /var/log/onap
             name: {{ include "common.fullname" . }}-logs
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 6429d3f..4fc3a0b 100644 (file)
@@ -25,7 +25,7 @@ global:
 
 # application image
 image: onap/spike:1.0-STAGING-latest
-
+flavor: small
 # application configuration
 config:
   keyStorePassword: OBF:1y0q1uvc1uum1uvg1pil1pjl1uuq1uvk1uuu1y10
@@ -60,7 +60,21 @@ service:
 ingress:
   enabled: false
 
-resources: {}
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
 
 # XML bean configuration
 event:
index 3cedaec..fb07427 100644 (file)
@@ -352,7 +352,7 @@ spec:
           initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
           periodSeconds: {{ .Values.readiness.periodSeconds }}
         resources:
-{{ toYaml .Values.resources | indent 10 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 8 }}
index a3410ad..83bd1a9 100644 (file)
@@ -26,7 +26,7 @@ repository: nexus3.onap.org:10001
 image: onap/aai-traversal:1.3-STAGING-latest
 pullPolicy: Always
 restartPolicy: Always
-
+flavor: small
 # application configuration
 config:
 
@@ -75,7 +75,6 @@ service:
 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
@@ -93,3 +92,18 @@ resources: {}
 #  requests:
 #    cpu: 2
 #    memory: 4Gi
+resources:
+  small:
+    limits:
+      cpu: 2
+      memory: 4Gi
+    requests:
+      cpu: 2
+      memory: 4Gi
+  large:
+    limits:
+      cpu: 4
+      memory: 8Gi
+    requests:
+      cpu: 4
+      memory: 8Gi
diff --git a/kubernetes/common/controller-blueprints/.helmignore b/kubernetes/common/controller-blueprints/.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/common/controller-blueprints/Chart.yaml b/kubernetes/common/controller-blueprints/Chart.yaml
new file mode 100644 (file)
index 0000000..28c22a3
--- /dev/null
@@ -0,0 +1,18 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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: Controller Blueprints Micro Service
+name: controller-blueprints
+version: 3.0.0
\ No newline at end of file
diff --git a/kubernetes/common/controller-blueprints/requirements.yaml b/kubernetes/common/controller-blueprints/requirements.yaml
new file mode 100644 (file)
index 0000000..b9ecec7
--- /dev/null
@@ -0,0 +1,21 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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.
+
+dependencies:
+  - name: mariadb-galera
+    version: ~2.0.0
+    repository: file://../mariadb-galera/
+  - name: common
+    version: ~2.0.0
+    repository: '@local'
\ No newline at end of file
diff --git a/kubernetes/common/controller-blueprints/resources/config/application.properties b/kubernetes/common/controller-blueprints/resources/config/application.properties
new file mode 100644 (file)
index 0000000..48678fc
--- /dev/null
@@ -0,0 +1,61 @@
+#
+# Copyright (c) 2017-2018 AT&T Intellectual Property.
+# Modifications Copyright (c) 2018 IBM.
+#
+# 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.
+#
+appName=ControllerBluePrints
+ms_name=org.onap.ccsdk.apps.controllerblueprints
+appVersion=1.0.0
+
+# Basic Authentication
+basic-auth.user-name=ccsdkapps
+basic-auth.hashed-pwd=$2a$10$MJxhNiOAffxbyrV9.rrOUewP9Q/ASg5Nit2cmP.yBaXGsVXo8BW3y
+
+logging.level.org.springframework.web=INFO
+logging.level.org.hibernate.SQL=warn
+logging.level.org.hibernate.type.descriptor.sql=debug
+
+#To Remove Null in JSON API Response
+spring.jackson.default-property-inclusion=non_null
+
+#Swagger Configuration
+swagger.contact.name=CCSDK team
+swagger.contact.url=www.onap.org
+swagger.contact.email=onap-discuss@lists.onap.org
+
+spring.jpa.properties.hibernate.show_sql=true
+spring.jpa.properties.hibernate.use_sql_comments=true
+spring.jpa.properties.hibernate.format_sql=true
+
+# spring.datasource.url, spring.datasource.username,spring.datasource.password  may be overridden by ENV variables
+spring.datasource.url=jdbc:mysql://controller-blueprints-db:3306/sdnctl
+spring.datasource.username=sdnctl
+spring.datasource.password=sdnctl
+spring.datasource.driver-class-name=org.mariadb.jdbc.Driver
+spring.jpa.show-sql = true
+spring.jpa.hibernate.ddl-auto = none
+spring.jpa.hibernate.naming-strategy = org.hibernate.cfg.ImprovedNamingStrategy
+spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5Dialect
+
+#Load Blueprints
+# blueprints.load.initial-data may be overridden by ENV variables
+blueprints.load.initial-data=true
+load.dataTypePath=load/model_type/data_type
+load.nodeTypePath=load/model_type/node_type
+load.artifactTypePath=load/model_type/artifact_type
+load.resourceDictionaryPath=load/resource_dictionary
+load.blueprintsPath=load/blueprints
+
+# Load Resource Source Mappings
+resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest
diff --git a/kubernetes/common/controller-blueprints/resources/config/logback.xml b/kubernetes/common/controller-blueprints/resources/config/logback.xml
new file mode 100644 (file)
index 0000000..b73db71
--- /dev/null
@@ -0,0 +1,44 @@
+<!--
+  ~ Copyright (c) 2017-2018 AT&T Intellectual Property.
+  ~
+  ~ 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.
+  -->
+
+<configuration>
+
+    <property name="localPattern" value="%d{HH:mm:ss.SSS} %-5level %logger{100} - %msg%n" />
+
+    <property name="defaultPattern" value="%date{ISO8601,UTC}|%X{RequestID}|%X{ServiceInstanceId}|%thread|%X{VirtualServerName}|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}|%X{Timer}| %msg%n" />
+
+    <property name="debugLoggerPattern" value="%date{ISO8601,UTC}|%X{RequestID}|%X{ServiceInstanceId}|%thread|%X{VirtualServerName}|%X{ServiceName}|%X{InstanceUUID}|%.-5level|%X{AlertSeverity}|%X{ServerIPAddress}|%X{ServerFQDN}|%X{RemoteHost}|%X{ClassName}|%X{Timer}|[%caller{3}]| %msg%n" />
+
+    <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
+        <!-- encoders are assigned the type
+             ch.qos.logback.classic.encoder.PatternLayoutEncoder by default -->
+        <encoder>
+            <pattern>${defaultPattern}</pattern>
+        </encoder>
+    </appender>
+
+
+    <logger name="org.springframework" level="info"/>
+    <logger name="org.springframework.web" level="info"/>
+    <logger name="org.springframework.security.web.authentication" level="warn"/>
+    <logger name="org.hibernate" level="error"/>
+    <logger name="org.onap.ccsdk.apps" level="info"/>
+
+    <root level="warn">
+        <appender-ref ref="STDOUT"/>
+    </root>
+
+</configuration>
diff --git a/kubernetes/common/controller-blueprints/templates/configmap.yaml b/kubernetes/common/controller-blueprints/templates/configmap.yaml
new file mode 100644 (file)
index 0000000..1f194b6
--- /dev/null
@@ -0,0 +1,22 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+# Modifications Copyright © 2018 AT&T, 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: ConfigMap
+metadata:
+  name: {{ include "common.fullname" . }}-configmap
+  namespace: {{ include "common.namespace" . }}
+data:
+{{ tpl (.Files.Glob "resources/config/*").AsConfig . | indent 2 }}
diff --git a/kubernetes/common/controller-blueprints/templates/deployment.yaml b/kubernetes/common/controller-blueprints/templates/deployment.yaml
new file mode 100644 (file)
index 0000000..18fb165
--- /dev/null
@@ -0,0 +1,134 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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:
+      initContainers:
+      - command:
+        - /root/ready.py
+        args:
+        - --container-name
+        - {{ index .Values "mariadb-galera" "nameOverride" }}
+        env:
+        - name: NAMESPACE
+          valueFrom:
+            fieldRef:
+              apiVersion: v1
+              fieldPath: metadata.namespace
+        image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-readiness
+      containers:
+        - name: {{ include "common.name" . }}
+          image: "{{ include "common.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 .Values.liveness.enabled }}
+          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 }}
+          env:
+            - name: APPLICATIONNAME
+              value: {{ .Values.config.applicationName }}
+            - name: BUNDLEVERSION
+              value: {{ .Values.config.bundleVersion }}
+            - name: APP_CONFIG_HOME
+              value: {{ .Values.config.appConfigDir }}
+            - name: DB_URL
+              value: {{ .Values.config.dbUrl }}
+            - name: DB_USER
+              value: {{ index .Values "mariadb-galera" "config" "userName" }}
+            - name: DB_PASSWORD
+              valueFrom:
+                secretKeyRef:
+                  name: {{ template "common.fullname" . }}
+                  key: db-root-password
+            - name: MS_USER
+              valueFrom:
+                secretKeyRef:
+                  name: {{ template "common.fullname" . }}
+                  key: restUser
+            - name: MS_PASSWORD
+              valueFrom:
+                secretKeyRef:
+                  name: {{ template "common.fullname" . }}
+                  key: restPassword
+            - name: INIT_DATA_LOAD
+              value: {{ .Values.config.initDataLoad | quote }}
+            - name: STICKYSELECTORKEY
+              value: {{ .Values.config.stickySelectorKey | quote }}
+            - name: ENVCONTEXT
+              value: {{ .Values.config.envContext }}
+          volumeMounts:
+          - mountPath: /etc/localtime
+            name: localtime
+            readOnly: true
+          - mountPath: {{ .Values.config.appConfigDir }}/application.properties
+            name: {{ include "common.fullname" . }}-config
+            subPath: application.properties
+          - mountPath: {{ .Values.config.appConfigDir }}/logback.xml
+            name: {{ include "common.fullname" . }}-config
+            subPath: logback.xml
+          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.fullname" . }}-config
+          configMap:
+            name: {{ include "common.fullname" . }}-configmap
+            items:
+            - key: application.properties
+              path: application.properties
+            - key: logback.xml
+              path: logback.xml
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
diff --git a/kubernetes/common/controller-blueprints/templates/secrets.yaml b/kubernetes/common/controller-blueprints/templates/secrets.yaml
new file mode 100644 (file)
index 0000000..b4ab161
--- /dev/null
@@ -0,0 +1,29 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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: Secret
+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 }}
+type: Opaque
+data:
+  db-root-password: {{ index .Values "mariadb-galera" "config" "mariadbRootPassword" | b64enc | quote }}
+  restUser: {{ .Values.config.restUser | b64enc | quote }}
+  restPassword: {{ .Values.config.restPassword | b64enc | quote }}
diff --git a/kubernetes/common/controller-blueprints/templates/service.yaml b/kubernetes/common/controller-blueprints/templates/service.yaml
new file mode 100644 (file)
index 0000000..438ca19
--- /dev/null
@@ -0,0 +1,52 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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.servicename" . }}
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ .Release.Name }}
+    heritage: {{ .Release.Service }}
+  annotations:
+# Example MSB registration annotation
+#    msb.onap.org/service-info: '[
+#      {
+#          "serviceName": "controller-blueprints",
+#          "version": "v1",
+#          "url": "/ecomp/mso/infra",
+#          "protocol": "REST"
+#          "port": "8080",
+#          "visualRange":"1"
+#      }
+#      ]'
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+    {{if eq .Values.service.type "NodePort" -}}
+    - port: {{ .Values.service.externalPort }}
+      targetPort: {{ .Values.service.internalPort }}
+      nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+      name: {{ .Values.service.portName | default "http" }}
+    {{- else -}}
+    - port: {{ .Values.service.externalPort }}
+      targetPort: {{ .Values.service.internalPort }}
+      name: {{ .Values.service.portName | default "http" }}
+    {{- end}}
+  selector:
+    app: {{ include "common.name" . }}
+    release: {{ .Release.Name }}
\ No newline at end of file
diff --git a/kubernetes/common/controller-blueprints/values.yaml b/kubernetes/common/controller-blueprints/values.yaml
new file mode 100644 (file)
index 0000000..f8b8aba
--- /dev/null
@@ -0,0 +1,122 @@
+# Copyright (c) 2018 Amdocs, Bell Canada
+#
+# 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:
+  # Change to an unused port prefix range to prevent port conflicts
+  # with other instances running within the same k8s cluster
+  nodePortPrefix: 302
+
+  # image repositories
+  repository: nexus3.onap.org:10001
+
+  # readiness check
+  readinessRepository: oomk8s
+  readinessImage: readiness-check:2.0.0
+
+  # image pull policy
+  pullPolicy: Always
+
+  persistence:
+    mountPath: /dockerdata-nfs
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/ccsdk-controllerblueprints:latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# application configuration
+config:
+  applicationName: ControllerBluePrints
+  bundleVersion: 1.0.0
+  appConfigDir: /opt/app/onap/config
+  dbUrl: jdbc:mysql://controller-blueprints-db:3306/sdnctl
+  initDataLoad: true
+  stickySelectorKey:
+  envContext: DEV
+  restUser: ccsdkapps
+  restPassword: ccsdkapps
+
+mariadb-galera:
+  config:
+      userName: sdnctl
+      userPassword: sdnctl
+      mariadbRootPassword: sdnctl
+      mysqlDatabase: sdnctl
+  nameOverride: controller-blueprints-db
+  service:
+    name: controller-blueprints-db
+    portName: cb-db
+  replicaCount: 1
+  persistence:
+    enabled: true
+    mountSubPath: controller-blueprints/data
+
+# 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
+
+service:
+  type: ClusterIP
+  portName: controller-blueprints
+  internalPort: 8080
+  externalPort: 8080
+
+persistence:
+  enabled: true
+
+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 95b6783..690bb74 100755 (executable)
@@ -85,7 +85,7 @@ spec:
             name: {{ .Values.global.commonConfigPrefix  }}-config
             subPath: log.conf
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 6114de3..ea83587 100755 (executable)
@@ -24,6 +24,24 @@ ingress:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -34,4 +52,3 @@ liveness:
 readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
-resources: {}
index 2d52b09..f16b09f 100644 (file)
@@ -78,7 +78,7 @@ spec:
         - name: {{ include "common.fullname" . }}-data
           mountPath: /var/lib/cassandra/data
         resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
       {{- if .Values.nodeSelector }}
       nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 400387c..1268bad 100644 (file)
@@ -38,6 +38,24 @@ nodeSelector: {}
 
 affinity: {}
 
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 16Gi
+      cpu: 8000m
+    requests:
+      memory: 8Gi
+      cpu: 4000m
+  large:
+    limits:
+      memory: 32Gi
+      cpu: 16000m
+    requests:
+      memory: 16Gi
+      cpu: 8000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -89,5 +107,3 @@ service:
 
 ingress:
   enabled: false
-
-resources: {}
index 3274040..3a32129 100755 (executable)
@@ -88,7 +88,7 @@ spec:
             name: {{ .Values.global.commonConfigPrefix }}-config
             subPath: healthy.sh
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 57c56d5..659128d 100755 (executable)
@@ -17,6 +17,24 @@ ingress:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -27,4 +45,3 @@ liveness:
 readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
-resources: {}
index 4314227..d5f619e 100755 (executable)
@@ -97,7 +97,7 @@ spec:
             name: {{ .Values.global.commonConfigPrefix }}-config
             subPath: AAF_RootCA.cer
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 57c56d5..659128d 100755 (executable)
@@ -17,6 +17,24 @@ ingress:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -27,4 +45,3 @@ liveness:
 readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
-resources: {}
index 902914e..7883340 100644 (file)
@@ -46,6 +46,8 @@ spec:
         - name: {{ include "common.name" . }}
           image: "{{ include "common.repository" . }}/{{ .Values.image }}"   #"
           imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+          resources:
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
           ports:
           - containerPort: {{ .Values.service.internalPort }}
           # disable liveness probe when breakpoints set in debugger
index 1fcd5f6..dda1c0f 100644 (file)
@@ -48,6 +48,24 @@ nodeSelector: {}
 
 affinity: {}
 
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -69,5 +87,3 @@ service:
   portName: oof-has-music
 ingress:
   enabled: false
-
-resources: {}
index b5ef0c8..d90943c 100755 (executable)
@@ -88,7 +88,7 @@ spec:
             name: {{ .Values.global.commonConfigPrefix }}-config
             subPath: healthy.sh
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 57c56d5..659128d 100755 (executable)
@@ -17,6 +17,24 @@ ingress:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -27,4 +45,3 @@ liveness:
 readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
-resources: {}
index abd2f0a..ad1e1c5 100755 (executable)
@@ -88,7 +88,7 @@ spec:
             name: {{ .Values.global.commonConfigPrefix }}-config
             subPath: healthy.sh
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index 57c56d5..659128d 100755 (executable)
@@ -17,6 +17,24 @@ ingress:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -27,4 +45,3 @@ liveness:
 readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
-resources: {}
index 70df814..43f0680 100644 (file)
@@ -54,7 +54,7 @@ spec:
             name: localtime
             readOnly: true
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index b0eca78..e61eda0 100644 (file)
@@ -30,6 +30,24 @@ pullPolicy: Always
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -48,4 +66,3 @@ service:
   portName: oof-has-zookeeper
 ingress:
   enabled: false
-resources: {}
index da7cb70..3341505 100644 (file)
@@ -77,7 +77,7 @@ spec:
             name: {{ include "common.fullname" . }}-config
             subPath: osdf_config.yaml
           resources:
-{{ toYaml .Values.resources | indent 12 }}
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
         {{- if .Values.nodeSelector }}
         nodeSelector:
 {{ toYaml .Values.nodeSelector | indent 10 }}
index ac1bcc0..5aa462f 100644 (file)
@@ -75,6 +75,24 @@ config:
 replicaCount: 1
 nodeSelector: {}
 affinity: {}
+# Resource Limit flavor -By Default using small
+flavor: small
+# Segregation for Different environment (Small and Large)
+resources:
+  small:
+    limits:
+      memory: 4Gi
+      cpu: 2000m
+    requests:
+      memory: 1Gi
+      cpu: 500m
+  large:
+    limits:
+      memory: 8Gi
+      cpu: 4000m
+    requests:
+      memory: 2Gi
+      cpu: 1000m
 # probe configuration parameters
 liveness:
   initialDelaySeconds: 10
@@ -93,4 +111,3 @@ service:
   nodePort: 48
 ingress:
   enabled: false
-resources: {}
index 0934814..f2be094 100644 (file)
@@ -16,6 +16,9 @@ dependencies:
   - name: common
     version: ~2.0.0
     repository: '@local'
+  - name: controller-blueprints
+    version: ~3.0.0
+    repository: '@local'
   - name: mysql
     version: ~2.0.0
     repository: '@local'
diff --git a/kubernetes/sdnc/resources/config/conf/blueprints-processor-adaptor.properties b/kubernetes/sdnc/resources/config/conf/blueprints-processor-adaptor.properties
new file mode 100644 (file)
index 0000000..eb17d09
--- /dev/null
@@ -0,0 +1,35 @@
+###
+# Copyright � 2017-2018 AT&T Intellectual Property.
+# Modifications Copyright � 2018 IBM.
+#
+# 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.
+###
+#
+# Configuration file for SDNC Controller Module
+#
+
+org.onap.ccsdk.features.rest.adaptors.envtype=solo
+
+# Config Generator Microservices
+org.onap.ccsdk.features.rest.adaptors.modelservice.type=generic
+org.onap.ccsdk.features.rest.adaptors.modelservice.enable=true
+org.onap.ccsdk.features.rest.adaptors.modelservice.url=http://controller-blueprints:8080/api/v1/
+org.onap.ccsdk.features.rest.adaptors.modelservice.user=ccsdkapps
+org.onap.ccsdk.features.rest.adaptors.modelservice.passwd=ccsdkapps
+
+# Generic RESTCONF Adaptor
+org.onap.ccsdk.features.rest.adaptors.restconf.type=generic
+org.onap.ccsdk.features.rest.adaptors.restconf.enable=true
+org.onap.ccsdk.features.rest.adaptors.restconf.user=admin
+org.onap.ccsdk.features.rest.adaptors.restconf.passwd={{ .Values.config.odlPassword}}
+org.onap.ccsdk.features.rest.adaptors.restconf.url=http://sdnc:8282/restconf/
index 8c52e5c..784bc69 100644 (file)
@@ -123,6 +123,12 @@ spec:
           - mountPath: /opt/onap/sdnc/svclogic/config/svclogic.properties
             name: properties
             subPath: svclogic.properties
+          - mountPath: {{ .Values.config.configDir }}/netbox.properties
+            name: properties
+            subPath: netbox.properties
+          - mountPath: {{ .Values.config.configDir }}/blueprints-processor-adaptor.properties
+            name: properties
+            subPath: blueprints-processor-adaptor.properties
           - mountPath: {{ .Values.persistence.mdsalPath }}
             name: {{ include "common.fullname" . }}-mdsal
           - mountPath: /var/log/onap