summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--docs/MSB-OOM-MSC.pngbin108096 -> 0 bytes
-rw-r--r--docs/oom_developer_guide.rst617
-rw-r--r--kubernetes/onap/requirements.yaml2
-rw-r--r--kubernetes/sdc/.helmignore21
-rw-r--r--kubernetes/sdc/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-be/.helmignore21
-rw-r--r--kubernetes/sdc/charts/sdc-be/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-be/resources/config/logging/logback.xml (renamed from kubernetes/sdc/resources/config/log/be/logback.xml)0
-rw-r--r--kubernetes/sdc/charts/sdc-be/templates/NOTES.txt19
-rw-r--r--kubernetes/sdc/charts/sdc-be/templates/configmap.yaml (renamed from kubernetes/sdc/templates/sdc-fe-configmap.yaml)8
-rw-r--r--kubernetes/sdc/charts/sdc-be/templates/deployment.yaml136
-rw-r--r--kubernetes/sdc/charts/sdc-be/templates/job.yaml51
-rw-r--r--kubernetes/sdc/charts/sdc-be/templates/service.yaml51
-rw-r--r--kubernetes/sdc/charts/sdc-be/values.yaml71
-rw-r--r--kubernetes/sdc/charts/sdc-cs/.helmignore21
-rw-r--r--kubernetes/sdc/charts/sdc-cs/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/NOTES.txt19
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/deployment.yaml88
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/job.yaml60
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/pv.yaml21
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/pvc.yaml32
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/secrets.yaml31
-rw-r--r--kubernetes/sdc/charts/sdc-cs/templates/service.yaml31
-rw-r--r--kubernetes/sdc/charts/sdc-cs/values.yaml101
-rw-r--r--kubernetes/sdc/charts/sdc-es/.helmignore21
-rw-r--r--kubernetes/sdc/charts/sdc-es/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/NOTES.txt19
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/deployment.yaml102
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/job.yaml51
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/pv.yaml21
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/pvc.yaml32
-rw-r--r--kubernetes/sdc/charts/sdc-es/templates/service.yaml31
-rw-r--r--kubernetes/sdc/charts/sdc-es/values.yaml101
-rw-r--r--kubernetes/sdc/charts/sdc-fe/.helmignore21
-rw-r--r--kubernetes/sdc/charts/sdc-fe/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-fe/resources/config/logging/logback.xml (renamed from kubernetes/sdc/resources/config/log/fe/logback.xml)4
-rw-r--r--kubernetes/sdc/charts/sdc-fe/templates/NOTES.txt19
-rw-r--r--kubernetes/sdc/charts/sdc-fe/templates/configmap.yaml (renamed from kubernetes/sdc/templates/sdc-environments-configmap.yaml)8
-rw-r--r--kubernetes/sdc/charts/sdc-fe/templates/deployment.yaml120
-rw-r--r--kubernetes/sdc/charts/sdc-fe/templates/service.yaml42
-rw-r--r--kubernetes/sdc/charts/sdc-fe/values.yaml75
-rw-r--r--kubernetes/sdc/charts/sdc-kb/.helmignore25
-rw-r--r--kubernetes/sdc/charts/sdc-kb/Chart.yaml4
-rw-r--r--kubernetes/sdc/charts/sdc-kb/templates/NOTES.txt19
-rw-r--r--kubernetes/sdc/charts/sdc-kb/templates/deployment.yaml86
-rw-r--r--kubernetes/sdc/charts/sdc-kb/templates/service.yaml25
-rw-r--r--kubernetes/sdc/charts/sdc-kb/values.yaml73
-rw-r--r--kubernetes/sdc/requirements.yaml4
-rwxr-xr-xkubernetes/sdc/resources/config/environments/AUTO.json68
-rwxr-xr-xkubernetes/sdc/resources/config/environments/Template.json75
-rwxr-xr-xkubernetes/sdc/resources/config/sdc-fe/FE_2_setup_configuration.rb27
-rw-r--r--kubernetes/sdc/templates/all-services.yaml141
-rw-r--r--kubernetes/sdc/templates/configmap.yaml15
-rw-r--r--kubernetes/sdc/templates/sdc-be.yaml137
-rw-r--r--kubernetes/sdc/templates/sdc-cs.yaml95
-rw-r--r--kubernetes/sdc/templates/sdc-es.yaml91
-rw-r--r--kubernetes/sdc/templates/sdc-fe.yaml135
-rw-r--r--kubernetes/sdc/templates/sdc-kb.yaml87
-rw-r--r--kubernetes/sdc/templates/sdc-log-configmap.yaml41
-rw-r--r--kubernetes/sdc/templates/sdc-pv-pvc.yaml48
-rw-r--r--kubernetes/sdc/values.yaml29
61 files changed, 2232 insertions, 1081 deletions
diff --git a/docs/MSB-OOM-MSC.png b/docs/MSB-OOM-MSC.png
deleted file mode 100644
index 7c1e076ada..0000000000
--- a/docs/MSB-OOM-MSC.png
+++ /dev/null
Binary files differ
diff --git a/docs/oom_developer_guide.rst b/docs/oom_developer_guide.rst
index 1c18044b70..c9aa6290d7 100644
--- a/docs/oom_developer_guide.rst
+++ b/docs/oom_developer_guide.rst
@@ -4,6 +4,7 @@
.. Links
.. _Helm: https://docs.helm.sh/
+.. _Helm Charts: https://github.com/kubernetes/charts
.. _Kubernetes: https://Kubernetes.io/
.. _Docker: https://www.docker.com/
.. _Nexus: https://nexus.onap.org/#welcome
@@ -14,6 +15,7 @@
.. _Kubernetes Storage Class: https://Kubernetes.io/docs/concepts/storage/storage-classes/
.. _Assigning Pods to Nodes: https://Kubernetes.io/docs/concepts/configuration/assign-pod-node/
+
.. _developer-guide-label:
OOM Developer Guide
@@ -64,16 +66,336 @@ ONAP on a single laptop computer.
Helm Charts
===========
+A Helm chart is a collection of files that describe a related set of Kubernetes
+resources. A simple chart might be used to deploy something simple, like a
+memcached pod, while a complex chart might contain many micro-service arranged
+in a hierarchy as found in the `aai` ONAP component.
-Standard Chart Format
----------------------
+Charts are created as files laid out in a particular directory tree, then they
+can be packaged into versioned archives to be deployed. There is a public
+archive of `Helm Charts`_ on GitHub that includes many technologies applicable
+to ONAP. Some of these charts have been used in ONAP and all of the ONAP charts
+have been created following the guidelines provided.
-Helm charts are available in the open-source community for a wide variety of
-common software components which are used in ONAP and where possible.
+The top level of the ONAP charts is shown below:
+.. graphviz::
-Chart Hierarchy
----------------
+ digraph onap_top_chart {
+ rankdir="LR";
+ {
+ node [shape=folder]
+ oValues [label="values.yaml"]
+ oChart [label="Chart.yaml"]
+ dev [label="dev.yaml"]
+ prod [label="prod.yaml"]
+ crb [label="clusterrolebindings.yaml"]
+ secrets [label="secrets.yaml"]
+ }
+ {
+ node [style=dashed]
+ vCom [label="component"]
+ }
+
+ onap -> oValues
+ onap -> oChart
+ onap -> templates
+ onap -> resources
+ oValues -> vCom
+ resources -> environments
+ environments -> dev
+ environments -> prod
+ templates -> crb
+ templates -> secrets
+ }
+
+Within the `values.yaml` file at the `onap` level, one will find a set of
+boolean values that control which of the ONAP components get deployed as shown
+below:
+
+.. code-block:: yaml
+
+ aaf: # Application Authorization Framework
+ enabled: false
+ <...>
+ so: # Service Orchestrator
+ enabled: true
+
+By setting these flags a custom deployment can be created and used during
+deployment by using the `-f` Helm option as follows::
+
+ > helm install local/onap -name development -f dev.yaml
+
+Note that there are one or more example deployment files in the
+`onap/resources/environments/` directory. It is best practice to create a unique
+deployment file for each environment used to ensure consistent behaviour.
+
+To aid in the long term supportability of ONAP, a set of common charts have
+been created (and will be expanded in subsequent releases of ONAP) that can be
+used by any of the ONAP components by including the common component in its
+`requirements.yaml` file. The common components are arranged as follows:
+
+.. graphviz::
+
+ digraph onap_common_chart {
+ rankdir="LR";
+ {
+ node [shape=folder]
+ mValues [label="values.yaml"]
+ ccValues [label="values.yaml"]
+ comValues [label="values.yaml"]
+ comChart [label="Chart.yaml"]
+ ccChart [label="Chart.yaml"]
+ mChart [label="Chart.yaml"]
+
+ mReq [label="requirements.yaml"]
+ mService [label="service.yaml"]
+ mMap [label="configmap.yaml"]
+ ccName [label="_name.tpl"]
+ ccNS [label="_namespace.tpl"]
+ }
+ {
+ cCom [label="common"]
+ mTemp [label="templates"]
+ ccTemp [label="templates"]
+ }
+ {
+ more [label="...",style=dashed]
+ }
+
+ common -> comValues
+ common -> comChart
+ common -> cCom
+ common -> mysql
+ common -> more
+
+ cCom -> ccChart
+ cCom -> ccValues
+ cCom -> ccTemp
+ ccTemp -> ccName
+ ccTemp -> ccNS
+
+ mysql -> mValues
+ mysql -> mChart
+ mysql -> mReq
+ mysql -> mTemp
+ mTemp -> mService
+ mTemp -> mMap
+ }
+
+The common section of charts consists of a set of templates that assist with
+parameter substitution (`_name.tpl` and `_namespace.tpl`) and a set of charts
+for components used throughout ONAP. Initially `mysql` is in the common area but
+this will expand to include other databases like `mariadb-galera`, `postgres`,
+and `cassandra`. Other candidates for common components include `redis` and
+`kafka`. When the common components are used by other charts they are
+instantiated each time. In subsequent ONAP releases some of the common
+components could be a setup as services that are used by multiple ONAP
+components thus minimizing the deployment and operational costs.
+
+All of the ONAP components have charts that follow the pattern shown below:
+
+.. graphviz::
+
+ digraph onap_component_chart {
+ rankdir="LR";
+ {
+ node [shape=folder]
+ cValues [label="values.yaml"]
+ cChart [label="Chart.yaml"]
+ cService [label="service.yaml"]
+ cMap [label="configmap.yaml"]
+ cFiles [label="config file(s)"]
+ }
+ {
+ cCharts [label="charts"]
+ cTemp [label="templates"]
+ cRes [label="resources"]
+
+ }
+ {
+ sCom [label="component",style=dashed]
+ }
+
+ component -> cValues
+ component -> cChart
+ component -> cCharts
+ component -> cTemp
+ component -> cRes
+ cTemp -> cService
+ cTemp -> cMap
+ cRes -> config
+ config -> cFiles
+ cCharts -> sCom
+ }
+
+Note that the component charts may include a hierarchy of components and in
+themselves can be quite complex.
+
+Configuration of the components varies somewhat from component to component but
+generally follows the pattern of one or more `configmap.yaml` files which can
+directly provide configuration to the containers in addition to processing
+configuration files stored in the `config` directory. It is the responsibility
+of each ONAP component team to update these configuration files when changes
+are made to the project containers that impact configuration.
+
+The following section describes how the hierarchical ONAP configuration system is
+key to management of such a large system.
+
+Configuration Management
+========================
+
+ONAP is a large system composed of many components - each of which are complex
+systems in themselves - that needs to be deployed in a number of different
+ways. For example, within a single operator's network there may be R&D
+deployments under active development, pre-production versions undergoing system
+testing and production systems that are operating live networks. Each of these
+deployments will differ in significant ways, such as the version of the
+software images deployed. In addition, there may be a number of application
+specific configuration differences, such as operating system environment
+variables. The following describes how the Helm configuration management
+system is used within the OOM project to manage both ONAP infrastructure
+configuration as well as ONAP components configuration.
+
+One of the artifacts that OOM/Kubernetes uses to deploy ONAP components is the
+deployment specification, yet another yaml file. Within these deployment specs
+are a number of parameters as shown in the following mariadb example:
+
+.. code-block:: yaml
+
+ apiVersion: extensions/v1beta1
+ kind: Deployment
+ metadata:
+ name: mariadb
+ spec:
+ <...>
+ template:
+ <...>
+ spec:
+ hostname: mariadb
+ containers:
+ - args:
+ image: nexus3.onap.org:10001/mariadb:10.1.11
+ name: "mariadb"
+ env:
+ - name: MYSQL_ROOT_PASSWORD
+ value: password
+ - name: MARIADB_MAJOR
+ value: "10.1"
+ <...>
+ imagePullSecrets:
+ - name: onap-docker-registry-key
+
+Note that within the deployment specification, one of the container arguments
+is the key/value pair image: nexus3.onap.org:10001/mariadb:10.1.11 which
+specifies the version of the mariadb software to deploy. Although the
+deployment specifications greatly simplify deployment, maintenance of the
+deployment specifications themselves become problematic as software versions
+change over time or as different versions are required for different
+deployments. For example, if the R&D team needs to deploy a newer version of
+mariadb than what is currently used in the production environment, they would
+need to clone the deployment specification and change this value. Fortunately,
+this problem has been solved with the templating capabilities of Helm.
+
+The following example shows how the deployment specifications are modified to
+incorporate Helm templates such that key/value pairs can be defined outside of
+the deployment specifications and passed during instantiation of the component.
+
+.. code-block:: yaml
+
+ apiVersion: extensions/v1beta1
+ kind: Deployment
+ metadata:
+ name: mariadb
+ namespace: "{{ .Values.nsPrefix }}-mso"
+ spec:
+ <...>
+ template:
+ <...>
+ spec:
+ hostname: mariadb
+ containers:
+ - args:
+ image: {{ .Values.image.mariadb }}
+ imagePullPolicy: {{ .Values.pullPolicy }}
+ name: "mariadb"
+ env:
+ - name: MYSQL_ROOT_PASSWORD
+ value: password
+ - name: MARIADB_MAJOR
+ value: "10.1"
+ <...>
+ imagePullSecrets:
+ - name: "{{ .Values.nsPrefix }}-docker-registry-key"apiVersion: extensions/v1beta1
+ kind: Deployment
+ metadata:
+ name: mariadb
+ namespace: "{{ .Values.nsPrefix }}-mso"
+ spec:
+ <...>
+ template:
+ <...>
+ spec:
+ hostname: mariadb
+ containers:
+ - args:
+ image: {{ .Values.image.mariadb }}
+ imagePullPolicy: {{ .Values.pullPolicy }}
+ name: "mariadb"
+ env:
+ - name: MYSQL_ROOT_PASSWORD
+ value: password
+ - name: MARIADB_MAJOR
+ value: "10.1"
+ <...>
+ imagePullSecrets:
+ - name: "{{ .Values.nsPrefix }}-docker-registry-key"
+
+This version of the deployment specification has gone through the process of
+templating values that are likely to change between deployments. Note that the
+image is now specified as: image: {{ .Values.image.mariadb }} instead of a
+string used previously. During the deployment phase, Helm (actually the Helm
+sub-component Tiller) substitutes the {{ .. }} entries with a variable defined
+in a values.yaml file. The content of this file is as follows:
+
+.. code-block:: yaml
+
+ nsPrefix: onap
+ pullPolicy: IfNotPresent
+ image:
+ readiness: oomk8s/readiness-check:1.0.0
+ mso: nexus3.onap.org:10001/openecomp/mso:1.0-STAGING-latest
+ mariadb: nexus3.onap.org:10001/mariadb:10.1.11
+
+Within the values.yaml file there is an image section with the key/value pair
+mariadb: nexus3.onap.org:10001/mariadb:10.1.11 which is the same value used in
+the non-templated version. Once all of the substitutions are complete, the
+resulting deployment specification ready to be used by Kubernetes.
+
+Also note that in this example, the namespace key/value pair is specified in
+the values.yaml file. This key/value pair will be global across the entire
+ONAP deployment and is therefore a prime example of where configuration
+hierarchy can be very useful.
+
+When creating a deployment template consider the use of default values if
+appropriate. Helm templating has built in support for DEFAULT values, here is
+an example:
+
+.. code-block:: yaml
+
+ imagePullSecrets:
+ - name: "{{ .Values.nsPrefix | default "onap" }}-docker-registry-key"
+
+The pipeline operator ("|") used here hints at that power of Helm templates in
+that much like an operating system command line the pipeline operator allow
+over 60 Helm functions to be embedded directly into the template (note that the
+Helm template language is a superset of the Go template language). These
+functions include simple string operations like upper and more complex flow
+control operations like if/else.
+
+
+ONAP Application Configuration
+------------------------------
Dependency Management
---------------------
@@ -177,17 +499,32 @@ Nodes
~~~~~
OOM works with both physical and virtual worker machines.
-* Virtual Machine Deployments - If ONAP is to be deployed onto a set of virtual machines, the creation of the VMs is outside of the scope of OOM and could be done in many ways, such as
+* Virtual Machine Deployments - If ONAP is to be deployed onto a set of virtual
+ machines, the creation of the VMs is outside of the scope of OOM and could be
+ done in many ways, such as
- * manually, for example by a user using the OpenStack Horizon dashboard or AWS EC2, or
- * automatically, for example with the use of a OpenStack Heat Orchestration Template which builds an ONAP stack, Azure ARM template, AWS CloudFormation Template, or
- * orchestrated, for example with Cloudify creating the VMs from a TOSCA template and controlling their life cycle for the life of the ONAP deployment.
+ * manually, for example by a user using the OpenStack Horizon dashboard or
+ AWS EC2, or
+ * automatically, for example with the use of a OpenStack Heat Orchestration
+ Template which builds an ONAP stack, Azure ARM template, AWS CloudFormation
+ Template, or
+ * orchestrated, for example with Cloudify creating the VMs from a TOSCA
+ template and controlling their life cycle for the life of the ONAP
+ deployment.
-* Physical Machine Deployments - If ONAP is to be deployed onto physical machines there are several options but the recommendation is to use Rancher along with Helm to associate hosts with a Kubernetes cluster.
+* Physical Machine Deployments - If ONAP is to be deployed onto physical
+ machines there are several options but the recommendation is to use Rancher
+ along with Helm to associate hosts with a Kubernetes cluster.
Pods
~~~~
-A group of containers with shared storage and networking can be grouped together into a Kubernetes pod. All of the containers within a pod are co-located and co-scheduled so they operate as a single unit. Within ONAP Amsterdam release, pods are mapped one-to-one to docker containers although this may change in the future. As explained in the Services section below the use of Pods within each ONAP component is abstracted from other ONAP components.
+A group of containers with shared storage and networking can be grouped
+together into a Kubernetes pod. All of the containers within a pod are
+co-located and co-scheduled so they operate as a single unit. Within ONAP
+Amsterdam release, pods are mapped one-to-one to docker containers although
+this may change in the future. As explained in the Services section below the
+use of Pods within each ONAP component is abstracted from other ONAP
+components.
Services
~~~~~~~~
@@ -328,10 +665,10 @@ machines). For example:
nodeSelector:
failure-domain.beta.Kubernetes.io/region: {{ .Values.location }}
-- "location: West" is specified in the values.yaml file used to deploy
- one DCAE cluster and "location: East" is specified in a second values.yaml
+- "location: West" is specified in the `values.yaml` file used to deploy
+ one DCAE cluster and "location: East" is specified in a second `values.yaml`
file (see OOM Configuration Management for more information about
- configuration files like the values.yamlfile).
+ configuration files like the `values.yaml` file).
Node affinity can also be used to achieve geographic redundancy if pods are
assigned to multiple failure domains. For more information refer to `Assigning
@@ -461,166 +798,142 @@ the database components of each of the projects and the same technique can be
used for all persistent state information.
-Configuration Management
-========================
-ONAP is a large system composed of many components - each of which are complex
-systems in themselves - that needs to be deployed in a number of different
-ways. For example, within a single operator's network there may be R&D
-deployments under active development, pre-production versions undergoing system
-testing and production systems that are operating live networks. Each of these
-deployments will differ in significant ways, such as the version of the
-software images deployed. In addition, there may be a number of application
-specific configuration differences, such as operating system environment
-variables. The following describes how the Helm configuration management
-system is used within the OOM project to manage both ONAP infrastructure
-configuration as well as ONAP components configuration.
+Environment Files
+~~~~~~~~~~~~~~~~~
-One of the artifacts that OOM/Kubernetes uses to deploy ONAP components is the
-deployment specification, yet another yaml file. Within these deployment specs
-are a number of parameters as shown in the following mariadb example:
+MSB Integration
+===============
-.. code-block:: yaml
+The \ `Microservices Bus
+Project <https://wiki.onap.org/pages/viewpage.action?pageId=3246982>`__ provides
+facilities to integrate micro-services into ONAP and therefore needs to
+integrate into OOM - primarily through Consul which is the backend of
+MSB service discovery. The following is a brief description of how this
+integration will be done:
- apiVersion: extensions/v1beta1
- kind: Deployment
- metadata:
- name: mariadb
- spec:
- <...>
- template:
- <...>
- spec:
- hostname: mariadb
- containers:
- - args:
- image: nexus3.onap.org:10001/mariadb:10.1.11
- name: "mariadb"
- env:
- - name: MYSQL_ROOT_PASSWORD
- value: password
- - name: MARIADB_MAJOR
- value: "10.1"
- <...>
- imagePullSecrets:
- - name: onap-docker-registry-key
+A registrator to push the service endpoint info to MSB service
+discovery. 
-Note that within the deployment specification, one of the container arguments
-is the key/value pair image: nexus3.onap.org:10001/mariadb:10.1.11 which
-specifies the version of the mariadb software to deploy. Although the
-deployment specifications greatly simplify deployment, maintenance of the
-deployment specifications themselves become problematic as software versions
-change over time or as different versions are required for different
-deployments. For example, if the R&D team needs to deploy a newer version of
-mariadb than what is currently used in the production environment, they would
-need to clone the deployment specification and change this value. Fortunately,
-this problem has been solved with the templating capabilities of Helm.
+- The needed service endpoint info is put into the kubernetes yaml file
+ as annotation, including service name, Protocol,version, visual
+ range,LB method, IP, Port,etc.
-The following example shows how the deployment specifications are modified to
-incorporate Helm templates such that key/value pairs can be defined outside of
-the deployment specifications and passed during instantiation of the component.
+- OOM deploy/start/restart/scale in/scale out/upgrade ONAP components
+
+- Registrator watch the kubernetes event
+
+- When an ONAP component instance has been started/destroyed by OOM,
+ Registrator get the notification from kubernetes
+
+- Registrator parse the service endpoint info from annotation and
+ register/update/unregister it to MSB service discovery
+
+- MSB API Gateway uses the service endpoint info for service routing
+ and load balancing.
+
+Details of the registration service API can be found at \ `Microservice
+Bus API
+Documentation <https://wiki.onap.org/display/DW/Microservice+Bus+API+Documentation>`__.
+
+ONAP Component Registration to MSB
+----------------------------------
+The charts of all ONAP components intending to register against MSB must have
+an annotation in their service(s) template. A `sdc` example follows:
.. code-block:: yaml
- apiVersion: extensions/v1beta1
- kind: Deployment
- metadata:
- name: mariadb
- namespace: "{{ .Values.nsPrefix }}-mso"
- spec:
- <...>
- template:
- <...>
- spec:
- hostname: mariadb
- containers:
- - args:
- image: {{ .Values.image.mariadb }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: "mariadb"
- env:
- - name: MYSQL_ROOT_PASSWORD
- value: password
- - name: MARIADB_MAJOR
- value: "10.1"
- <...>
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"apiVersion: extensions/v1beta1
- kind: Deployment
+ apiVersion: v1
+ kind: Service
metadata:
- name: mariadb
- namespace: "{{ .Values.nsPrefix }}-mso"
- spec:
- <...>
- template:
- <...>
- spec:
- hostname: mariadb
- containers:
- - args:
- image: {{ .Values.image.mariadb }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: "mariadb"
- env:
- - name: MYSQL_ROOT_PASSWORD
- value: password
- - name: MARIADB_MAJOR
- value: "10.1"
- <...>
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
+ labels:
+ app: sdc-be
+ name: sdc-be
+ namespace: "{{ .Values.nsPrefix }}"
+ annotations:
+ msb.onap.org/service-info: '[
+ {
+ "serviceName": "sdc",
+ "version": "v1",
+ "url": "/sdc/v1",
+ "protocol": "REST",
+ "port": "8080",
+ "visualRange":"1"
+ },
+ {
+ "serviceName": "sdc-deprecated",
+ "version": "v1",
+ "url": "/sdc/v1",
+ "protocol": "REST",
+ "port": "8080",
+ "visualRange":"1",
+ "path":"/sdc/v1"
+ }
+ ]'
+ ...
-This version of the deployment specification has gone through the process of
-templating values that are likely to change between deployments. Note that the
-image is now specified as: image: {{ .Values.image.mariadb }} instead of a
-string used previously. During the deployment phase, Helm (actually the Helm
-sub-component Tiller) substitutes the {{ .. }} entries with a variable defined
-in a values.yaml file. The content of this file is as follows:
-.. code-block:: yaml
+MSB Integration with OOM
+------------------------
+A preliminary view of the OOM-MSB integration is as follows:
- nsPrefix: onap
- pullPolicy: IfNotPresent
- image:
- readiness: oomk8s/readiness-check:1.0.0
- mso: nexus3.onap.org:10001/openecomp/mso:1.0-STAGING-latest
- mariadb: nexus3.onap.org:10001/mariadb:10.1.11
+.. figure:: MSB-OOM-Diagram.png
-Within the values.yaml file there is an image section with the key/value pair
-mariadb: nexus3.onap.org:10001/mariadb:10.1.11 which is the same value used in
-the non-templated version. Once all of the substitutions are complete, the
-resulting deployment specification ready to be used by Kubernetes.
+A message sequence chart of the registration process:
-Also note that in this example, the namespace key/value pair is specified in
-the values.yaml file. This key/value pair will be global across the entire
-ONAP deployment and is therefore a prime example of where configuration
-hierarchy can be very useful.
+.. uml::
-When creating a deployment template consider the use of default values if
-appropriate. Helm templating has built in support for DEFAULT values, here is
-an example:
+ participant "OOM" as oom
+ participant "ONAP Component" as onap
+ participant "Service Discovery" as sd
+ participant "External API Gateway" as eagw
+ participant "Router (Internal API Gateway)" as iagw
-.. code-block:: yaml
+ box "MSB" #LightBlue
+ participant sd
+ participant eagw
+ participant iagw
+ end box
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix | default "onap" }}-docker-registry-key"
+ == Deploy Servcie ==
-The pipeline operator ("|") used here hints at that power of Helm templates in
-that much like an operating system command line the pipeline operator allow
-over 60 Helm functions to be embedded directly into the template (note that the
-Helm template language is a superset of the Go template language). These
-functions include simple string operations like upper and more complex flow
-control operations like if/else.
+ oom -> onap: Deploy
+ oom -> sd: Register service endpoints
+ sd -> eagw: Services exposed to external system
+ sd -> iagw: Services for internal use
+ == Component Life-cycle Management ==
-ONAP Application Configuration
-------------------------------
+ oom -> onap: Start/Stop/Scale/Migrate/Upgrade
+ oom -> sd: Update service info
+ sd -> eagw: Update service info
+ sd -> iagw: Update service info
-Environment Files
-~~~~~~~~~~~~~~~~~
+ == Service Health Check ==
+
+ sd -> onap: Check the health of service
+ sd -> eagw: Update service status
+ sd -> iagw: Update service status
+
+
+MSB Deployment Instructions
+---------------------------
+MSB is helm installable ONAP component which is often automatically deployed.
+To install it individually enter::
+
+ > helm install <repo-name>/msb
+
+.. note::
+ TBD: Vaidate if the following procedure is still required.
+
+Please note that Kubernetes authentication token must be set at
+*kubernetes/kube2msb/values.yaml* so the kube2msb registrator can get the
+access to watch the kubernetes events and get service annotation by
+Kubernetes APIs. The token can be found in the kubectl configuration file
+*~/.kube/config*
+
+More details can be found here `MSB installation <http://onap.readthedocs.io/en/latest/submodules/msb/apigateway.git/docs/platform/installation.html>`__.
-MSB Integration
-===============
.. MISC
.. ====
.. Note that although OOM uses Kubernetes facilities to minimize the effort
diff --git a/kubernetes/onap/requirements.yaml b/kubernetes/onap/requirements.yaml
index d440b68b58..d2df213e6b 100644
--- a/kubernetes/onap/requirements.yaml
+++ b/kubernetes/onap/requirements.yaml
@@ -85,7 +85,7 @@ dependencies:
repository: '@local'
condition: robot.enabled
- name: sdc
- version: ~0.1.0
+ version: ~2.0.0
repository: '@local'
condition: sdc.enabled
- name: sdnc
diff --git a/kubernetes/sdc/.helmignore b/kubernetes/sdc/.helmignore
new file mode 100644
index 0000000000..f0c1319444
--- /dev/null
+++ b/kubernetes/sdc/.helmignore
@@ -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/Chart.yaml b/kubernetes/sdc/Chart.yaml
index 0fa6ac5f28..ad56334404 100644
--- a/kubernetes/sdc/Chart.yaml
+++ b/kubernetes/sdc/Chart.yaml
@@ -13,6 +13,6 @@
# limitations under the License.
apiVersion: v1
-description: A Helm chart for Kubernetes
+description: Service Design and Creation Umbrella Helm charts
name: sdc
-version: 0.1.0
+version: 2.0.0
diff --git a/kubernetes/sdc/charts/sdc-be/.helmignore b/kubernetes/sdc/charts/sdc-be/.helmignore
new file mode 100644
index 0000000000..f0c1319444
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/.helmignore
@@ -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-be/Chart.yaml b/kubernetes/sdc/charts/sdc-be/Chart.yaml
new file mode 100644
index 0000000000..9c3648709d
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/Chart.yaml
@@ -0,0 +1,4 @@
+apiVersion: v1
+description: Service Design and Creation Backend API
+name: sdc-be
+version: 2.0.0 \ No newline at end of file
diff --git a/kubernetes/sdc/resources/config/log/be/logback.xml b/kubernetes/sdc/charts/sdc-be/resources/config/logging/logback.xml
index 4d508e3047..4d508e3047 100644
--- a/kubernetes/sdc/resources/config/log/be/logback.xml
+++ b/kubernetes/sdc/charts/sdc-be/resources/config/logging/logback.xml
diff --git a/kubernetes/sdc/charts/sdc-be/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-be/templates/NOTES.txt
new file mode 100644
index 0000000000..0878f5c080
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/templates/NOTES.txt
@@ -0,0 +1,19 @@
+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/templates/sdc-fe-configmap.yaml b/kubernetes/sdc/charts/sdc-be/templates/configmap.yaml
index 648bec40e6..1d0751a01b 100644
--- a/kubernetes/sdc/templates/sdc-fe-configmap.yaml
+++ b/kubernetes/sdc/charts/sdc-be/templates/configmap.yaml
@@ -12,12 +12,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-#{{ if not .Values.disableSdcSdcFe }}
apiVersion: v1
kind: ConfigMap
metadata:
- name: sdc-fe-configmap
- namespace: {{ .Values.nsPrefix }}
+ name: {{ include "common.fullname" . }}-logging-configmap
+ namespace: {{ include "common.namespace" . }}
data:
-{{ tpl (.Files.Glob "resources/config/sdc-fe/*").AsConfig . | indent 2 }}
-#{{ end }}
+{{ tpl (.Files.Glob "resources/config/logging/*").AsConfig . | indent 2 }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-be/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-be/templates/deployment.yaml
new file mode 100644
index 0000000000..4869966876
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/templates/deployment.yaml
@@ -0,0 +1,136 @@
+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:
+ - name: {{ include "common.name" . }}-readiness
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - "sdc-es"
+ - --container-name
+ - "sdc-cs"
+ 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" . }}-job-completion
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: "{{ .Values.global.pullPolicy | default .Values.pullPolicy }}"
+ command:
+ - /root/job_complete.py
+ args:
+ - --job-name
+ - {{ .Release.Name }}-sdc-cs-config-cassandra
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ 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 }}
+ - containerPort: {{ .Values.service.internalPort2 }}
+ # 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 }}
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: JAVA_OPTIONS
+ value: ""
+ - name: HOST_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ - name: {{ include "common.fullname" . }}-localtime
+ mountPath: /etc/localtime
+ readOnly: true
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/log/onap
+ - name: {{ include "common.fullname" . }}-logback
+ mountPath: /tmp/logback.xml
+ lifecycle:
+ postStart:
+ exec:
+ command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
+ 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 }}
+
+ # side car containers
+ - name: {{ include "common.name" . }}-filebeat-onap
+ image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-filebeat-conf
+ mountPath: /usr/share/filebeat/filebeat.yml
+ subPath: filebeat.yml
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/log/onap
+ - name: {{ include "common.fullname" . }}-data-filebeat
+ mountPath: /usr/share/filebeat/data
+ volumes:
+ - name: {{ include "common.fullname" . }}-localtime
+ hostPath:
+ path: /etc/localtime
+ - name: {{ include "common.fullname" . }}-filebeat-conf
+ configMap:
+ name: {{ .Release.Name }}-sdc-filebeat-configmap
+ - name: {{ include "common.fullname" . }}-data-filebeat
+ emptyDir: {}
+ - name: {{ include "common.fullname" . }}-logback
+ configMap:
+ name : {{ include "common.fullname" . }}-logging-configmap
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ - name: {{ include "common.fullname" . }}-logs
+ emptyDir: {}
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key" \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-be/templates/job.yaml b/kubernetes/sdc/charts/sdc-be/templates/job.yaml
new file mode 100644
index 0000000000..7338d2e261
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/templates/job.yaml
@@ -0,0 +1,51 @@
+apiVersion: batch/v1
+kind: Job
+metadata:
+ name: {{ include "common.fullname" . }}-config-backend
+ namespace: {{ include "common.namespace" . }}
+ labels:
+ app: {{ include "common.name" . }}-job
+ chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+ release: {{ .Release.Name }}
+ heritage: {{ .Release.Service }}
+spec:
+ template:
+ metadata:
+ labels:
+ app: {{ include "common.name" . }}-job
+ release: {{ .Release.Name }}
+ spec:
+ restartPolicy: Never
+ initContainers:
+ - name: {{ include "common.name" . }}-init-readiness
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - sdc-be
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ containers:
+ - name: {{ include "common.name" . }}-job
+ image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.backendInitImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ volumes:
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key"
+ restartPolicy: Never
diff --git a/kubernetes/sdc/charts/sdc-be/templates/service.yaml b/kubernetes/sdc/charts/sdc-be/templates/service.yaml
new file mode 100644
index 0000000000..83e9bb458d
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/templates/service.yaml
@@ -0,0 +1,51 @@
+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": "sdc",
+ "version": "v1",
+ "url": "/sdc/v1",
+ "protocol": "REST",
+ "port": "{{ .Values.service.internalPort2 }}",
+ "visualRange":"1"
+ },
+ {
+ "serviceName": "sdc-deprecated",
+ "version": "v1",
+ "url": "/sdc/v1",
+ "protocol": "REST",
+ "port": "{{ .Values.service.internalPort2 }}",
+ "visualRange":"1",
+ "path":"/sdc/v1"
+ }
+ ]'
+spec:
+ type: {{ .Values.service.type }}
+ ports:
+ {{if eq .Values.service.type "NodePort" -}}
+ - port: {{ .Values.service.internalPort }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.internalPort2 }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }}
+ name: {{ .Values.service.name }}2
+ {{- else -}}
+ - port: {{ .Values.service.externalPort }}
+ targetPort: {{ .Values.service.internalPort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.externalPort2 }}
+ targetPort: {{ .Values.service.internalPort2 }}
+ name: {{ .Values.service.name }}2
+ {{- end}}
+ selector:
+ app: {{ include "common.name" . }}
+ release: {{ .Release.Name }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-be/values.yaml b/kubernetes/sdc/charts/sdc-be/values.yaml
new file mode 100644
index 0000000000..ebd5f8fe10
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-be/values.yaml
@@ -0,0 +1,71 @@
+#################################################################
+# 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/sdc-backend:1.2-STAGING-latest
+backendInitImage: onap/sdc-backend-init:1.2-STAGING-latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# 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: NodePort
+ name: sdc-be
+ nodePort: "04"
+ internalPort: 8443
+ nodePort2: "05"
+ internalPort2: 8080
+
+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/sdc/charts/sdc-cs/.helmignore b/kubernetes/sdc/charts/sdc-cs/.helmignore
new file mode 100644
index 0000000000..f0c1319444
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/.helmignore
@@ -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-cs/Chart.yaml b/kubernetes/sdc/charts/sdc-cs/Chart.yaml
new file mode 100644
index 0000000000..9632644448
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/Chart.yaml
@@ -0,0 +1,4 @@
+apiVersion: v1
+description: Service Design and Creation Cassandra
+name: sdc-cs
+version: 2.0.0 \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-cs/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-cs/templates/NOTES.txt
new file mode 100644
index 0000000000..0878f5c080
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/NOTES.txt
@@ -0,0 +1,19 @@
+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-cs/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-cs/templates/deployment.yaml
new file mode 100644
index 0000000000..10fabae288
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/deployment.yaml
@@ -0,0 +1,88 @@
+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 }}
+ - containerPort: {{ .Values.service.internalPort2 }}
+ # 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 }}
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: HOST_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ - name: CS_PASSWORD
+ valueFrom:
+ secretKeyRef: {name: {{ include "common.fullname" . }}, key: cs_password}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-data
+ mountPath: /var/lib/cassandra/
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ - name: {{ include "common.fullname" . }}-localtime
+ mountPath: /etc/localtime
+ readOnly: true
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/lib/jetty/logs
+ 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: {{ include "common.fullname" . }}-localtime
+ hostPath:
+ path: /etc/localtime
+ - name: {{ include "common.fullname" . }}-logs
+ emptyDir: {}
+ {{- if .Values.persistence.enabled }}
+ - name: {{ include "common.fullname" . }}-data
+ persistentVolumeClaim:
+ claimName: {{ include "common.fullname" . }}
+ {{- else }}
+ emptyDir: {}
+ {{- end }}
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key" \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-cs/templates/job.yaml b/kubernetes/sdc/charts/sdc-cs/templates/job.yaml
new file mode 100644
index 0000000000..da2ec3dfec
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/job.yaml
@@ -0,0 +1,60 @@
+apiVersion: batch/v1
+kind: Job
+metadata:
+ name: {{ include "common.fullname" . }}-config-cassandra
+ namespace: {{ include "common.namespace" . }}
+ labels:
+ app: {{ include "common.name" . }}-job
+ chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+ release: {{ .Release.Name }}
+ heritage: {{ .Release.Service }}
+spec:
+ template:
+ metadata:
+ labels:
+ app: {{ include "common.name" . }}-job
+ release: {{ .Release.Name }}
+ spec:
+ restartPolicy: Never
+ initContainers:
+ - name: {{ include "common.name" . }}-init-readiness
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - sdc-cs
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ containers:
+ - name: {{ include "common.name" . }}-job
+ image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.cassandraInitImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: SDC_USER
+ valueFrom:
+ secretKeyRef: {name: {{ include "common.fullname" . }}, key: sdc_user}
+ - name: SDC_PASSWORD
+ valueFrom:
+ secretKeyRef: {name: {{ include "common.fullname" . }}, key: sdc_password}
+ - name: CS_PASSWORD
+ valueFrom:
+ secretKeyRef: {name: {{ include "common.fullname" . }}, key: cs_password}
+ volumes:
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key"
+ restartPolicy: Never
diff --git a/kubernetes/sdc/charts/sdc-cs/templates/pv.yaml b/kubernetes/sdc/charts/sdc-cs/templates/pv.yaml
new file mode 100644
index 0000000000..31230a9ed7
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/pv.yaml
@@ -0,0 +1,21 @@
+{{- 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 -}}
diff --git a/kubernetes/sdc/charts/sdc-cs/templates/pvc.yaml b/kubernetes/sdc/charts/sdc-cs/templates/pvc.yaml
new file mode 100644
index 0000000000..b0cd3bf238
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/pvc.yaml
@@ -0,0 +1,32 @@
+{{- 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/sdc/charts/sdc-cs/templates/secrets.yaml b/kubernetes/sdc/charts/sdc-cs/templates/secrets.yaml
new file mode 100644
index 0000000000..72d96344a8
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/secrets.yaml
@@ -0,0 +1,31 @@
+# Copyright © 2017 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.name" . }}
+ chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+ release: {{ .Release.Name }}
+ heritage: {{ .Release.Service }}
+type: Opaque
+data:
+ #application user
+ sdc_user: "{{ .Values.secrets.sdc_user }}"
+ sdc_password: "{{ .Values.secrets.sdc_password }}"
+ #default user:
+ cs_password: "{{ .Values.secrets.cs_password }}"
diff --git a/kubernetes/sdc/charts/sdc-cs/templates/service.yaml b/kubernetes/sdc/charts/sdc-cs/templates/service.yaml
new file mode 100644
index 0000000000..a41fc38d23
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/templates/service.yaml
@@ -0,0 +1,31 @@
+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 }}
+spec:
+ type: {{ .Values.service.type }}
+ ports:
+ {{if eq .Values.service.type "NodePort" -}}
+ - port: {{ .Values.service.internalPort }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.internalPort2 }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }}
+ name: {{ .Values.service.name }}2
+ {{- else -}}
+ - port: {{ .Values.service.externalPort }}
+ targetPort: {{ .Values.service.internalPort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.externalPort2 }}
+ targetPort: {{ .Values.service.internalPort2 }}
+ name: {{ .Values.service.name }}2
+ {{- end}}
+ selector:
+ app: {{ include "common.name" . }}
+ release: {{ .Release.Name }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-cs/values.yaml b/kubernetes/sdc/charts/sdc-cs/values.yaml
new file mode 100644
index 0000000000..5e2b77c12a
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-cs/values.yaml
@@ -0,0 +1,101 @@
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+ nodePortPrefix: 302
+ repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+ readinessRepository: oomk8s
+ readinessImage: readiness-check:1.1.0
+ loggingRepository: docker.elastic.co
+ loggingImage: beats/filebeat:5.5.0
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/sdc-cassandra:1.2-STAGING-latest
+cassandraInitImage: onap/sdc-cassandra-init:1.2-STAGING-latest
+
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+secrets:
+ sdc_user: YXNkY191c2Vy
+ sdc_password: QWExMjM0JV4h
+ cs_password: b25hcDEyMyNAIQ==
+
+# 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
+ name: sdc-cs
+ externalPort: 9160
+ internalPort: 9160
+ externalPort2: 9042
+ internalPort2: 9042
+
+
+## Persist data to a persitent volume
+persistence:
+ enabled: true
+
+ ## A manually managed Persistent Volume and Claim
+ ## Requires persistence.enabled: true
+ ## If defined, PVC must be created manually before volume will be bound
+ # existingClaim:
+ volumeReclaimPolicy: Retain
+
+ ## database data Persistent Volume Storage Class
+ ## If defined, storageClassName: <storageClass>
+ ## If set to "-", storageClassName: "", which disables dynamic provisioning
+ ## If undefined (the default) or set to null, no storageClassName spec is
+ ## set, choosing the default provisioner. (gp2 on AWS, standard on
+ ## GKE, AWS & OpenStack)
+ ##
+ # storageClass: "-"
+ accessMode: ReadWriteMany
+ size: 2Gi
+ mountPath: /dockerdata-nfs
+ mountSubPath: /sdc/sdc-cs/CS
+
+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/sdc/charts/sdc-es/.helmignore b/kubernetes/sdc/charts/sdc-es/.helmignore
new file mode 100644
index 0000000000..c13e3c8fbb
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/.helmignore
@@ -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 \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-es/Chart.yaml b/kubernetes/sdc/charts/sdc-es/Chart.yaml
new file mode 100644
index 0000000000..f2097a532d
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/Chart.yaml
@@ -0,0 +1,4 @@
+apiVersion: v1
+description: Service Design and Creation Elasticsearch
+name: sdc-es
+version: 2.0.0 \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-es/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-es/templates/NOTES.txt
new file mode 100644
index 0000000000..0878f5c080
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/NOTES.txt
@@ -0,0 +1,19 @@
+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-es/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-es/templates/deployment.yaml
new file mode 100644
index 0000000000..bb08a2aecd
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/deployment.yaml
@@ -0,0 +1,102 @@
+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:
+ - name: {{ include "common.name" . }}-logs-init
+ command:
+ - /bin/bash
+ - "-c"
+ - |
+ mkdir -p /ubuntu-init/ASDC/ASDC-ES/
+ chmod -R 777 /ubuntu-init/
+ image: "{{ .Values.global.ubuntuInitRepository }}/{{ .Values.global.ubuntuInitImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /ubuntu-init/
+ 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 }}
+ - containerPort: {{ .Values.service.internalPort2 }}
+ # 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:
+ httpGet:
+ path: "_cluster/health?wait_for_status=yellow&timeout=120s"
+ port: {{ .Values.service.internalPort }}
+ scheme: HTTP
+ initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
+ periodSeconds: {{ .Values.readiness.periodSeconds }}
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: HOST_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ - name: ES_HEAP_SIZE
+ value: {{ .Values.config.elasticHeapSize }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ - name: {{ include "common.fullname" . }}-localtime
+ mountPath: /etc/localtime
+ readOnly: true
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/lib/jetty/logs
+ - name: {{ include "common.fullname" . }}-data
+ mountPath: /usr/share/elasticsearch/data/
+ 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: {{ include "common.fullname" . }}-localtime
+ hostPath:
+ path: /etc/localtime
+ {{- if .Values.persistence.enabled }}
+ - name: {{ include "common.fullname" . }}-data
+ persistentVolumeClaim:
+ claimName: {{ include "common.fullname" . }}
+ {{- else }}
+ emptyDir: {}
+ {{- end }}
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ - name: {{ include "common.fullname" . }}-logs
+ emptyDir: {}
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key" \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-es/templates/job.yaml b/kubernetes/sdc/charts/sdc-es/templates/job.yaml
new file mode 100644
index 0000000000..03a21c0636
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/job.yaml
@@ -0,0 +1,51 @@
+apiVersion: batch/v1
+kind: Job
+metadata:
+ name: {{ include "common.fullname" . }}-config-elasticsearch
+ namespace: {{ include "common.namespace" . }}
+ labels:
+ app: {{ include "common.name" . }}-job
+ chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+ release: {{ .Release.Name }}
+ heritage: {{ .Release.Service }}
+spec:
+ template:
+ metadata:
+ labels:
+ app: {{ include "common.name" . }}-job
+ release: {{ .Release.Name }}
+ spec:
+ restartPolicy: Never
+ initContainers:
+ - name: {{ include "common.name" . }}-init-readiness
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - sdc-es
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ containers:
+ - name: {{ include "common.name" . }}-job
+ image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.elasticInitImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ volumes:
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key"
+ restartPolicy: Never
diff --git a/kubernetes/sdc/charts/sdc-es/templates/pv.yaml b/kubernetes/sdc/charts/sdc-es/templates/pv.yaml
new file mode 100644
index 0000000000..31230a9ed7
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/pv.yaml
@@ -0,0 +1,21 @@
+{{- 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 -}}
diff --git a/kubernetes/sdc/charts/sdc-es/templates/pvc.yaml b/kubernetes/sdc/charts/sdc-es/templates/pvc.yaml
new file mode 100644
index 0000000000..b0cd3bf238
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/pvc.yaml
@@ -0,0 +1,32 @@
+{{- 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/sdc/charts/sdc-es/templates/service.yaml b/kubernetes/sdc/charts/sdc-es/templates/service.yaml
new file mode 100644
index 0000000000..a41fc38d23
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/templates/service.yaml
@@ -0,0 +1,31 @@
+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 }}
+spec:
+ type: {{ .Values.service.type }}
+ ports:
+ {{if eq .Values.service.type "NodePort" -}}
+ - port: {{ .Values.service.internalPort }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.internalPort2 }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }}
+ name: {{ .Values.service.name }}2
+ {{- else -}}
+ - port: {{ .Values.service.externalPort }}
+ targetPort: {{ .Values.service.internalPort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.externalPort2 }}
+ targetPort: {{ .Values.service.internalPort2 }}
+ name: {{ .Values.service.name }}2
+ {{- end}}
+ selector:
+ app: {{ include "common.name" . }}
+ release: {{ .Release.Name }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-es/values.yaml b/kubernetes/sdc/charts/sdc-es/values.yaml
new file mode 100644
index 0000000000..b32ed11045
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-es/values.yaml
@@ -0,0 +1,101 @@
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+ nodePortPrefix: 302
+ repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+ readinessRepository: oomk8s
+ readinessImage: readiness-check:1.1.0
+ loggingRepository: docker.elastic.co
+ loggingImage: beats/filebeat:5.5.0
+ ubuntuInitRepository: oomk8s
+ ubuntuInitImage: ubuntu-init:1.0.0
+
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/sdc-elasticsearch:1.2-STAGING-latest
+elasticInitImage: onap/sdc-init-elasticsearch:1.2-STAGING-latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# application configuration
+config:
+ elasticHeapSize: 1024M
+
+# 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
+ name: sdc-es
+ externalPort: 9200
+ internalPort: 9200
+ externalPort2: 9300
+ internalPort2: 9300
+
+## Persist data to a persitent volume
+persistence:
+ enabled: true
+
+ ## A manually managed Persistent Volume and Claim
+ ## Requires persistence.enabled: true
+ ## If defined, PVC must be created manually before volume will be bound
+ # existingClaim:
+ volumeReclaimPolicy: Retain
+
+ ## database data Persistent Volume Storage Class
+ ## If defined, storageClassName: <storageClass>
+ ## If set to "-", storageClassName: "", which disables dynamic provisioning
+ ## If undefined (the default) or set to null, no storageClassName spec is
+ ## set, choosing the default provisioner. (gp2 on AWS, standard on
+ ## GKE, AWS & OpenStack)
+ ##
+ # storageClass: "-"
+ accessMode: ReadWriteMany
+ size: 2Gi
+ mountPath: /dockerdata-nfs
+ mountSubPath: /sdc/sdc-es/ES
+
+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/sdc/charts/sdc-fe/.helmignore b/kubernetes/sdc/charts/sdc-fe/.helmignore
new file mode 100644
index 0000000000..f0c1319444
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/.helmignore
@@ -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-fe/Chart.yaml b/kubernetes/sdc/charts/sdc-fe/Chart.yaml
new file mode 100644
index 0000000000..dc60986581
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/Chart.yaml
@@ -0,0 +1,4 @@
+apiVersion: v1
+description: Service Design and Creation Front End
+name: sdc-fe
+version: 2.0.0 \ No newline at end of file
diff --git a/kubernetes/sdc/resources/config/log/fe/logback.xml b/kubernetes/sdc/charts/sdc-fe/resources/config/logging/logback.xml
index a8e9ed7264..6e253543e8 100644
--- a/kubernetes/sdc/resources/config/log/fe/logback.xml
+++ b/kubernetes/sdc/charts/sdc-fe/resources/config/logging/logback.xml
@@ -78,9 +78,9 @@
<!-- Debug log -->
<appender class="ch.qos.logback.core.rolling.RollingFileAppender" name="DEBUG_ROLLING">
<file>${logDirectory}/${debugLogName}.log</file>
- <!-- No need to deny audit messages - they are INFO only, will be denied
+ <!-- No need to deny audit messages - they are INFO only, will be denied
anyway -->
- <!-- Transaction messages filter - deny Transaction messages, there are
+ <!-- Transaction messages filter - deny Transaction messages, there are
some DEBUG level messages among them -->
<filter class="ch.qos.logback.core.filter.EvaluatorFilter">
<evaluator class="ch.qos.logback.classic.boolex.OnMarkerEvaluator">
diff --git a/kubernetes/sdc/charts/sdc-fe/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-fe/templates/NOTES.txt
new file mode 100644
index 0000000000..c4b9989618
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/templates/NOTES.txt
@@ -0,0 +1,19 @@
+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.fullname" . }},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/templates/sdc-environments-configmap.yaml b/kubernetes/sdc/charts/sdc-fe/templates/configmap.yaml
index 741c2818ea..144bdb719f 100644
--- a/kubernetes/sdc/templates/sdc-environments-configmap.yaml
+++ b/kubernetes/sdc/charts/sdc-fe/templates/configmap.yaml
@@ -12,12 +12,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-#{{ if not .Values.disableSdcSdcBe }}
apiVersion: v1
kind: ConfigMap
metadata:
- name: sdc-environments-configmap
- namespace: {{ .Values.nsPrefix }}
+ name: {{ include "common.fullname" . }}-logging-configmap
+ namespace: {{ include "common.namespace" . }}
data:
-{{ tpl (.Files.Glob "resources/config/environments/*").AsConfig . | indent 2 }}
-#{{ end }}
+{{ tpl (.Files.Glob "resources/config/logging/*").AsConfig . | indent 2 }}
diff --git a/kubernetes/sdc/charts/sdc-fe/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-fe/templates/deployment.yaml
new file mode 100644
index 0000000000..818a279773
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/templates/deployment.yaml
@@ -0,0 +1,120 @@
+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:
+ - name: {{ include "common.name" . }}-readiness
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - "sdc-be"
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ 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 }}
+ - containerPort: {{ .Values.service.internalPort2 }}
+ # 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 }}
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: HOST_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ - name: JAVA_OPTIONS
+ value: ""
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ - name: {{ include "common.fullname" . }}-localtime
+ mountPath: /etc/localtime
+ readOnly: true
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/log/onap
+ - name: {{ include "common.fullname" . }}-logback
+ mountPath: /tmp/logback.xml
+ lifecycle:
+ postStart:
+ exec:
+ command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-fe/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
+ 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 }}
+
+ # side car containers
+ - name: {{ include "common.name" . }}-filebeat-onap
+ image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-filebeat-conf
+ mountPath: /usr/share/filebeat/filebeat.yml
+ subPath: filebeat.yml
+ - name: {{ include "common.fullname" . }}-logs
+ mountPath: /var/log/onap
+ - name: {{ include "common.fullname" . }}-data-filebeat
+ mountPath: /usr/share/filebeat/data
+ volumes:
+ - name: {{ include "common.fullname" . }}-localtime
+ hostPath:
+ path: /etc/localtime
+ - name: {{ include "common.fullname" . }}-filebeat-conf
+ configMap:
+ name: {{ .Release.Name }}-sdc-filebeat-configmap
+ - name: {{ include "common.fullname" . }}-data-filebeat
+ emptyDir: {}
+ - name: {{ include "common.fullname" . }}-logback
+ configMap:
+ name : {{ include "common.fullname" . }}-logging-configmap
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ - name: {{ include "common.fullname" . }}-logs
+ emptyDir: {}
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key" \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-fe/templates/service.yaml b/kubernetes/sdc/charts/sdc-fe/templates/service.yaml
new file mode 100644
index 0000000000..fc7a3c75b8
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/templates/service.yaml
@@ -0,0 +1,42 @@
+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": "sdc-gui",
+ "version": "v1",
+ "url": "/sdc1",
+ "protocol": "UI",
+ "port": "{{ .Values.service.internalPort }}",
+ "visualRange":"0|1"
+ }
+ ]'
+spec:
+ type: {{ .Values.service.type }}
+ ports:
+ {{if eq .Values.service.type "NodePort" -}}
+ - port: {{ .Values.service.internalPort }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.internalPort2 }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }}
+ name: {{ .Values.service.name }}2
+ {{- else -}}
+ - port: {{ .Values.service.externalPort }}
+ targetPort: {{ .Values.service.internalPort }}
+ name: {{ .Values.service.name }}
+ - port: {{ .Values.service.externalPort2 }}
+ targetPort: {{ .Values.service.internalPort2 }}
+ name: {{ .Values.service.name }}2
+ {{- end}}
+ selector:
+ app: {{ include "common.name" . }}
+ release: {{ .Release.Name }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-fe/values.yaml b/kubernetes/sdc/charts/sdc-fe/values.yaml
new file mode 100644
index 0000000000..828ec4117a
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-fe/values.yaml
@@ -0,0 +1,75 @@
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+ nodePortPrefix: 302
+ repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+ readinessRepository: oomk8s
+ readinessImage: readiness-check:1.1.0
+ loggingRepository: docker.elastic.co
+ loggingImage: beats/filebeat:5.5.0
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/sdc-frontend:1.2-STAGING-latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# 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:
+ #Example service definition with external, internal and node ports.
+ #Services may use any combination of ports depending on the 'type' of
+ #service being defined.
+ type: NodePort
+ name: sdc-fe
+ nodePort: "06"
+ internalPort: 8181
+ nodePort2: "07"
+ internalPort2: 9443
+
+
+
+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/sdc/charts/sdc-kb/.helmignore b/kubernetes/sdc/charts/sdc-kb/.helmignore
new file mode 100644
index 0000000000..b9208e2c64
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/.helmignore
@@ -0,0 +1,25 @@
+# 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
+
+
+#TODO:REMOVE
+sdc-kb.yaml \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-kb/Chart.yaml b/kubernetes/sdc/charts/sdc-kb/Chart.yaml
new file mode 100644
index 0000000000..2bb4e49829
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/Chart.yaml
@@ -0,0 +1,4 @@
+apiVersion: v1
+description: Service Design and Creation Kibana
+name: sdc-kb
+version: 2.0.0 \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-kb/templates/NOTES.txt b/kubernetes/sdc/charts/sdc-kb/templates/NOTES.txt
new file mode 100644
index 0000000000..0878f5c080
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/templates/NOTES.txt
@@ -0,0 +1,19 @@
+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-kb/templates/deployment.yaml b/kubernetes/sdc/charts/sdc-kb/templates/deployment.yaml
new file mode 100644
index 0000000000..73c01f575e
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/templates/deployment.yaml
@@ -0,0 +1,86 @@
+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:
+ - name: {{ include "common.name" . }}-readiness
+ command:
+ - /root/ready.py
+ args:
+ - --container-name
+ - "sdc-es"
+ env:
+ - name: NAMESPACE
+ valueFrom:
+ fieldRef:
+ apiVersion: v1
+ fieldPath: metadata.namespace
+ image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ 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 }}
+ {{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 }}
+ env:
+ - name: ENVNAME
+ value: {{ .Values.global.env.name }}
+ - name: HOST_IP
+ valueFrom:
+ fieldRef:
+ fieldPath: status.podIP
+ - name: ELASTICSEARCH_URL
+ value: "http://{{ .Release.Name }}-{{ index .Values "sdc-es" "service" "name" }}:9200"
+ volumeMounts:
+ - name: {{ include "common.fullname" . }}-environments
+ mountPath: /root/chef-solo/environments/
+ - name: {{ include "common.fullname" . }}-localtime
+ mountPath: /etc/localtime
+ readOnly: true
+ 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: {{ include "common.fullname" . }}-localtime
+ hostPath:
+ path: /etc/localtime
+ - name: {{ include "common.fullname" . }}-environments
+ configMap:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ defaultMode: 0755
+ imagePullSecrets:
+ - name: "{{ include "common.namespace" . }}-docker-registry-key" \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-kb/templates/service.yaml b/kubernetes/sdc/charts/sdc-kb/templates/service.yaml
new file mode 100644
index 0000000000..0fbaae9947
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/templates/service.yaml
@@ -0,0 +1,25 @@
+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 }}
+spec:
+ type: {{ .Values.service.type }}
+ ports:
+ {{if eq .Values.service.type "NodePort" -}}
+ - port: {{ .Values.service.externalPort }}
+ nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
+ name: {{ .Values.service.name }}
+ {{- else -}}
+ - port: {{ .Values.service.externalPort }}
+ targetPort: {{ .Values.service.internalPort }}
+ name: {{ .Values.service.name }}
+ {{- end}}
+ selector:
+ app: {{ include "common.name" . }}
+ release: {{ .Release.Name }} \ No newline at end of file
diff --git a/kubernetes/sdc/charts/sdc-kb/values.yaml b/kubernetes/sdc/charts/sdc-kb/values.yaml
new file mode 100644
index 0000000000..b1796f4f84
--- /dev/null
+++ b/kubernetes/sdc/charts/sdc-kb/values.yaml
@@ -0,0 +1,73 @@
+#################################################################
+# Global configuration defaults.
+#################################################################
+global:
+ nodePortPrefix: 302
+ repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ==
+ readinessRepository: oomk8s
+ readinessImage: readiness-check:1.1.0
+ loggingRepository: docker.elastic.co
+ loggingImage: beats/filebeat:5.5.0
+
+#################################################################
+# Application configuration defaults.
+#################################################################
+# application image
+repository: nexus3.onap.org:10001
+image: onap/sdc-kibana:1.2-STAGING-latest
+pullPolicy: Always
+
+# flag to enable debugging - application support required
+debugEnabled: false
+
+# 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
+ name: sdc-kb
+ externalPort: 5601
+ internalPort: 5601
+
+
+sdc-es:
+ service:
+ name: sdc-es
+
+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/sdc/requirements.yaml b/kubernetes/sdc/requirements.yaml
new file mode 100644
index 0000000000..acca8ef7e2
--- /dev/null
+++ b/kubernetes/sdc/requirements.yaml
@@ -0,0 +1,4 @@
+dependencies:
+ - name: common
+ version: ~2.0.0
+ repository: '@local' \ No newline at end of file
diff --git a/kubernetes/sdc/resources/config/environments/AUTO.json b/kubernetes/sdc/resources/config/environments/AUTO.json
index d35590ec67..5ae381c746 100755
--- a/kubernetes/sdc/resources/config/environments/AUTO.json
+++ b/kubernetes/sdc/resources/config/environments/AUTO.json
@@ -1,41 +1,58 @@
{
- "name": "AUTO",
- "description": "OpenSource-AUTO",
- "cookbook_versions": {
- "Deploy-SDandC": "= 1.0.0"
- },
- "json_class": "Chef::Environment",
- "chef_type": "environment",
+ "name": "{{ .Values.global.env.name }}",
+ "description": "OpenSource-{{ .Values.global.env.name }}",
+ "cookbook_versions": {
+ "Deploy-SDandC": "= 1.0.0"
+ },
+ "json_class": "Chef::Environment",
+ "chef_type": "environment",
- "default_attributes": {
- "CS_VIP": "sdc-cs.{{.Values.nsPrefix}}",
- "BE_VIP": "sdc-be.{{.Values.nsPrefix}}",
- "FE_VIP": "sdc-fe.{{.Values.nsPrefix}}",
- "ES_VIP": "sdc-es.{{.Values.nsPrefix}}",
+ "default_attributes": {
+ "disableHttp": false,
+ "CS_VIP": "{{.Release.Name}}-sdc-cs.{{include "common.namespace" .}}",
+ "BE_VIP": "{{.Release.Name}}-sdc-be.{{include "common.namespace" .}}",
+ "FE_VIP": "{{.Release.Name}}-sdc-fe.{{include "common.namespace" .}}",
+ "ES_VIP": "{{.Release.Name}}-sdc-es.{{include "common.namespace" .}}",
+ "KB_VIP": "{{.Release.Name}}-sdc-kb.{{include "common.namespace" .}}",
"interfaces": {
"application": "eth0",
"private": "eth0"
},
- "ECompP": {
- "ecomp_rest_url": "http://portalapps.{{.Values.nsPrefix}}:8989/ONAPPORTAL/auxapi",
- "ueb_url_list": "dmaap.{{.Values.nsPrefix}}, dmaap.{{.Values.nsPrefix}}",
+ "ECompP": {
+ "ecomp_rest_url": "http://{{.Release.Name}}-portalapps.{{include "common.namespace" .}}:8989/ONAPPORTAL/auxapi",
+ "ueb_url_list": "{{.Release.Name}}-dmaap.{{include "common.namespace" .}}, {{.Release.Name}}-dmaap.{{include "common.namespace" .}}",
"app_secret": "XftIATw9Jr3VzAcPqt3NnJOu",
"app_key": "x9UfO7JsDn8BESVX",
"inbox_name": "ECOMP-PORTAL-INBOX",
- "ecomp_redirect_url": "http://portalapps.{{.Values.nsPrefix}}:8989/ONAPPORTAL/login.htm",
+ "ecomp_redirect_url": "http://{{.Release.Name}}-portalapps.{{include "common.namespace" .}}:8989/ONAPPORTAL/login.htm",
"app_topic_name": "ECOMP-PORTAL-OUTBOX-SDC1",
- "decryption_key": "AGLDdG4D04BKm2IxIWEr8o=="
+ "decryption_key": "AGLDdG4D04BKm2IxIWEr8o=="
},
"UEB": {
"PublicKey": "iPIxkpAMI8qTcQj8",
"SecretKey": "Ehq3WyT4bkif4zwgEbvshGal",
- "fqdn": ["dmaap.{{.Values.nsPrefix}}", "dmaap.{{.Values.nsPrefix}}"]
+ "fqdn": ["{{.Release.Name}}-dmaap.{{include "common.namespace" .}}", "{{.Release.Name}}-dmaap.{{include "common.namespace" .}}"]
},
"Nodes": {
- "CS": "sdc-cs.{{.Values.nsPrefix}}",
- "BE": "sdc-be.{{.Values.nsPrefix}}",
- "FE": "sdc-fe.{{.Values.nsPrefix}}",
- "ES": "sdc-es.{{.Values.nsPrefix}}"
+ "CS": "{{.Release.Name}}-sdc-cs.{{include "common.namespace" .}}",
+ "BE": "{{.Release.Name}}-sdc-be.{{include "common.namespace" .}}",
+ "FE": "{{.Release.Name}}-sdc-fe.{{include "common.namespace" .}}",
+ "ES": "{{.Release.Name}}-sdc-es.{{include "common.namespace" .}}",
+ "KB": "{{.Release.Name}}-sdc-kb.{{include "common.namespace" .}}"
+ },
+ "Plugins": {
+ "DCAE": {
+ "dcae_discovery_url": "{{.Values.config.environment.dcaeUrl}}",
+ "dcae_source_url": "{{.Values.config.environment.dcaeUrl}}"
+ },
+ "WORKFLOW": {
+ "workflow_discovery_url": "{{.Values.config.environment.workflowUrl}}",
+ "workflow_source_url": "{{.Values.config.environment.workflowUrl}}"
+ }
+ },
+ "VnfRepo": {
+ "vnfRepoPort": "{{.Values.config.environment.vnfRepoPort}}",
+ "vnfRepoHost": "{{.Values.config.environment.vnfRepoHost}}"
}
},
"override_attributes": {
@@ -68,7 +85,10 @@
"cache_dir": "/var/lib/cassandra/saved_caches",
"log_file": "/var/lib/cassandra/log/system.log",
"phi_convict_threshold": "8",
- "commitlog_dir": "/var/lib/cassandra/commitlog"
+ "commitlog_dir": "/var/lib/cassandra/commitlog",
+ "socket_read_timeout": "20000",
+ "socket_connect_timeout": "20000",
+ "titan_connection_timeout": "10000"
}
}
-}
+} \ No newline at end of file
diff --git a/kubernetes/sdc/resources/config/environments/Template.json b/kubernetes/sdc/resources/config/environments/Template.json
deleted file mode 100755
index 247e990f31..0000000000
--- a/kubernetes/sdc/resources/config/environments/Template.json
+++ /dev/null
@@ -1,75 +0,0 @@
-{
- "name": "xxx",
- "description": "OpenSource-xxx",
- "cookbook_versions": {
- "Deploy-SDandC": "= 1.0.0"
- },
- "json_class": "Chef::Environment",
- "chef_type": "environment",
-
- "default_attributes": {
- "CS_VIP": "yyy",
- "BE_VIP": "yyy",
- "FE_VIP": "yyy",
- "ES_VIP": "yyy",
- "interfaces": {
- "application": "eth0",
- "private": "eth1"
- },
- "ECompP": {
- "ecomp_rest_url": "http://portalapps.{{.Values.nsPrefix}}:8989/ONAPPORTAL/auxapi",
- "ueb_url_list": "dmaap.{{.Values.nsPrefix}},dmaap.{{.Values.nsPrefix}}",
- "app_secret": "XftIATw9Jr3VzAcPqt3NnJOu",
- "app_key": "x9UfO7JsDn8BESVX",
- "inbox_name": "ECOMP-PORTAL-INBOX",
- "ecomp_redirect_url": "http://portalapps.{{.Values.nsPrefix}}:8989/ONAPPORTAL/login.htm",
- "app_topic_name": "ECOMP-PORTAL-OUTBOX-SDC1",
- "decryption_key": "AGLDdG4D04BKm2IxIWEr8o=="
- },
- "UEB": {
- "PublicKey": "iPIxkpAMI8qTcQj8",
- "SecretKey": "Ehq3WyT4bkif4zwgEbvshGal",
- "fqdn": ["dmaap.{{.Values.nsPrefix}}", "dmaap.{{.Values.nsPrefix}}"]
- },
- "Nodes": {
- "CS": "yyy",
- "BE": "yyy",
- "FE": "yyy",
- "ES": "yyy"
- }
- },
- "override_attributes": {
- "FE": {
- "http_port": "8181",
- "https_port": "9443"
- },
- "BE": {
- "http_port": "8080",
- "https_port": "8443"
- },
- "elasticsearch": {
- "cluster_name": "SDC-ES-",
- "ES_path_home": "/usr/share/elasticsearch",
- "ES_path_data": "/usr/share/elasticsearch/data",
- "num_of_replicas": "0",
- "num_of_shards": "1"
- },
-
- "cassandra": {
- "concurrent_reads": "32",
- "num_tokens": "256",
- "data_dir": "/var/lib/cassandra/data",
- "hinted_handoff_enabled": "true",
- "cassandra_user": "asdc_user",
- "cassandra_password": "Aa1234%^!",
- "concurrent_writes": "32",
- "cluster_name": "SDC-CS-",
- "multithreaded_compaction": "false",
- "cache_dir": "/var/lib/cassandra/saved_caches",
- "log_file": "/var/lib/cassandra/log/system.log",
- "phi_convict_threshold": "8",
- "commitlog_dir": "/var/lib/cassandra/commitlog"
- }
- }
-}
-
diff --git a/kubernetes/sdc/resources/config/sdc-fe/FE_2_setup_configuration.rb b/kubernetes/sdc/resources/config/sdc-fe/FE_2_setup_configuration.rb
deleted file mode 100755
index 5c233a2207..0000000000
--- a/kubernetes/sdc/resources/config/sdc-fe/FE_2_setup_configuration.rb
+++ /dev/null
@@ -1,27 +0,0 @@
-jetty_base="/var/lib/jetty"
-template "catalog-fe-config" do
- path "#{jetty_base}/config/catalog-fe/configuration.yaml"
- source "FE-configuration.yaml.erb"
- owner "jetty"
- group "jetty"
- mode "0755"
- variables({
- :fe_host_ip => node['HOST_IP'],
- :be_host_ip => "sdc-be.{{.Values.nsPrefix}}",
- :catalog_port => node['BE'][:http_port],
- :ssl_port => node['BE'][:https_port]
- })
-end
-
-template "onboarding-fe-config" do
- path "#{jetty_base}/config/onboarding-fe/onboarding_configuration.yaml"
- source "FE-onboarding-configuration.yaml.erb"
- owner "jetty"
- group "jetty"
- mode "0755"
- variables({
- :catalog_ip => node['HOST_IP'],
- :catalog_port => node['BE'][:http_port],
- :ssl_port => node['BE'][:https_port]
-})
-end
diff --git a/kubernetes/sdc/templates/all-services.yaml b/kubernetes/sdc/templates/all-services.yaml
deleted file mode 100644
index 1f0a9a720c..0000000000
--- a/kubernetes/sdc/templates/all-services.yaml
+++ /dev/null
@@ -1,141 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcEs }}
-apiVersion: v1
-kind: Service
-metadata:
- labels:
- app: sdc-es
- name: sdc-es
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- ports:
- - name: sdc-es-port-9200
- port: 9200
- - name: sdc-es-port-9300
- port: 9300
- selector:
- app: sdc-es
- clusterIP: None
-#{{ end }}
-#{{ if not .Values.disableSdcSdcCs }}
----
-apiVersion: v1
-kind: Service
-metadata:
- labels:
- app: sdc-cs
- name: sdc-cs
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- ports:
- - name: sdc-cs-port-9042
- port: 9042
- - name: sdc-cs-port-9160
- port: 9160
- selector:
- app: sdc-cs
- clusterIP: None
-#{{ end }}
-#{{ if not .Values.disableSdcSdcKb }}
----
-apiVersion: v1
-kind: Service
-metadata:
- labels:
- app: sdc-kb
- name: sdc-kb
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- ports:
- - name: sdc-kb-port-5601
- port: 5601
- selector:
- app: sdc-kb
- clusterIP: None
-#{{ end }}
-#{{ if not .Values.disableSdcSdcBe }}
----
-apiVersion: v1
-kind: Service
-metadata:
- labels:
- app: sdc-be
- name: sdc-be
- namespace: "{{ .Values.nsPrefix }}"
- annotations:
- msb.onap.org/service-info: '[
- {
- "serviceName": "sdc",
- "version": "v1",
- "url": "/sdc/v1",
- "protocol": "REST",
- "port": "8080",
- "visualRange":"1"
- },
- {
- "serviceName": "sdc-deprecated",
- "version": "v1",
- "url": "/sdc/v1",
- "protocol": "REST",
- "port": "8080",
- "visualRange":"1",
- "path":"/sdc/v1"
- }
- ]'
-spec:
- ports:
- - name: sdc-be-port-8443
- nodePort: {{ .Values.nodePortPrefix }}04
- port: 8443
- - name: sdc-be-port-8080
- nodePort: {{ .Values.nodePortPrefix }}05
- port: 8080
- selector:
- app: sdc-be
- type: NodePort
-#{{ end }}
-#{{ if not .Values.disableSdcSdcFe }}
----
-apiVersion: v1
-kind: Service
-metadata:
- labels:
- app: sdc-fe
- name: sdc-fe
- namespace: "{{ .Values.nsPrefix }}"
- annotations:
- msb.onap.org/service-info: '[
- {
- "serviceName": "sdc-gui",
- "version": "v1",
- "url": "/sdc1",
- "protocol": "UI",
- "port": "8181",
- "visualRange":"0|1"
- }
- ]'
-spec:
- ports:
- - name: sdc-fe-port-9443
- nodePort: {{ .Values.nodePortPrefix }}07
- port: 9443
- - name: sdc-fe-port-8181
- nodePort: {{ .Values.nodePortPrefix }}06
- port: 8181
- selector:
- app: sdc-fe
- type: NodePort
-#{{ end }} \ No newline at end of file
diff --git a/kubernetes/sdc/templates/configmap.yaml b/kubernetes/sdc/templates/configmap.yaml
new file mode 100644
index 0000000000..f09c48276e
--- /dev/null
+++ b/kubernetes/sdc/templates/configmap.yaml
@@ -0,0 +1,15 @@
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ .Release.Name }}-sdc-environments-configmap
+ namespace: {{ include "common.namespace" . }}
+data:
+{{ tpl (.Files.Glob "resources/config/environments/*").AsConfig . | indent 2 }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ .Release.Name }}-sdc-filebeat-configmap
+ namespace: {{ include "common.namespace" . }}
+data:
+{{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }} \ No newline at end of file
diff --git a/kubernetes/sdc/templates/sdc-be.yaml b/kubernetes/sdc/templates/sdc-be.yaml
deleted file mode 100644
index 9cf036a55e..0000000000
--- a/kubernetes/sdc/templates/sdc-be.yaml
+++ /dev/null
@@ -1,137 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcBe }}
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
- labels:
- app: sdc-be
- name: sdc-be
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- selector:
- matchLabels:
- app: sdc-be
- template:
- metadata:
- labels:
- app: sdc-be
- name: sdc-be
- spec:
- initContainers:
- - command:
- - /root/ready.py
- args:
- - --container-name
- - sdc-es
- - --container-name
- - sdc-cs
- - --container-name
- - sdc-kb
- env:
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: metadata.namespace
- image: {{ .Values.image.readiness }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-be-readiness
- - command:
- - /root/ready.py
- args:
- - --container-name
- - dmaap
- env:
- - name: NAMESPACE
- value: {{ .Values.nsPrefix }}
- image: {{ .Values.image.readiness }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-dmaap-readiness
- containers:
- - env:
- - name: ENVNAME
- value: AUTO
- - name: HOST_IP
- valueFrom:
- fieldRef:
- fieldPath: status.podIP
- image: {{ .Values.image.sdcBackend }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-be
- volumeMounts:
- - mountPath: /usr/share/elasticsearch/data/
- name: sdc-sdc-es-es
- - mountPath: /root/chef-solo/environments/
- name: sdc-environments
- - mountPath: /etc/localtime
- name: sdc-localtime
- readOnly: true
- - mountPath: /var/lib/jetty/logs
- name: sdc-logs
- - mountPath: /var/log/onap
- name: sdc-logs-2
- - mountPath: /tmp/logback.xml
- name: sdc-logback
- lifecycle:
- postStart:
- exec:
- command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
- ports:
- - containerPort: 8443
- - containerPort: 8080
- readinessProbe:
- tcpSocket:
- port: 8443
- initialDelaySeconds: 5
- periodSeconds: 10
- - image: {{ .Values.image.filebeat }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: filebeat-onap
- volumeMounts:
- - mountPath: /usr/share/filebeat/filebeat.yml
- name: filebeat-conf
- subPath: filebeat.yml
- - mountPath: /var/log/onap
- name: sdc-logs-2
- - mountPath: /usr/share/filebeat/data
- name: sdc-data-filebeat
- volumes:
- - name: filebeat-conf
- configMap:
- name: sdc-filebeat-configmap
- - name: sdc-logs-2
- emptyDir: {}
- - name: sdc-data-filebeat
- emptyDir: {}
- - name: sdc-logback
- configMap:
- name : sdc-log-be-configmap
- - name: sdc-sdc-es-es
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/sdc-es/ES
- - name: sdc-environments
- configMap:
- name: sdc-environments-configmap
- defaultMode: 0755
- - name: sdc-localtime
- hostPath:
- path: /etc/localtime
- - name: sdc-logs
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/logs
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-cs.yaml b/kubernetes/sdc/templates/sdc-cs.yaml
deleted file mode 100644
index d41d5f75b8..0000000000
--- a/kubernetes/sdc/templates/sdc-cs.yaml
+++ /dev/null
@@ -1,95 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcCs }}
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
- labels:
- app: sdc-cs
- name: sdc-cs
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- selector:
- matchLabels:
- app: sdc-cs
- template:
- metadata:
- labels:
- app: sdc-cs
- name: sdc-cs
- spec:
- initContainers:
- - command:
- - /root/ready.py
- args:
- - --container-name
- - sdc-es
- env:
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: metadata.namespace
- image: {{ .Values.image.readiness }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-cs-readiness
- containers:
- - env:
- - name: ENVNAME
- value: AUTO
- - name: HOST_IP
- valueFrom:
- fieldRef:
- fieldPath: status.podIP
- - name: ES_HEAP_SIZE
- value: "1024M"
- image: {{ .Values.image.sdcCassandra }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-cs
- volumeMounts:
- - mountPath: /var/lib/cassandra/
- name: sdc-sdc-cs-cs
- - mountPath: /root/chef-solo/environments/
- name: sdc-environments
- - mountPath: /etc/localtime
- name: sdc-localtime
- readOnly: true
- - mountPath: /var/lib/jetty/logs
- name: sdc-logs
- ports:
- - containerPort: 9042
- - containerPort: 9160
- readinessProbe:
- tcpSocket:
- port: 9160
- initialDelaySeconds: 5
- periodSeconds: 10
- volumes:
- - name: sdc-sdc-cs-cs
- persistentVolumeClaim:
- claimName: sdc-cs-db
- - name: sdc-environments
- configMap:
- name : sdc-environments-configmap
- defaultMode: 0755
- - name: sdc-localtime
- hostPath:
- path: /etc/localtime
- - name: sdc-logs
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/logs
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-es.yaml b/kubernetes/sdc/templates/sdc-es.yaml
deleted file mode 100644
index 0c3f3dedf7..0000000000
--- a/kubernetes/sdc/templates/sdc-es.yaml
+++ /dev/null
@@ -1,91 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcEs }}
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
- labels:
- app: sdc-es
- name: sdc-es
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- selector:
- matchLabels:
- app: sdc-es
- template:
- metadata:
- labels:
- app: sdc-es
- name: sdc-es
- spec:
- initContainers:
- - name: sdc-logs-init
- image: {{ .Values.image.ubuntuInit }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- command:
- - /bin/bash
- - "-c"
- - |
- mkdir -p /ubuntu-init/ASDC/ASDC-ES/
- mkdir -p /ubuntu-init/ASDC/ASDC-CS/
- mkdir -p /ubuntu-init/ASDC/ASDC-KB/
- mkdir -p /ubuntu-init/ASDC/ASDC-BE/
- mkdir -p /ubuntu-init/ASDC/ASDC-FE/
- chmod -R 777 /ubuntu-init/
- containers:
- - image: {{ .Values.image.sdcElasticsearch }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-es
- env:
- - name: ENVNAME
- value: "AUTO"
- - name: HOST_IP
- valueFrom:
- fieldRef:
- fieldPath: status.podIP
- - name: ES_HEAP_SIZE
- value: "1024M"
- volumeMounts:
- - name: sdc-logs
- mountPath: /ubuntu-init/
- - mountPath: /root/chef-solo/environments/
- name: sdc-environments
- - mountPath: /etc/localtime
- name: sdc-localtime
- readOnly: true
- - mountPath: /var/lib/jetty/logs
- name: sdc-logs
- ports:
- - containerPort: 9200
- - containerPort: 9300
- readinessProbe:
- tcpSocket:
- port: 9200
- initialDelaySeconds: 5
- periodSeconds: 10
- volumes:
- - name: sdc-environments
- configMap :
- name : sdc-environments-configmap
- defaultMode: 0755
- - name: sdc-localtime
- hostPath:
- path: /etc/localtime
- - name: sdc-logs
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/logs
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-fe.yaml b/kubernetes/sdc/templates/sdc-fe.yaml
deleted file mode 100644
index b61e11fa95..0000000000
--- a/kubernetes/sdc/templates/sdc-fe.yaml
+++ /dev/null
@@ -1,135 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcFe }}
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
- labels:
- app: sdc-fe
- name: sdc-fe
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- selector:
- matchLabels:
- app: sdc-fe
- template:
- metadata:
- labels:
- app: sdc-fe
- name: sdc-fe
- spec:
- initContainers:
- - command:
- - /root/ready.py
- args:
- - --container-name
- - sdc-es
- - --container-name
- - sdc-cs
- - --container-name
- - sdc-kb
- - --container-name
- - sdc-be
- env:
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: metadata.namespace
- image: {{ .Values.image.readiness }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-fe-readiness
- containers:
- - name: sdc-fe
- env:
- - name: ENVNAME
- value: AUTO
- - name: HOST_IP
- valueFrom:
- fieldRef:
- fieldPath: status.podIP
- image: {{ .Values.image.sdcFrontend }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- volumeMounts:
- - mountPath: /usr/share/elasticsearch/data/
- name: sdc-sdc-es-es
- - mountPath: /root/chef-solo/environments/
- name: sdc-environments
- - mountPath: /etc/localtime
- name: sdc-localtime
- readOnly: true
- - mountPath: /var/lib/jetty/logs
- name: sdc-logs
- - mountPath: /var/log/onap
- name: sdc-logs-2
- - mountPath: /root/chef-solo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb
- name: sdc-fe-config
- subPath: FE_2_setup_configuration.rb
- - mountPath: /tmp/logback.xml
- name: sdc-logback
- lifecycle:
- postStart:
- exec:
- command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-fe/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
- ports:
- - containerPort: 9443
- - containerPort: 8181
- readinessProbe:
- tcpSocket:
- port: 8181
- initialDelaySeconds: 5
- periodSeconds: 10
- - image: {{ .Values.image.filebeat }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: filebeat-onap
- volumeMounts:
- - mountPath: /usr/share/filebeat/filebeat.yml
- name: filebeat-conf
- subPath: filebeat.yml
- - mountPath: /var/log/onap
- name: sdc-logs-2
- - mountPath: /usr/share/filebeat/data
- name: sdc-data-filebeat
- volumes:
- - name: filebeat-conf
- configMap:
- name : sdc-filebeat-configmap
- - name: sdc-logs-2
- emptyDir: {}
- - name: sdc-data-filebeat
- emptyDir: {}
- - name: sdc-logback
- configMap:
- name : sdc-log-fe-configmap
- - name: sdc-sdc-es-es
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/sdc-es/ES
- - name: sdc-environments
- configMap:
- name: sdc-environments-configmap
- defaultMode: 0755
- - name: sdc-localtime
- hostPath:
- path: /etc/localtime
- - name: sdc-logs
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/logs
- - name: sdc-fe-config
- configMap:
- name: sdc-fe-configmap
- defaultMode: 0755
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-kb.yaml b/kubernetes/sdc/templates/sdc-kb.yaml
deleted file mode 100644
index 122781b62e..0000000000
--- a/kubernetes/sdc/templates/sdc-kb.yaml
+++ /dev/null
@@ -1,87 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcKb }}
-apiVersion: extensions/v1beta1
-kind: Deployment
-metadata:
- labels:
- app: sdc-kb
- name: sdc-kb
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- selector:
- matchLabels:
- app: sdc-kb
- template:
- metadata:
- labels:
- app: sdc-kb
- name: sdc-kb
- spec:
- initContainers:
- - command:
- - /root/ready.py
- args:
- - --container-name
- - sdc-es
- - --container-name
- - sdc-cs
- env:
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: metadata.namespace
- image: {{ .Values.image.readiness }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-kb-readiness
- containers:
- - env:
- - name: ENVNAME
- value: AUTO
- - name: ELASTICSEARCH_URL
- value: http://sdc-es:9200
- image: {{ .Values.image.sdcKibana }}
- imagePullPolicy: {{ .Values.pullPolicy }}
- name: sdc-kb
- volumeMounts:
- - mountPath: /root/chef-solo/environments/
- name: sdc-environments
- - mountPath: /etc/localtime
- name: sdc-localtime
- readOnly: true
- - mountPath: /var/lib/jetty/logs
- name: sdc-logs
- ports:
- - containerPort: 5601
- readinessProbe:
- tcpSocket:
- port: 5601
- initialDelaySeconds: 5
- periodSeconds: 10
- volumes:
- - name: sdc-environments
- configMap:
- name: sdc-environments-configmap
- defaultMode: 0755
- - name: sdc-localtime
- hostPath:
- path: /etc/localtime
- - name: sdc-logs
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/logs
- imagePullSecrets:
- - name: "{{ .Values.nsPrefix }}-docker-registry-key"
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-log-configmap.yaml b/kubernetes/sdc/templates/sdc-log-configmap.yaml
deleted file mode 100644
index 78312b7c04..0000000000
--- a/kubernetes/sdc/templates/sdc-log-configmap.yaml
+++ /dev/null
@@ -1,41 +0,0 @@
-# Copyright © 2017 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.
-
-#{{ if not .Values.disableSdcSdcBe }}
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: sdc-log-be-configmap
- namespace: {{ .Values.nsPrefix }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/be/*").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: sdc-filebeat-configmap
- namespace: {{ .Values.nsPrefix }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }}
-#{{ end }}
----
-#{{ if not .Values.disableSdcSdcFe }}
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: sdc-log-fe-configmap
- namespace: {{ .Values.nsPrefix }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/fe/*").AsConfig . | indent 2 }}
-#{{ end }}
diff --git a/kubernetes/sdc/templates/sdc-pv-pvc.yaml b/kubernetes/sdc/templates/sdc-pv-pvc.yaml
deleted file mode 100644
index d4dbc1b2a6..0000000000
--- a/kubernetes/sdc/templates/sdc-pv-pvc.yaml
+++ /dev/null
@@ -1,48 +0,0 @@
-{{/*
-# Copyright © 2017 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.
-*/}}
-
-#{{ if not .Values.disableSdcSdcCs }}
-apiVersion: v1
-kind: PersistentVolume
-metadata:
- name: "{{ .Values.nsPrefix }}-sdc"
- namespace: "{{ .Values.nsPrefix }}"
- labels:
- name: "{{ .Values.nsPrefix }}-sdc"
-spec:
- capacity:
- storage: 2Gi
- accessModes:
- - ReadWriteMany
- persistentVolumeReclaimPolicy: Retain
- hostPath:
- path: {{ .Values.dataRootDir }}/{{ .Values.nsPrefix }}/sdc/sdc-cs/CS
----
-kind: PersistentVolumeClaim
-apiVersion: v1
-metadata:
- name: sdc-cs-db
- namespace: "{{ .Values.nsPrefix }}"
-spec:
- accessModes:
- - ReadWriteMany
- resources:
- requests:
- storage: 2Gi
- selector:
- matchLabels:
- name: "{{ .Values.nsPrefix }}-sdc"
-#{{ end }}
diff --git a/kubernetes/sdc/values.yaml b/kubernetes/sdc/values.yaml
index 40b3ec3f23..90a4d28eaa 100644
--- a/kubernetes/sdc/values.yaml
+++ b/kubernetes/sdc/values.yaml
@@ -12,19 +12,22 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-nsPrefix: onap
-pullPolicy: Always
-nodePortPrefix: 302
-dataRootDir: /dockerdata-nfs
-image:
- readiness: oomk8s/readiness-check:1.1.0
- sdcKibana: nexus3.onap.org:10001/openecomp/sdc-kibana:v1.1.0
- sdcFrontend: nexus3.onap.org:10001/openecomp/sdc-frontend:v1.1.0
- sdcElasticsearch: nexus3.onap.org:10001/openecomp/sdc-elasticsearch:v1.1.0
- sdcCassandra: nexus3.onap.org:10001/openecomp/sdc-cassandra:v1.1.0
- sdcBackend: nexus3.onap.org:10001/openecomp/sdc-backend:v1.1.0
- filebeat: docker.elastic.co/beats/filebeat:5.5.0
- ubuntuInit: oomk8s/ubuntu-init:1.0.0
+global:
+ persistence: {}
+ env:
+ name: AUTO
+
config:
logstashServiceName: log-ls
logstashPort: 5044
+ environment:
+ dcaeUrl: 10.0.2.15
+ workflowUrl: 10.0.2.15
+ vnfRepoPort: 8702
+ vnfRepoHost: 192.168.50.5
+
+
+
+sdc-es:
+ service:
+ name: sdc-es \ No newline at end of file