diff options
36 files changed, 637 insertions, 938 deletions
diff --git a/docs/OOM Project Description/oom_project_description.rst b/docs/OOM Project Description/oom_project_description.rst index 2f6883d961..18309ca74c 100644 --- a/docs/OOM Project Description/oom_project_description.rst +++ b/docs/OOM Project Description/oom_project_description.rst @@ -22,7 +22,7 @@ its life cycle while using hardware resources efficiently. Quick Start Guide ================= -Once a kubernetes environment is available (check out `ONAP on Kubernetes <file:///C:\display\DW\ONAP+on+Kubernetes>`__ if you're +Once a kubernetes environment is available (check out `ONAP on Kubernetes <https://wiki.onap.org/display/DW/ONAP+on+Kubernetes>`__ if you're getting started) and the deployment artifacts have been customized for your location, ONAP is ready to be installed. The first step is to setup @@ -71,7 +71,7 @@ short video demonstration by Mike Elliott: .. raw:: html - <video controls src="/OOM_Demo.mp4"></video> + <video controls src="_static/OOM_Demo.mp4"></video> OOM Architecture and Technical Details @@ -82,7 +82,7 @@ management system to orchestrate the life cycle of the ONAP infrastructure components.  If you'd like to learn more about how this works or develop the deployment specifications for a project not already managed by OOM look here: \ `OOM User -Guide <file:///C:\display\DW\OOM+User+Guide>`__. +Guide <http://onap.readthedocs.io/en/latest/submodules/oom.git/docs/OOM%20User%20Guide/oom_user_guide.html>`__. Links to Further Information @@ -90,4 +90,4 @@ Links to Further Information - Configuration data for all of the ONAP sub-projects is distributed by OOM.  For more information on how this is done see: \ `OOM - Configuration Management <file:///C:\display\DW\OOM+Configuration+Management>`__. + Configuration Management <https://wiki.onap.org/display/DW/OOM+Configuration+Management>`__. diff --git a/kubernetes/README.md b/kubernetes/README.md index 4760d9ec0d..dc49e5445b 100644 --- a/kubernetes/README.md +++ b/kubernetes/README.md @@ -1,35 +1,80 @@ -ONAP on Kubernetes -==================== +## **Quick Start Guide - ONAP on Kubernetes** -Under construction... +This is a quick start guide to help you get started on ONAP installation. Creating an ONAP deployment instance requires creating base configuration on the host node and then deploying the runtime containers. -Creating an ONAP deployment instance requires creating base configuration on the -host node and then deploying the runtime containers. +Pre-requisites: -The following is an example of creating the first deployed instance in a K8s -cluster. The name given to the instance is 'dev1'. This will serve as the -Namespace prefix for each deployed ONAP component (ie. dev1-mso). +- Your Kubernetes environment must be available. For more information see, [ONAP on Kubernetes](https://wiki.onap.org/display/DW/ONAP+on+Kubernetes). +- Deployment artifacts are customized for your location. - 1. oom/kubernetes/config/createConfig.sh -n dev1 +Step 1 - 2. oom/kubernetes/oneclick/createAll.bash -n dev1 +Review and optionally change configuration parameters: -To delete the runtime containers for the deployed instance, use the following: +Setup the [/oom/kubernetes/config/onap-parameters.yaml](https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/config/onap-parameters.yaml;h=7ddaf4d4c3dccf2fad515265f0da9c31ec0e64b1;hb=refs/heads/master) file with key-value pairs specific to your OpenStack environment. - 3. oom/kubernetes/oneclick/deleteAll.bash -n dev1 +OR -Note that deleting the runtime containers does not remove the configuration -created in step 1. +There is a [sample](https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/config/onap-parameters-sample.yaml;h=3a74beddbbf7f9f9ec8e5a6abaecb7cb238bd519;hb=refs/heads/master) that may help you out or even be usable directly if you don't intend to actually use OpenStack resources. -To deploy more than one ONAP instance within the same Kubernetes cluster, you -will need to specify an Instance number. This is currently required due to the -use of NodePort ranges. NodePorts allow external IP:Port access to containers -that are running inside a Kubernetes cluster. +Step 2 -Example if this is the 2 instance of an ONAP deployment in the cluster: +In-order to be able to support multiple ONAP instances within a single kubernetes environment, a configuration set is required. To do this, execute the [createConfig.sh](https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/config/createConfig.sh;h=f226ccae47ca6de15c1da49be4b8b6de974895ed;hb=refs/heads/master) script: - 1. oom/kubernetes/config/createConfig.sh -n test +> oom/kubernetes/config/createConfig.sh -n onap - 2. oom/kubernetes/oneclick/createAll.bash -n test -i 2 +Where: +'onap' refers to the name of the instance. This serves as the Namespace prefix for each deployed ONAP component (for example, onap-mso). + +Step 3 + +The bash script [createAll.bash](https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/oneclick/createAll.bash;h=5e5f2dc76ea7739452e757282e750638b4e3e1de;hb=refs/heads/master) is used to create an ONAP deployment with kubernetes. It has two primary functions: + +- Creating the namespaces used to encapsulate the ONAP components, and +- Creating the services, pods and containers within each of these namespaces that provide the core functionality of ONAP. + +Before you execute the createAll.bash. script, pod config-init ([pod-config-init.yaml](https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/config/pod-config-init.yaml;h=b1285ce21d61815c082f6d6aa3c43d00561811c7;hb=refs/heads/master)) may need editing to match your environment and deployment into the default namespace. + +To deploy the containers and create your ONAP system, execute the following command: + +> oom/kubernetes/oneclick/createAll.bash -n onap + +#### **Additional information on usage of createAll.bash** + +Namespaces provide isolation between ONAP components as ONAP release 1.0 contains duplicate application (for example, mariadb) and port usage. + +As such createAll.bash requires the user to enter a namespace prefix string that can be used to separate multiple deployments of onap. The result will be set of 10 namespaces (for example, onap-sdc, onap-aai, onap-mso, onap-message-router, onap-robot, onap-vid, onap-sdnc, onap-portal, onap-policy, onap-appc) being created within the kubernetes environment. + + +#### **Deploying multiple ONAP instances within the same Kubernetes cluster** + +To deploy multiple ONAP instances, you must specify the number of Instances you would like to create in a Kubernetes cluster using createAllbash. + +This is currently required due to the use of NodePort ranges. NodePorts allow external IP:Port access to containers that are running inside a Kubernetes cluster. + +To create multiple instances of an ONAP deployment in the cluster, use the following commands: + +> oom/kubernetes/config/createConfig.sh -n onap + +> oom/kubernetes/oneclick/createAll.bash -n onap -i 2 + +Where: + +- 'onap' refers to the name of the instance. + +- ‘i 2’ refers to the number of instances of an ONAP deployment in the cluster. + +#### **To delete a deployed instance** + +To delete a deployed instance, use the following command: + +> oom/kubernetes/oneclick/deleteAll.bash -n onap + +**Note:** Deleting the runtime containers does not remove the configuration created in step 2. + +For more information on OOM project documentation, refer to: + + - [Quick Start Guide on Wiki](https://wiki.onap.org/display/DW/ONAP+Operations+Manager+Project#ONAPOperationsManagerProject-QuickStartGuide) + - [Quick Start Guide on readthedocs](http://onap.readthedocs.io/en/latest/submodules/oom.git/docs/OOM%20Project%20Description/oom_project_description.html#quick-start-guide) diff --git a/kubernetes/aai/templates/aai-deployment.yaml b/kubernetes/aai/templates/aai-deployment.yaml index c2220cacde..a65cf44cba 100644 --- a/kubernetes/aai/templates/aai-deployment.yaml +++ b/kubernetes/aai/templates/aai-deployment.yaml @@ -13,29 +13,24 @@ spec: labels: app: aai-service name: aai-service - annotations: - pod.beta.kubernetes.io/init-containers: '[{ - "args": [ - "--container-name", "aai-resources", - "--container-name", "aai-traversal" - ], - "command": [ - "/root/ready.py" - ], - "env": [{ - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - }], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "aai-service-readiness" - }]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - aai-resources + - --container-name + - aai-traversal + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: aai-service-readiness containers: - name: aai-service image: "{{ .Values.image.aaiProxy }}:{{ .Values.image.aaiProxyVersion}}" @@ -69,4 +64,4 @@ spec: restartPolicy: Always imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/aai/templates/aai-resources-deployment.yaml b/kubernetes/aai/templates/aai-resources-deployment.yaml index ebf447f3ca..2e46284076 100644 --- a/kubernetes/aai/templates/aai-resources-deployment.yaml +++ b/kubernetes/aai/templates/aai-resources-deployment.yaml @@ -13,33 +13,22 @@ spec: labels: app: aai-resources name: aai-resources - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "hbase" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "aai-resources-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - hbase + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: aai-resources-readiness containers: - name: aai-resources image: "{{ .Values.image.aaiResourcesImage }}:{{ .Values.image.aaiResourcesVersion}}" @@ -113,4 +102,4 @@ metadata: namespace: {{ .Values.nsPrefix }}-aai data: {{ (.Files.Glob "resources/resources/conf/logback.xml").AsConfig | indent 2 }} -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/aai/templates/aai-traversal-deployment.yaml b/kubernetes/aai/templates/aai-traversal-deployment.yaml index a54c49a59d..03bd0dcd87 100644 --- a/kubernetes/aai/templates/aai-traversal-deployment.yaml +++ b/kubernetes/aai/templates/aai-traversal-deployment.yaml @@ -13,35 +13,24 @@ spec: labels: app: aai-traversal name: aai-traversal - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "hbase", - "--container-name", - "aai-resources" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "aai-traversal-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - hbase + - --container-name + - aai-resources + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: aai-traversal-readiness containers: - name: aai-traversal image: "{{ .Values.image.aaiTraversalImage }}:{{ .Values.image.aaiTraversalVersion }}" @@ -115,4 +104,4 @@ metadata: namespace: {{ .Values.nsPrefix }}-aai data: {{ (.Files.Glob "resources/traversal/conf/logback.xml").AsConfig | indent 2 }} -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/appc/templates/appc-deployment.yaml b/kubernetes/appc/templates/appc-deployment.yaml index e379c167d7..f4593b0d73 100644 --- a/kubernetes/appc/templates/appc-deployment.yaml +++ b/kubernetes/appc/templates/appc-deployment.yaml @@ -13,33 +13,22 @@ spec: labels: app: appc name: appc - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "appc-db-container" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "appc-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - appc-db-container + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: appc-readiness containers: - command: - /opt/openecomp/appc/bin/startODL.sh @@ -112,4 +101,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdnc/conf/aaiclient.properties imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/appc/templates/dgbuilder-deployment.yaml b/kubernetes/appc/templates/dgbuilder-deployment.yaml index 32ccdafc3b..ed69c05f38 100644 --- a/kubernetes/appc/templates/dgbuilder-deployment.yaml +++ b/kubernetes/appc/templates/dgbuilder-deployment.yaml @@ -13,35 +13,24 @@ spec: labels: app: appc-dgbuilder name: appc-dgbuilder - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "appc-db-container", - "--container-name", - "appc-controller-container" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "appc-dgbuilder-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - appc-db-container + - --container-name + - appc-controller-container + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: appc-dgbuilder-readiness containers: - command: - /bin/bash @@ -73,4 +62,4 @@ spec: restartPolicy: Always imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/config/docker/init/src/config/aai/sparky-be/appconfig/portal/portal.properties b/kubernetes/config/docker/init/src/config/aai/sparky-be/appconfig/portal/portal.properties index cf99f5da59..33d91cf88a 100644 --- a/kubernetes/config/docker/init/src/config/aai/sparky-be/appconfig/portal/portal.properties +++ b/kubernetes/config/docker/init/src/config/aai/sparky-be/appconfig/portal/portal.properties @@ -7,10 +7,10 @@ portal.api.impl.class = org.openecomp.sparky.security.portal.PortalRestAPIServic # Instance of ECOMP Portal where the app has been on-boarded # use insecure http for dev purposes to avoid self-signed certificate -ecomp_rest_url = http://portalapps.onap-portal:8989/ECOMPPORTAL/auxapi +ecomp_rest_url = http://portalapps.onap-portal:8989/ONAPPORTAL/auxapi # Standard global logon page -ecomp_redirect_url = http://portalapps.onap-portal:8989/ECOMPPORTAL/login.htm +ecomp_redirect_url = http://portalapps.onap-portal:8989/ONAPPORTAL/login.htm # Name of cookie to extract on login request csp_cookie_name = EPService diff --git a/kubernetes/config/docker/init/src/config/policy/opt/policy/config/pe/console.conf b/kubernetes/config/docker/init/src/config/policy/opt/policy/config/pe/console.conf index d5be80a675..b0a7888398 100755 --- a/kubernetes/config/docker/init/src/config/policy/opt/policy/config/pe/console.conf +++ b/kubernetes/config/docker/init/src/config/policy/opt/policy/config/pe/console.conf @@ -121,7 +121,7 @@ onap_application_name= #-----------------------ONAP-PORTAL-Properties---------------------- -ONAP_REDIRECT_URL=http://portalapps.onap-portal:8989/ECOMPPORTAL/login.htm +ONAP_REDIRECT_URL=http://portalapps.onap-portal:8989/ONAPPORTAL/login.htm ONAP_REST_URL= ONAP_UEB_URL_LIST= ONAP_PORTAL_INBOX_NAME= @@ -129,4 +129,4 @@ ONAP_UEB_APP_KEY= ONAP_UEB_APP_SECRET= ONAP_UEB_APP_MAILBOX_NAME= APP_DISPLAY_NAME=ONAP Policy -ONAP_SHARED_CONTEXT_REST_URL=http://portalapps.onap-portal:8989/ECOMPPORTAL/context +ONAP_SHARED_CONTEXT_REST_URL=http://portalapps.onap-portal:8989/ONAPPORTAL/context diff --git a/kubernetes/config/docker/init/src/config/sdc/environments/AUTO.json b/kubernetes/config/docker/init/src/config/sdc/environments/AUTO.json index 62583517f1..5d6eaef94e 100755 --- a/kubernetes/config/docker/init/src/config/sdc/environments/AUTO.json +++ b/kubernetes/config/docker/init/src/config/sdc/environments/AUTO.json @@ -17,12 +17,12 @@ "private": "eth0" }, "ECompP": { - "ecomp_rest_url": "http://portalapps.onap-portal:8989/ECOMPPORTAL/auxapi", + "ecomp_rest_url": "http://portalapps.onap-portal:8989/ONAPPORTAL/auxapi", "ueb_url_list": "dmaap.onap-message-router, dmaap.onap-message-router", "app_secret": "XftIATw9Jr3VzAcPqt3NnJOu", "app_key": "x9UfO7JsDn8BESVX", "inbox_name": "ECOMP-PORTAL-INBOX", - "ecomp_redirect_url": "http://portalapps.onap-portal:8989/ECOMPPORTAL/login.htm", + "ecomp_redirect_url": "http://portalapps.onap-portal:8989/ONAPPORTAL/login.htm", "app_topic_name": "ECOMP-PORTAL-OUTBOX-SDC1", "decryption_key": "AGLDdG4D04BKm2IxIWEr8o==" }, diff --git a/kubernetes/config/docker/init/src/config/sdc/environments/Template.json b/kubernetes/config/docker/init/src/config/sdc/environments/Template.json index 0bec1b76a2..ddddc78e2b 100755 --- a/kubernetes/config/docker/init/src/config/sdc/environments/Template.json +++ b/kubernetes/config/docker/init/src/config/sdc/environments/Template.json @@ -17,12 +17,12 @@ "private": "eth1" }, "ECompP": { - "ecomp_rest_url": "http://portalapps.onap-portal:8989/ECOMPPORTAL/auxapi", + "ecomp_rest_url": "http://portalapps.onap-portal:8989/ONAPPORTAL/auxapi", "ueb_url_list": "dmaap.onap-message-router,dmaap.onap-message-router", "app_secret": "XftIATw9Jr3VzAcPqt3NnJOu", "app_key": "x9UfO7JsDn8BESVX", "inbox_name": "ECOMP-PORTAL-INBOX", - "ecomp_redirect_url": "http://portalapps.onap-portal:8989/ECOMPPORTAL/login.htm", + "ecomp_redirect_url": "http://portalapps.onap-portal:8989/ONAPPORTAL/login.htm", "app_topic_name": "ECOMP-PORTAL-OUTBOX-SDC1", "decryption_key": "AGLDdG4D04BKm2IxIWEr8o==" }, diff --git a/kubernetes/dcae/templates/cdap0-dep.yaml b/kubernetes/dcae/templates/cdap0-dep.yaml index c6239e219b..37d7d58a16 100644 --- a/kubernetes/dcae/templates/cdap0-dep.yaml +++ b/kubernetes/dcae/templates/cdap0-dep.yaml @@ -22,22 +22,15 @@ spec: labels: app: cdap0 name: cdap0 - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "name": "create-fs", - "image": "{{ .Values.image.cdapfs }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "command": ["/bin/bash", "-c", "mkdir -p /cdap/{cdap0-opt-tools,cdap0-opt-data,pod-ip}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"], - "volumeMounts": [ - { - "mountPath": "/cdap", - "name": "cdap-root" - } - ] - } - ]' spec: + initContainers: + - command: ["/bin/bash", "-c", "mkdir -p /cdap/{cdap0-opt-tools,cdap0-opt-data,pod-ip}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"] + name: create-fs + image: {{ .Values.image.cdapfs }} + imagePullPolicy: {{ .Values.pullPolicy }} + volumeMounts: + - mountPath: /cdap + name: cdap-root hostname: zldcprivatecloudtruecdap00 containers: - image: {{ .Values.image.cdap }} @@ -83,4 +76,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/dcae/cdap/cdap0-opt-data imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/dcae/templates/cdap1-dep.yaml b/kubernetes/dcae/templates/cdap1-dep.yaml index 64f69d32dd..7529777038 100644 --- a/kubernetes/dcae/templates/cdap1-dep.yaml +++ b/kubernetes/dcae/templates/cdap1-dep.yaml @@ -22,22 +22,15 @@ spec: labels: app: cdap1 name: cdap1 - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "name": "create-fs", - "image": "{{ .Values.image.cdapfs }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "command": ["/bin/bash", "-c", "mkdir -p /cdap/{cdap1-opt-tools,cdap1-opt-data}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"], - "volumeMounts": [ - { - "mountPath": "/cdap", - "name": "cdap-root" - } - ] - } - ]' spec: + initContainers: + - command: ["/bin/bash", "-c", "mkdir -p /cdap/{cdap1-opt-tools,cdap1-opt-data}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"] + name: create-fs + image: {{ .Values.image.cdapfs }} + imagePullPolicy: {{ .Values.pullPolicy }} + volumeMounts: + - mountPath: /cdap + name: cdap-root hostname: zldcprivatecloudtruecdap01 containers: - image: {{ .Values.image.cdap }} @@ -83,4 +76,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/dcae/cdap/cdap1-opt-data imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/dcae/templates/cdap2-dep.yaml b/kubernetes/dcae/templates/cdap2-dep.yaml index f6d6ec70e4..d146894e56 100644 --- a/kubernetes/dcae/templates/cdap2-dep.yaml +++ b/kubernetes/dcae/templates/cdap2-dep.yaml @@ -22,22 +22,15 @@ spec: labels: app: cdap2 name: cdap2 - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "name": "create-fs", - "image": "{{ .Values.image.cdapfs }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "command": ["/bin/bash", "-c", "mkdir -p /cdap/{cdap2-opt-tools,cdap2-opt-data}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"], - "volumeMounts": [ - { - "mountPath": "/cdap", - "name": "cdap-root" - } - ] - } - ]' spec: + initContainers: + - command: ["/bin/bash", "-c", "mkdir -p /cdap/{cdap2-opt-tools,cdap2-opt-data}; grep `hostname` /etc/hosts > /cdap/pod-ip/`hostname`_ip.txt; while [`ls /cdap/pod-ip | wc -l` < 3]; do sleep 1; done"] + name: create-fs + image: {{ .Values.image.cdapfs }} + imagePullPolicy: {{ .Values.pullPolicy }} + volumeMounts: + - mountPath: /cdap + name: cdap-root hostname: zldcprivatecloudtruecdap02 containers: - image: {{ .Values.image.cdap }} @@ -83,4 +76,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/dcae/cdap/cdap2-opt-data imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/dcae/templates/dcae-dmaap.yaml b/kubernetes/dcae/templates/dcae-dmaap.yaml index 885620b18d..46c2e65b46 100644 --- a/kubernetes/dcae/templates/dcae-dmaap.yaml +++ b/kubernetes/dcae/templates/dcae-dmaap.yaml @@ -13,35 +13,24 @@ spec: labels: app: dmaap name: dmaap - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "kafka", - "--container-name", - "zookeeper" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "dmaap-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - kafka + - --container-name + - zookeeper + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: dmaap-readiness containers: - image: {{ .Values.image.dmaap }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -74,4 +63,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/dcae/message-router/dmaap/mykey imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/dcae/templates/dcae-kafka.yaml b/kubernetes/dcae/templates/dcae-kafka.yaml index 9bfca2bd94..de18137235 100644 --- a/kubernetes/dcae/templates/dcae-kafka.yaml +++ b/kubernetes/dcae/templates/dcae-kafka.yaml @@ -13,33 +13,22 @@ spec: labels: app: kafka name: kafka - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "zookeeper" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "kafka-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - zookeeper + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: kafka-readiness containers: - image: {{ .Values.image.kafka }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -82,4 +71,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/dcae/message-router/dcae-startup-vm-message-router/docker_files/start-kafka.sh imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/log/templates/elasticsearch-deployment.yaml b/kubernetes/log/templates/elasticsearch-deployment.yaml index c123df1daa..74ab921834 100644 --- a/kubernetes/log/templates/elasticsearch-deployment.yaml +++ b/kubernetes/log/templates/elasticsearch-deployment.yaml @@ -15,30 +15,23 @@ spec: labels: app: elasticsearch name: elasticsearch - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "command": ["sysctl", "-w", "vm.max_map_count=262144"], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "securityContext": { - "privileged": true - }, - "image": "{{ .Values.image.es_bb }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "init-sysctl" - } - ]' spec: + initContainers: + - command: + - sysctl + - -w + - vm.max_map_count=262144 + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + securityContext: + privileged: true + image: {{ .Values.image.es_bb }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: init-sysctl containers: - name: elasticsearch image: {{ .Values.image.elasticsearch}} diff --git a/kubernetes/log/templates/kibana-deployment.yaml b/kubernetes/log/templates/kibana-deployment.yaml index e48cbb4ac4..2de825e516 100644 --- a/kubernetes/log/templates/kibana-deployment.yaml +++ b/kubernetes/log/templates/kibana-deployment.yaml @@ -15,33 +15,22 @@ spec: labels: app: kibana name: kibana - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "elasticsearch" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "kibana-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - elasticsearch + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: kibana-readiness containers: - name: kibana image: {{ .Values.image.kibana }} diff --git a/kubernetes/log/templates/logstash-deployment.yaml b/kubernetes/log/templates/logstash-deployment.yaml index d25793e178..47c72c8145 100644 --- a/kubernetes/log/templates/logstash-deployment.yaml +++ b/kubernetes/log/templates/logstash-deployment.yaml @@ -15,34 +15,22 @@ spec: labels: app: logstash name: logstash - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "elasticsearch" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "logstash-readiness" - } - ]' - spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - elasticsearch + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: logstash-readiness containers: - name: logstash image: {{ .Values.image.logstash }} diff --git a/kubernetes/message-router/templates/message-router-dmaap.yaml b/kubernetes/message-router/templates/message-router-dmaap.yaml index 67d51fd00e..1d9777e760 100644 --- a/kubernetes/message-router/templates/message-router-dmaap.yaml +++ b/kubernetes/message-router/templates/message-router-dmaap.yaml @@ -13,35 +13,24 @@ spec: labels: app: dmaap name: dmaap - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "global-kafka", - "--container-name", - "zookeeper" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "dmaap-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - global-kafka + - --container-name + - zookeeper + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: dmaap-readiness containers: - image: {{ .Values.image.dmaap }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -80,4 +69,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/message-router/dmaap/mykey imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -{{ end }}
\ No newline at end of file +{{ end }} diff --git a/kubernetes/message-router/templates/message-router-kafka.yaml b/kubernetes/message-router/templates/message-router-kafka.yaml index 3e2628b750..ab12c28cec 100644 --- a/kubernetes/message-router/templates/message-router-kafka.yaml +++ b/kubernetes/message-router/templates/message-router-kafka.yaml @@ -13,33 +13,22 @@ spec: labels: app: global-kafka name: global-kafka - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "zookeeper" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "kafka-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - zookeeper + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: kafka-readiness containers: - image: {{ .Values.image.kafka }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -88,4 +77,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/message-router/dcae-startup-vm-message-router/docker_files/start-kafka.sh imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/oneclick/deleteAll.bash b/kubernetes/oneclick/deleteAll.bash index cf293e48ad..b41679b061 100755 --- a/kubernetes/oneclick/deleteAll.bash +++ b/kubernetes/oneclick/deleteAll.bash @@ -94,7 +94,6 @@ fi printf "\n********** Cleaning up ONAP: ${ONAP_APPS[*]}\n" - for i in ${HELM_APPS[@]}; do delete_app_helm $NS $i @@ -103,6 +102,9 @@ for i in ${HELM_APPS[@]}; do done +delete_app_helm $NS "config" +kubectl delete namespace $NS + if $WAIT_TERMINATE; then wait_terminate $NS fi diff --git a/kubernetes/policy/templates/dep-brmsgw.yaml b/kubernetes/policy/templates/dep-brmsgw.yaml index df5d888165..7a1bcdec49 100644 --- a/kubernetes/policy/templates/dep-brmsgw.yaml +++ b/kubernetes/policy/templates/dep-brmsgw.yaml @@ -14,39 +14,28 @@ spec: labels: app: brmsgw name: brmsgw - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "mariadb", - "--container-name", - "nexus", - "--container-name", - "pap", - "--container-name", - "pdp" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "brmsgw-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - mariadb + - --container-name + - nexus + - --container-name + - pap + - --container-name + - pdp + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: brmsgw-readiness containers: - command: - /bin/bash @@ -70,4 +59,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/policy/opt/policy/config/pe/ imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/policy/templates/dep-drools.yaml b/kubernetes/policy/templates/dep-drools.yaml index 3e9fa014fb..48ef16e3b2 100644 --- a/kubernetes/policy/templates/dep-drools.yaml +++ b/kubernetes/policy/templates/dep-drools.yaml @@ -14,41 +14,30 @@ spec: labels: app: drools name: drools - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "mariadb", - "--container-name", - "nexus", - "--container-name", - "pap", - "--container-name", - "pdp", - "--container-name", - "brmsgw" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "drools-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - mariadb + - --container-name + - nexus + - --container-name + - pap + - --container-name + - pdp + - --container-name + - brmsgw + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: drools-readiness containers: - command: - /bin/bash @@ -112,4 +101,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/policy/opt/policy/config/drools/ imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/policy/templates/dep-nexus.yaml b/kubernetes/policy/templates/dep-nexus.yaml index 07cd334879..4adb05f630 100644 --- a/kubernetes/policy/templates/dep-nexus.yaml +++ b/kubernetes/policy/templates/dep-nexus.yaml @@ -13,33 +13,22 @@ spec: labels: app: nexus name: nexus - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "mariadb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "nexus-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - mariadb + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: nexus-readiness containers: - image: "{{ .Values.image.policyNexus }}:{{ .Values.image.policyNexusVersion }}" imagePullPolicy: {{ .Values.pullPolicy }} @@ -54,4 +43,4 @@ spec: path: /etc/localtime imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/policy/templates/dep-pap.yaml b/kubernetes/policy/templates/dep-pap.yaml index 0816aa5291..523cfd35ff 100644 --- a/kubernetes/policy/templates/dep-pap.yaml +++ b/kubernetes/policy/templates/dep-pap.yaml @@ -13,58 +13,37 @@ spec: labels: app: pap name: pap - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "nexus", - "--container-name", - "mariadb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "pap-readiness" - }, - { - "env": [ - { - "name": "POD_IP", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "status.podIP" - } - } - } - ], - "command": ["/bin/bash", "-c", "echo $POD_IP > /config/ip_addr.txt"], - "volumeMounts": [ - { - "mountPath": "/config/", - "name": "pe" - } - ], - "image": "{{ .Values.image.ubuntu }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "generate-ip-addr-txt" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - nexus + - --container-name + - mariadb + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: pap-readiness + - command: ["/bin/bash", "-c", "echo $POD_IP > /config/ip_addr.txt"] + env: + - name: POD_IP + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: status.podIP + volumeMounts: + - mountPath: /config/ + name: pe + image: {{ .Values.image.ubuntu }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: generate-ip-addr-txt containers: - command: - /bin/bash @@ -129,4 +108,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/policy/opt/policy/config/pe/ imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/policy/templates/dep-pdp.yaml b/kubernetes/policy/templates/dep-pdp.yaml index 6cc442b417..3763b95bb2 100644 --- a/kubernetes/policy/templates/dep-pdp.yaml +++ b/kubernetes/policy/templates/dep-pdp.yaml @@ -14,37 +14,26 @@ spec: labels: app: pdp name: pdp - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "mariadb", - "--container-name", - "nexus", - "--container-name", - "pap" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "pdp-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - mariadb + - --container-name + - nexus + - --container-name + - pap + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: pdp-readiness containers: - command: - /bin/bash @@ -103,4 +92,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/policy/opt/policy/config/pe/ imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/portal/templates/portal-apps-deployment.yaml b/kubernetes/portal/templates/portal-apps-deployment.yaml index 75977c7be0..761441acc3 100755 --- a/kubernetes/portal/templates/portal-apps-deployment.yaml +++ b/kubernetes/portal/templates/portal-apps-deployment.yaml @@ -13,49 +13,31 @@ spec: labels: app: portalapps name: portalapps - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "portaldb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "portalapps-readiness" - }, - { - "command": ["/bin/bash", "-c", "if [ ! -e /portal_root/boot.txt ]; then mysql -u root -pAa123456 -h portaldb < /portal-mysql/oom_updates.sql; fi"], - "volumeMounts": [ - { - "mountPath": "/portal-mysql/oom_updates.sql", - "name": "portal-mariadb-onboarding-sql" - }, - { - "mountPath": "/portal_root/", - "name": "portal-root" - } - ], - "image": "{{ .Values.image.mariadbClient }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "provision-portaldb-users" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - portaldb + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: portalapps-readiness + - command: ["/bin/bash", "-c", "if [ ! -e /portal_root/boot.txt ]; then mysql -u root -pAa123456 -h portaldb < /portal-mysql/oom_updates.sql; fi"] + volumeMounts: + - mountPath: /portal-mysql/oom_updates.sql + name: portal-mariadb-onboarding-sql + - mountPath: /portal_root/ + name: portal-root + image: {{ .Values.image.mariadbClient }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: provision-portaldb-users containers: - image: {{ .Values.image.portalapps }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -160,4 +142,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/portal/logs imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/portal/templates/portal-vnc-dep.yaml b/kubernetes/portal/templates/portal-vnc-dep.yaml index b4a9effe59..8d49bb2a27 100644 --- a/kubernetes/portal/templates/portal-vnc-dep.yaml +++ b/kubernetes/portal/templates/portal-vnc-dep.yaml @@ -15,100 +15,63 @@ spec: labels: app: vnc-portal name: vnc-portal - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "portalapps" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnc-portal-readiness" - }, - { - "args": [ - "--container-name", - "pap" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "value": "{{ .Values.nsPrefix }}-policy" - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnc-pap-readiness" - }, - { - "args": [ - "--container-name", - "sdc-fe" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "value": "{{ .Values.nsPrefix }}-sdc" - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnc-sdc-readiness" - }, - { - "args": [ - "--container-name", - "vid-server" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "value": "{{ .Values.nsPrefix }}-vid" - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnc-vid-readiness" - }, - { - "command": ["/bin/sh","-c"], - "args": ["echo `host sdc-be.{{ .Values.nsPrefix }}-sdc | awk ''{print$4}''` sdc.api.be.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host portalapps.{{ .Values.nsPrefix }}-portal | awk ''{print$4}''` portal.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host pap.{{ .Values.nsPrefix }}-policy | awk ''{print$4}''` policy.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host sdc-fe.{{ .Values.nsPrefix }}-sdc | awk ''{print$4}''` sdc.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host vid-server.{{ .Values.nsPrefix }}-vid | awk ''{print$4}''` vid.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host sparky-be.{{ .Values.nsPrefix }}-aai | awk ''{print$4}''` aai.api.simpledemo.onap.org >> /ubuntu-init/hosts"], - "image": "{{ .Values.image.ubuntuInit }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnc-init-hosts", - "volumeMounts": [ - { - "name": "ubuntu-init", - "mountPath": "/ubuntu-init/" - } - ] - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - portalapps + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnc-portal-readiness + - command: + - /root/ready.py + args: + - --container-name + - pap + env: + - name: NAMESPACE + value: {{ .Values.nsPrefix }}-policy + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnc-pap-readiness + - command: + - /root/ready.py + args: + - --container-name + - sdc-fe + env: + - name: NAMESPACE + value: {{ .Values.nsPrefix }}-sdc + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnc-sdc-readiness + - command: + - /root/ready.py + args: + - --container-name + - vid-server + env: + - name: NAMESPACE + value: {{ .Values.nsPrefix }}-vid + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnc-vid-readiness + - command: ["/bin/sh","-c"] + args: ["echo `host sdc-be.{{ .Values.nsPrefix }}-sdc | awk ''{print$4}''` sdc.api.be.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host portalapps.{{ .Values.nsPrefix }}-portal | awk ''{print$4}''` portal.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host pap.{{ .Values.nsPrefix }}-policy | awk ''{print$4}''` policy.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host sdc-fe.{{ .Values.nsPrefix }}-sdc | awk ''{print$4}''` sdc.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host vid-server.{{ .Values.nsPrefix }}-vid | awk ''{print$4}''` vid.api.simpledemo.onap.org >> /ubuntu-init/hosts; echo `host sparky-be.{{ .Values.nsPrefix }}-aai | awk ''{print$4}''` aai.api.simpledemo.onap.org >> /ubuntu-init/hosts"] + image: {{ .Values.image.ubuntuInit }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnc-init-hosts + volumeMounts: + - name: ubuntu-init + mountPath: /ubuntu-init/ containers: - image: {{ .Values.image.ubuntuDesktop }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -137,4 +100,4 @@ spec: emptyDir: {} imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/portal/templates/portal-widgets-deployment.yaml b/kubernetes/portal/templates/portal-widgets-deployment.yaml index 865d84523f..600419399e 100644 --- a/kubernetes/portal/templates/portal-widgets-deployment.yaml +++ b/kubernetes/portal/templates/portal-widgets-deployment.yaml @@ -13,33 +13,22 @@ spec: labels: app: portalwidgets name: portalwidgets - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "portaldb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "portalapps-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - portaldb + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: portalapps-readiness containers: - image: {{ .Values.image.portalwms }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -66,4 +55,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/portal/portal-fe/webapps/etc/ONAPWIDGETMS/application.properties imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/sdc/templates/sdc-be.yaml b/kubernetes/sdc/templates/sdc-be.yaml index f38dbd71d9..41560525e1 100644 --- a/kubernetes/sdc/templates/sdc-be.yaml +++ b/kubernetes/sdc/templates/sdc-be.yaml @@ -15,55 +15,37 @@ spec: labels: app: sdc-be name: sdc-be - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "sdc-es", - "--container-name", - "sdc-cs", - "--container-name", - "sdc-kb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "sdc-be-readiness" - }, - { - "args": [ - "--container-name", - "dmaap" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "value": "{{ .Values.nsPrefix }}-message-router" - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "sdc-dmaap-readiness" - } - ]' 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 }}-message-router + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: sdc-dmaap-readiness containers: - env: - name: ENVNAME @@ -136,4 +118,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/sdc/templates/sdc-cs.yaml b/kubernetes/sdc/templates/sdc-cs.yaml index d93ea2d7cf..a81d4ae826 100644 --- a/kubernetes/sdc/templates/sdc-cs.yaml +++ b/kubernetes/sdc/templates/sdc-cs.yaml @@ -15,33 +15,22 @@ spec: labels: app: sdc-cs name: sdc-cs - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "sdc-es" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "sdc-cs-readiness" - } - ]' 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 @@ -88,4 +77,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/sdc/templates/sdc-fe.yaml b/kubernetes/sdc/templates/sdc-fe.yaml index 4648c56c6f..bc1777f3ab 100644 --- a/kubernetes/sdc/templates/sdc-fe.yaml +++ b/kubernetes/sdc/templates/sdc-fe.yaml @@ -15,39 +15,28 @@ spec: labels: app: sdc-fe name: sdc-fe - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "sdc-es", - "--container-name", - "sdc-cs", - "--container-name", - "sdc-kb", - "--container-name", - "sdc-be" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "sdc-fe-readiness" - } - ]' 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: diff --git a/kubernetes/sdc/templates/sdc-kb.yaml b/kubernetes/sdc/templates/sdc-kb.yaml index 1f6f6e8dbf..a7334d4d08 100644 --- a/kubernetes/sdc/templates/sdc-kb.yaml +++ b/kubernetes/sdc/templates/sdc-kb.yaml @@ -15,35 +15,24 @@ spec: labels: app: sdc-kb name: sdc-kb - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "sdc-es", - "--container-name", - "sdc-cs" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "sdc-kb-readiness" - } - ]' 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 @@ -80,4 +69,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/vid/templates/vid-server-deployment.yaml b/kubernetes/vid/templates/vid-server-deployment.yaml index 1c0321833b..832fdeb93c 100644 --- a/kubernetes/vid/templates/vid-server-deployment.yaml +++ b/kubernetes/vid/templates/vid-server-deployment.yaml @@ -15,33 +15,22 @@ spec: labels: app: vid-server name: vid-server - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "vid-mariadb" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vid-server-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - vid-mariadb + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ .Values.image.readiness }} + imagePullPolicy: {{ .Values.pullPolicy }} + name: vid-server-readiness containers: - env: - name: ASDC_CLIENT_REST_HOST @@ -132,4 +121,4 @@ spec: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/vid/logback.xml imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" -#{{ end }}
\ No newline at end of file +#{{ end }} diff --git a/kubernetes/vnfsdk/templates/refrepo-deployment.yaml b/kubernetes/vnfsdk/templates/refrepo-deployment.yaml index 82f5f172db..0a56c740c1 100644 --- a/kubernetes/vnfsdk/templates/refrepo-deployment.yaml +++ b/kubernetes/vnfsdk/templates/refrepo-deployment.yaml @@ -15,33 +15,22 @@ spec: labels: app: refrepo name: refrepo - annotations: - pod.beta.kubernetes.io/init-containers: '[ - { - "args": [ - "--container-name", - "postgres" - ], - "command": [ - "/root/ready.py" - ], - "env": [ - { - "name": "NAMESPACE", - "valueFrom": { - "fieldRef": { - "apiVersion": "v1", - "fieldPath": "metadata.namespace" - } - } - } - ], - "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}", - "imagePullPolicy": "{{ .Values.pullPolicy }}", - "name": "vnfsdk-readiness" - } - ]' spec: + initContainers: + - command: + - /root/ready.py + args: + - --container-name + - postgres + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}" + imagePullPolicy: {{ .Values.pullPolicy }} + name: vnfsdk-readiness containers: - image: {{ .Values.image.refrepoImage }}:{{ .Values.image.refrepoVersion }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -53,4 +42,4 @@ spec: periodSeconds: 10 imagePullSecrets: - name: {{ .Values.nsPrefix }}-docker-registry-key -#{{ end }}
\ No newline at end of file +#{{ end }} |