From: Krzysztof Opasiak Date: Tue, 24 Nov 2020 17:23:01 +0000 (+0000) Subject: Merge "[AAF] externalizes init data out from aaf-cass image to chart" X-Git-Tag: 8.0.0~259 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=1a5966996b0b459fa3154cbe2845a5bfcdaf6d02;hp=a8c57a9bdb75a6778cae512ae83710ad8af361e4;p=oom.git Merge "[AAF] externalizes init data out from aaf-cass image to chart" --- diff --git a/kubernetes/aaf/components/aaf-cass/values.yaml b/kubernetes/aaf/components/aaf-cass/values.yaml index bec64d817c..f4d1d2eef0 100644 --- a/kubernetes/aaf/components/aaf-cass/values.yaml +++ b/kubernetes/aaf/components/aaf-cass/values.yaml @@ -17,13 +17,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-cm/values.yaml b/kubernetes/aaf/components/aaf-cm/values.yaml index 359a0f288a..e75abafb0e 100644 --- a/kubernetes/aaf/components/aaf-cm/values.yaml +++ b/kubernetes/aaf/components/aaf-cm/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-fs/values.yaml b/kubernetes/aaf/components/aaf-fs/values.yaml index 4180c522c9..c3750d4449 100644 --- a/kubernetes/aaf/components/aaf-fs/values.yaml +++ b/kubernetes/aaf/components/aaf-fs/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-gui/values.yaml b/kubernetes/aaf/components/aaf-gui/values.yaml index 99b5a4fb0d..247b1b5042 100644 --- a/kubernetes/aaf/components/aaf-gui/values.yaml +++ b/kubernetes/aaf/components/aaf-gui/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-locate/values.yaml b/kubernetes/aaf/components/aaf-locate/values.yaml index 67446c221f..e74893cd49 100644 --- a/kubernetes/aaf/components/aaf-locate/values.yaml +++ b/kubernetes/aaf/components/aaf-locate/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-oauth/values.yaml b/kubernetes/aaf/components/aaf-oauth/values.yaml index 13f275a43a..aad63df68a 100644 --- a/kubernetes/aaf/components/aaf-oauth/values.yaml +++ b/kubernetes/aaf/components/aaf-oauth/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-service/values.yaml b/kubernetes/aaf/components/aaf-service/values.yaml index 8406557ee0..2fd8a3bcd5 100644 --- a/kubernetes/aaf/components/aaf-service/values.yaml +++ b/kubernetes/aaf/components/aaf-service/values.yaml @@ -18,13 +18,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aaf/components/aaf-sshsm/values.yaml b/kubernetes/aaf/components/aaf-sshsm/values.yaml index bc08e59952..eee2bcf0aa 100644 --- a/kubernetes/aaf/components/aaf-sshsm/values.yaml +++ b/kubernetes/aaf/components/aaf-sshsm/values.yaml @@ -21,13 +21,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 # Standard OOM pullPolicy: "Always" diff --git a/kubernetes/aaf/values.yaml b/kubernetes/aaf/values.yaml index 2afdb422cb..df6aff5a04 100644 --- a/kubernetes/aaf/values.yaml +++ b/kubernetes/aaf/values.yaml @@ -23,13 +23,13 @@ global: # Readiness image readinessImage: onap/oom/readiness:3.0.1 # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 # Logging image loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 # BusyBox image - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:1.31 persistence: enabled: true diff --git a/kubernetes/aai b/kubernetes/aai index 9eef36ac7a..540b846831 160000 --- a/kubernetes/aai +++ b/kubernetes/aai @@ -1 +1 @@ -Subproject commit 9eef36ac7a12292e749104dd5a7fa17e35bdfecc +Subproject commit 540b846831e2053ccdcce9fa620cb7eeb7f5db46 diff --git a/kubernetes/cds/charts/cds-blueprints-processor/values.yaml b/kubernetes/cds/charts/cds-blueprints-processor/values.yaml index 1f61bc9309..6c5dfbb029 100755 --- a/kubernetes/cds/charts/cds-blueprints-processor/values.yaml +++ b/kubernetes/cds/charts/cds-blueprints-processor/values.yaml @@ -61,7 +61,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/ccsdk-blueprintsprocessor:1.0.1 +image: onap/ccsdk-blueprintsprocessor:1.0.3 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/cds/charts/cds-command-executor/values.yaml b/kubernetes/cds/charts/cds-command-executor/values.yaml index 01fcad805a..f7dc4cf427 100755 --- a/kubernetes/cds/charts/cds-command-executor/values.yaml +++ b/kubernetes/cds/charts/cds-command-executor/values.yaml @@ -39,7 +39,7 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/ccsdk-commandexecutor:1.0.1 +image: onap/ccsdk-commandexecutor:1.0.3 pullPolicy: Always # application configuration diff --git a/kubernetes/cds/charts/cds-py-executor/values.yaml b/kubernetes/cds/charts/cds-py-executor/values.yaml index decd1617cc..5bff0be083 100755 --- a/kubernetes/cds/charts/cds-py-executor/values.yaml +++ b/kubernetes/cds/charts/cds-py-executor/values.yaml @@ -37,7 +37,7 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/ccsdk-py-executor:1.0.1 +image: onap/ccsdk-py-executor:1.0.3 pullPolicy: Always # default number of instances diff --git a/kubernetes/cds/charts/cds-sdc-listener/values.yaml b/kubernetes/cds/charts/cds-sdc-listener/values.yaml index a0417c457a..c830d1d419 100644 --- a/kubernetes/cds/charts/cds-sdc-listener/values.yaml +++ b/kubernetes/cds/charts/cds-sdc-listener/values.yaml @@ -36,7 +36,7 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/ccsdk-sdclistener:1.0.1 +image: onap/ccsdk-sdclistener:1.0.3 name: sdc-listener pullPolicy: Always diff --git a/kubernetes/cds/charts/cds-ui/values.yaml b/kubernetes/cds/charts/cds-ui/values.yaml index f9049a68c0..496aa85fea 100644 --- a/kubernetes/cds/charts/cds-ui/values.yaml +++ b/kubernetes/cds/charts/cds-ui/values.yaml @@ -26,7 +26,7 @@ subChartsOnly: # application image repository: nexus3.onap.org:10001 -image: onap/ccsdk-cds-ui-server:1.0.1 +image: onap/ccsdk-cds-ui-server:1.0.3 pullPolicy: Always # application configuration diff --git a/kubernetes/clamp/components/clamp-backend/requirements.yaml b/kubernetes/clamp/components/clamp-backend/requirements.yaml index 08708fba14..5b041a56f2 100644 --- a/kubernetes/clamp/components/clamp-backend/requirements.yaml +++ b/kubernetes/clamp/components/clamp-backend/requirements.yaml @@ -15,5 +15,8 @@ dependencies: - name: certInitializer + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/clamp/components/clamp-backend/templates/deployment.yaml b/kubernetes/clamp/components/clamp-backend/templates/deployment.yaml index 1591efb8b4..9153f9d0ff 100644 --- a/kubernetes/clamp/components/clamp-backend/templates/deployment.yaml +++ b/kubernetes/clamp/components/clamp-backend/templates/deployment.yaml @@ -48,7 +48,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness {{ include "common.certInitializer.initContainer" . | indent 6 }} @@ -57,7 +57,7 @@ spec: {{ if .Values.global.centralizedLoggingEnabled }}{{ include "common.log.sidecar" . | nindent 8 }}{{ end }} # main container - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - sh diff --git a/kubernetes/clamp/components/clamp-backend/values.yaml b/kubernetes/clamp/components/clamp-backend/values.yaml index 6478809cbc..efd08ba4d0 100644 --- a/kubernetes/clamp/components/clamp-backend/values.yaml +++ b/kubernetes/clamp/components/clamp-backend/values.yaml @@ -18,8 +18,6 @@ ################################################################# global: # global defaults nodePortPrefix: 302 - repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ== - readinessImage: onap/oom/readiness:3.0.1 persistence: {} centralizedLoggingEnabled: true #AAF service @@ -65,8 +63,7 @@ secrets: flavor: small # application image -repository: nexus3.onap.org:10001 -image: onap/clamp-backend:5.1.4 +image: onap/clamp-backend:5.1.5 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/clamp/components/clamp-dash-es/requirements.yaml b/kubernetes/clamp/components/clamp-dash-es/requirements.yaml index 317d5b5d79..c388db3113 100644 --- a/kubernetes/clamp/components/clamp-dash-es/requirements.yaml +++ b/kubernetes/clamp/components/clamp-dash-es/requirements.yaml @@ -18,5 +18,8 @@ dependencies: version: ~6.x-0 repository: '@local' - name: certInitializer + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/clamp/components/clamp-dash-es/templates/deployment.yaml b/kubernetes/clamp/components/clamp-dash-es/templates/deployment.yaml index dcf011d315..d7aa77cd01 100644 --- a/kubernetes/clamp/components/clamp-dash-es/templates/deployment.yaml +++ b/kubernetes/clamp/components/clamp-dash-es/templates/deployment.yaml @@ -53,7 +53,7 @@ spec: fieldPath: metadata.namespace securityContext: privileged: true - image: {{ .Values.global.busyboxRepository | default .Values.busyboxRepository }}/{{ .Values.busyboxImage }} + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: init-sysctl volumeMounts: @@ -64,7 +64,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} {{- if .Values.global.aafEnabled }} command: diff --git a/kubernetes/clamp/components/clamp-dash-es/values.yaml b/kubernetes/clamp/components/clamp-dash-es/values.yaml index 04580a0354..1e2ae4778d 100644 --- a/kubernetes/clamp/components/clamp-dash-es/values.yaml +++ b/kubernetes/clamp/components/clamp-dash-es/values.yaml @@ -18,7 +18,6 @@ ################################################################# global: nodePortPrefix: 302 - repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ== persistence: {} centralizedLoggingEnabled: true #AAF service @@ -63,13 +62,7 @@ flavor: small ################################################################# # Application configuration defaults. ################################################################# - -# BusyBox image -busyboxRepository: registry.hub.docker.com -busyboxImage: library/busybox:latest - # application image -repository: nexus3.onap.org:10001 image: onap/clamp-dashboard-elasticsearch:5.0.4 pullPolicy: Always diff --git a/kubernetes/clamp/components/clamp-dash-kibana/requirements.yaml b/kubernetes/clamp/components/clamp-dash-kibana/requirements.yaml index 317d5b5d79..c388db3113 100644 --- a/kubernetes/clamp/components/clamp-dash-kibana/requirements.yaml +++ b/kubernetes/clamp/components/clamp-dash-kibana/requirements.yaml @@ -18,5 +18,8 @@ dependencies: version: ~6.x-0 repository: '@local' - name: certInitializer + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/clamp/components/clamp-dash-kibana/templates/deployment.yaml b/kubernetes/clamp/components/clamp-dash-kibana/templates/deployment.yaml index 99f0079831..8cb95cdf0b 100644 --- a/kubernetes/clamp/components/clamp-dash-kibana/templates/deployment.yaml +++ b/kubernetes/clamp/components/clamp-dash-kibana/templates/deployment.yaml @@ -48,13 +48,13 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/clamp/components/clamp-dash-kibana/values.yaml b/kubernetes/clamp/components/clamp-dash-kibana/values.yaml index 37dae0ffb1..9b5f1fc344 100644 --- a/kubernetes/clamp/components/clamp-dash-kibana/values.yaml +++ b/kubernetes/clamp/components/clamp-dash-kibana/values.yaml @@ -18,8 +18,6 @@ ################################################################# global: nodePortPrefix: 302 - repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ== - readinessImage: onap/oom/readiness:3.0.1 persistence: {} centralizedLoggingEnabled: true #AAF service @@ -64,13 +62,7 @@ flavor: small ################################################################# # Application configuration defaults. ################################################################# - -# BusyBox image -busyboxRepository: registry.hub.docker.com -busyboxImage: library/busybox:latest - # application image -repository: nexus3.onap.org:10001 image: onap/clamp-dashboard-kibana:5.0.4 pullPolicy: Always diff --git a/kubernetes/clamp/components/clamp-dash-logstash/requirements.yaml b/kubernetes/clamp/components/clamp-dash-logstash/requirements.yaml index 317d5b5d79..c388db3113 100644 --- a/kubernetes/clamp/components/clamp-dash-logstash/requirements.yaml +++ b/kubernetes/clamp/components/clamp-dash-logstash/requirements.yaml @@ -18,5 +18,8 @@ dependencies: version: ~6.x-0 repository: '@local' - name: certInitializer + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/clamp/components/clamp-dash-logstash/templates/deployment.yaml b/kubernetes/clamp/components/clamp-dash-logstash/templates/deployment.yaml index 9fd4c4095d..f098338c7f 100644 --- a/kubernetes/clamp/components/clamp-dash-logstash/templates/deployment.yaml +++ b/kubernetes/clamp/components/clamp-dash-logstash/templates/deployment.yaml @@ -48,13 +48,13 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: dmaap_consumer_group diff --git a/kubernetes/clamp/components/clamp-dash-logstash/values.yaml b/kubernetes/clamp/components/clamp-dash-logstash/values.yaml index 2b3c9f1712..9aab3af252 100644 --- a/kubernetes/clamp/components/clamp-dash-logstash/values.yaml +++ b/kubernetes/clamp/components/clamp-dash-logstash/values.yaml @@ -18,8 +18,6 @@ ################################################################# global: nodePortPrefix: 302 - repositorySecret: eyJuZXh1czMub25hcC5vcmc6MTAwMDEiOnsidXNlcm5hbWUiOiJkb2NrZXIiLCJwYXNzd29yZCI6ImRvY2tlciIsImVtYWlsIjoiQCIsImF1dGgiOiJaRzlqYTJWeU9tUnZZMnRsY2c9PSJ9fQ== - readinessImage: onap/oom/readiness:3.0.1 persistence: {} centralizedLoggingEnabled: true #AAF service @@ -66,7 +64,6 @@ flavor: small ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/clamp-dashboard-logstash:5.0.4 pullPolicy: Always diff --git a/kubernetes/clamp/components/clamp-mariadb/requirements.yaml b/kubernetes/clamp/components/clamp-mariadb/requirements.yaml index 9b96d0cfc4..b5d66f3805 100644 --- a/kubernetes/clamp/components/clamp-mariadb/requirements.yaml +++ b/kubernetes/clamp/components/clamp-mariadb/requirements.yaml @@ -14,5 +14,8 @@ dependencies: - name: common + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/clamp/components/clamp-mariadb/templates/deployment.yaml b/kubernetes/clamp/components/clamp-mariadb/templates/deployment.yaml index 6d30b3667d..8ddf584988 100644 --- a/kubernetes/clamp/components/clamp-mariadb/templates/deployment.yaml +++ b/kubernetes/clamp/components/clamp-mariadb/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/clamp/components/clamp-mariadb/values.yaml b/kubernetes/clamp/components/clamp-mariadb/values.yaml index f9a31b6b86..60b2cfef4f 100644 --- a/kubernetes/clamp/components/clamp-mariadb/values.yaml +++ b/kubernetes/clamp/components/clamp-mariadb/values.yaml @@ -21,7 +21,6 @@ global: # global defaults persistence: {} # application image -repository: docker.io image: mariadb:10.5.4 pullPolicy: Always flavor: small diff --git a/kubernetes/clamp/requirements.yaml b/kubernetes/clamp/requirements.yaml index dd93eaca2d..fd71422f78 100644 --- a/kubernetes/clamp/requirements.yaml +++ b/kubernetes/clamp/requirements.yaml @@ -17,6 +17,9 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: clamp-mariadb version: ~6.x-0 repository: 'file://components/clamp-mariadb' diff --git a/kubernetes/clamp/templates/deployment.yaml b/kubernetes/clamp/templates/deployment.yaml index 4c9bdb5b14..51b864b986 100644 --- a/kubernetes/clamp/templates/deployment.yaml +++ b/kubernetes/clamp/templates/deployment.yaml @@ -48,7 +48,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness {{ include "common.certInitializer.initContainer" . | nindent 6 }} @@ -57,7 +57,7 @@ spec: {{ if .Values.global.centralizedLoggingEnabled }}{{ include "common.log.sidecar" . | nindent 8 }}{{ end }} # main container - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/clamp/values.yaml b/kubernetes/clamp/values.yaml index 9dcad58839..b2b37d3755 100644 --- a/kubernetes/clamp/values.yaml +++ b/kubernetes/clamp/values.yaml @@ -18,9 +18,6 @@ ################################################################# global: # global defaults nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 centralizedLoggingEnabled: true #AAF service aafEnabled: true @@ -92,8 +89,7 @@ subChartsOnly: flavor: small # application image -repository: nexus3.onap.org:10001 -image: onap/clamp-frontend:5.1.4 +image: onap/clamp-frontend:5.1.5 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/common/Makefile b/kubernetes/common/Makefile index 817a2e24bc..43d62f1a82 100644 --- a/kubernetes/common/Makefile +++ b/kubernetes/common/Makefile @@ -20,11 +20,12 @@ SECRET_DIR := $(OUTPUT_DIR)/secrets COMMON_CHARTS_DIR := common EXCLUDES := -PROCESSED_LAST := cert-wrapper -TO_FILTER := $(EXCLUDES) $(PROCESSED_LAST) +PROCESSED_LAST := cert-wrapper repository-wrapper +PROCESSED_FIRST := repositoryGenerator certInitializer +TO_FILTER := $(PROCESSED_FIRST) $(EXCLUDES) $(PROCESSED_LAST) HELM_BIN := helm -HELM_CHARTS := $(filter-out $(TO_FILTER), $(sort $(patsubst %/.,%,$(wildcard */.)))) $(PROCESSED_LAST) +HELM_CHARTS := $(PROCESSED_FIRST) $(filter-out $(TO_FILTER), $(sort $(patsubst %/.,%,$(wildcard */.)))) $(PROCESSED_LAST) HELM_VER := $(shell $(HELM_BIN) version --template "{{.Version}}") .PHONY: $(HELM_CHARTS) $(TO_FILTER) diff --git a/kubernetes/common/common/documentation.rst b/kubernetes/common/common/documentation.rst index d982ab09c6..fd416c0cc8 100644 --- a/kubernetes/common/common/documentation.rst +++ b/kubernetes/common/common/documentation.rst @@ -77,8 +77,6 @@ only give an overview. +----------------------------------------------------+-----------------------+ | `common.repository` | `_repository.tpl` | +----------------------------------------------------+-----------------------+ - | `common.repository.secret` | `_repository.tpl` | - +----------------------------------------------------+-----------------------+ | `common.flavor` | `_resources.tpl` | +----------------------------------------------------+-----------------------+ | `common.resources` | `_resources.tpl` | @@ -289,7 +287,7 @@ taken on mariadb-galera): ... containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} ... Namespace diff --git a/kubernetes/common/common/templates/_repository.tpl b/kubernetes/common/common/templates/_repository.tpl index 272db42125..0316ae7050 100644 --- a/kubernetes/common/common/templates/_repository.tpl +++ b/kubernetes/common/common/templates/_repository.tpl @@ -15,6 +15,8 @@ */}} {{/* + /!\ DEPRECATED /!\ + Will be removed when transition to "repositoryGenerator" is finished. Resolve the name of the common image repository. The value for .Values.repository is used by default, unless either override mechanism is used. @@ -29,21 +31,3 @@ {{- default .Values.repository .Values.global.repository -}} {{end}} {{- end -}} - - -{{/* - Resolve the image repository secret token. - The value for .Values.global.repositoryCred is used: - repositoryCred: - user: user - password: password - mail: email (optional) -*/}} -{{- define "common.repository.secret" -}} - {{- $repo := include "common.repository" . }} - {{- $repo := default "nexus3.onap.org:10001" $repo }} - {{- $cred := .Values.global.repositoryCred }} - {{- $mail := default "@" $cred.mail }} - {{- $auth := printf "%s:%s" $cred.user $cred.password | b64enc }} - {{- printf "{\"%s\":{\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}}" $repo $cred.user $cred.password $mail $auth | b64enc -}} -{{- end -}} diff --git a/kubernetes/common/elasticsearch/components/data/values.yaml b/kubernetes/common/elasticsearch/components/data/values.yaml index a9e3d78ac1..8b5e687482 100644 --- a/kubernetes/common/elasticsearch/components/data/values.yaml +++ b/kubernetes/common/elasticsearch/components/data/values.yaml @@ -1,4 +1,5 @@ -# Copyright © 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Copyright (c) 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Modification Copyright (c) 2020 Nokia # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -46,7 +47,7 @@ service: - name: http-transport port: 9300 -image: bitnami/elasticsearch:7.6.1 +image: bitnami/elasticsearch:7.9.3 ## Specify a imagePullPolicy ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images diff --git a/kubernetes/common/elasticsearch/components/master/values.yaml b/kubernetes/common/elasticsearch/components/master/values.yaml index e59b4834f3..4095bd3d38 100644 --- a/kubernetes/common/elasticsearch/components/master/values.yaml +++ b/kubernetes/common/elasticsearch/components/master/values.yaml @@ -1,4 +1,5 @@ -# Copyright © 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Copyright (c) 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Modification Copyright (c) 2020 Nokia # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -42,7 +43,7 @@ replicaCount: 3 ## master acts as master only node, choose 'no' if no further data nodes are deployed) dedicatednode: 'yes' ## dedicatednode: "no" -image: bitnami/elasticsearch:7.6.1 +image: bitnami/elasticsearch:7.9.3 ## Specify a imagePullPolicy ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images diff --git a/kubernetes/common/elasticsearch/values.yaml b/kubernetes/common/elasticsearch/values.yaml index 31edcabfa1..7722af9215 100644 --- a/kubernetes/common/elasticsearch/values.yaml +++ b/kubernetes/common/elasticsearch/values.yaml @@ -1,4 +1,5 @@ -# Copyright © 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Copyright (c) 2020 Bitnami, AT&T, Amdocs, Bell Canada, highstreet technologies +# Modification Copyright (c) 2020 Nokia # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -21,7 +22,7 @@ global: readinessImage: onap/oom/readiness:3.0.1 loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:latest clusterName: cluster.local @@ -40,7 +41,7 @@ sysctlImage: enabled: true # application image -image: bitnami/elasticsearch:7.6.1 +image: bitnami/elasticsearch:7.9.3 ## Specify a imagePullPolicy ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images diff --git a/kubernetes/common/etcd/requirements.yaml b/kubernetes/common/etcd/requirements.yaml index e90e615d73..733bc449cb 100644 --- a/kubernetes/common/etcd/requirements.yaml +++ b/kubernetes/common/etcd/requirements.yaml @@ -16,3 +16,6 @@ dependencies: - name: common version: ~6.x-0 repository: 'file://../common' + - name: repositoryGenerator + version: ~6.x-0 + repository: 'file://../repositoryGenerator' diff --git a/kubernetes/common/etcd/templates/statefulset.yaml b/kubernetes/common/etcd/templates/statefulset.yaml index c45648f757..f5592bd252 100644 --- a/kubernetes/common/etcd/templates/statefulset.yaml +++ b/kubernetes/common/etcd/templates/statefulset.yaml @@ -50,7 +50,7 @@ spec: {{- end }} containers: - name: {{ include "common.fullname" . }} - image: "{{ .Values.repository }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.googleK8sRepository" . }}/{{ .Values.image }} imagePullPolicy: "{{ .Values.pullPolicy }}" ports: - containerPort: {{ .Values.service.peerInternalPort }} diff --git a/kubernetes/common/etcd/values.yaml b/kubernetes/common/etcd/values.yaml index d994f87ea4..3cfd4535f1 100644 --- a/kubernetes/common/etcd/values.yaml +++ b/kubernetes/common/etcd/values.yaml @@ -24,8 +24,7 @@ global: ################################################################# #repository: etcd -repository: "k8s.gcr.io" -image: "etcd-amd64:3.2.24" +image: etcd-amd64:3.2.24 pullPolicy: Always # default number of instances in the StatefulSet diff --git a/kubernetes/common/mariadb-galera/requirements.yaml b/kubernetes/common/mariadb-galera/requirements.yaml index 4fbecbfab2..2509f7fcff 100644 --- a/kubernetes/common/mariadb-galera/requirements.yaml +++ b/kubernetes/common/mariadb-galera/requirements.yaml @@ -15,4 +15,7 @@ dependencies: - name: common version: ~6.x-0 - repository: 'file://../common' \ No newline at end of file + repository: 'file://../common' + - name: repositoryGenerator + version: ~6.x-0 + repository: 'file://../repositoryGenerator' \ No newline at end of file diff --git a/kubernetes/common/mariadb-galera/resources/create-deployment.yml b/kubernetes/common/mariadb-galera/resources/create-deployment.yml index d81d640b0d..0f6bb5929e 100644 --- a/kubernetes/common/mariadb-galera/resources/create-deployment.yml +++ b/kubernetes/common/mariadb-galera/resources/create-deployment.yml @@ -13,7 +13,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.image }} ports: - containerPort: {{ .Values.service.internalPort }} name: {{ .Values.service.portName }} diff --git a/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml b/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml index bce0eb9c43..1c780179be 100644 --- a/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml +++ b/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml @@ -45,11 +45,11 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness - name: mariadb-galera-backup-init - image: "{{ include "common.repository" . }}/{{ .Values.backupImage }}" + image: {{ include "repositoryGenerator.image.mariadb" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /bin/bash @@ -94,7 +94,7 @@ spec: mountPath: /var/lib/mysql containers: - name: mariadb-backup-validate - image: "{{ include "common.repository" . }}/{{ .Values.backupImage }}" + image: {{ include "repositoryGenerator.image.mariadb" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: MYSQL_ROOT_PASSWORD diff --git a/kubernetes/common/mariadb-galera/templates/job.yaml b/kubernetes/common/mariadb-galera/templates/job.yaml index 5dc822a66f..250279ace2 100644 --- a/kubernetes/common/mariadb-galera/templates/job.yaml +++ b/kubernetes/common/mariadb-galera/templates/job.yaml @@ -14,7 +14,7 @@ spec: runAsUser: 1001 containers: - name: mariadb-job-pre-upgrade - image: {{ .Values.global.kubectlImage}} + image: {{ include "repositoryGenerator.image.kubectl" . }} imagePullPolicy: IfNotPresent env: - name: NAMESPACE_ENV @@ -49,7 +49,7 @@ spec: fsGroup: 1001 runAsUser: 0 initContainers: - - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + - image: {{ include "repositoryGenerator.image.readiness" . }} name: mariadb-galera-upgrade-readiness env: - name: NAMESPACE @@ -64,7 +64,7 @@ spec: - mariadb-galera containers: - name: mariadb-job-post-upgrade - image: {{ .Values.global.kubectlImage}} + image: {{ include "repositoryGenerator.image.kubectl" . }} imagePullPolicy: IfNotPresent env: - name: NAMESPACE_ENV @@ -99,7 +99,7 @@ spec: spec: containers: - name: mariadb-job-post-delete - image: {{ .Values.global.kubectlImage}} + image: {{ include "repositoryGenerator.image.kubectl" . }} imagePullPolicy: IfNotPresent command: ["/bin/bash", "-c", "--"] args: diff --git a/kubernetes/common/mariadb-galera/templates/statefulset.yaml b/kubernetes/common/mariadb-galera/templates/statefulset.yaml index 47d1e0ef3d..eb21fe3182 100644 --- a/kubernetes/common/mariadb-galera/templates/statefulset.yaml +++ b/kubernetes/common/mariadb-galera/templates/statefulset.yaml @@ -61,7 +61,7 @@ spec: - name: {{ include "common.namespace" . }}-docker-registry-key containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy | quote}} env: - name: POD_NAMESPACE @@ -119,7 +119,7 @@ spec: name: {{ include "common.fullname" . }}-data initContainers: - name: {{ include "common.name" . }}-prepare - image: "{{ include "common.repository" . }}/{{ .Values.imageInit }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy | quote}} command: ["sh", "-c", "chown -R 27:27 /var/lib/mysql"] volumeMounts: diff --git a/kubernetes/common/mariadb-galera/values.yaml b/kubernetes/common/mariadb-galera/values.yaml index 8a46098a21..6b1676fba7 100644 --- a/kubernetes/common/mariadb-galera/values.yaml +++ b/kubernetes/common/mariadb-galera/values.yaml @@ -38,23 +38,12 @@ global: backup: mountPath: /dockerdata-nfs/backup - repository: nexus3.onap.org:10001 - - readinessImage: onap/oom/readiness:3.0.1 - busyboxImage: busybox:1.30 - busyboxRepository: docker.io - # kubeclt image - kubectlImage: "bitnami/kubectl:1.15" - ################################################################# # Application configuration defaults. ################################################################# #repository: mysql -repository: nexus3.onap.org:10001 image: adfinissygroup/k8s-mariadb-galera-centos:v002 -backupImage: library/mariadb:10.1.38 -imageInit: busybox pullPolicy: IfNotPresent # application configuration @@ -131,10 +120,10 @@ ingress: ## Configure MariaDB-Galera with a custom my.cnf file ## ref: https://mariadb.com/kb/en/mariadb/configuring-mariadb-with-mycnf/#example-of-configuration-file ## -externalConfig: "" -# externalConfig: |- - # [mysqld] - # innodb_buffer_pool_size=2G +#externalConfig: "" +externalConfig: |- + [mysqld] + lower_case_table_names = 1 #resources: {} # We usually recommend not to specify default resources and to leave this as a conscious diff --git a/kubernetes/common/mariadb-init/requirements.yaml b/kubernetes/common/mariadb-init/requirements.yaml index 4fbecbfab2..2509f7fcff 100644 --- a/kubernetes/common/mariadb-init/requirements.yaml +++ b/kubernetes/common/mariadb-init/requirements.yaml @@ -15,4 +15,7 @@ dependencies: - name: common version: ~6.x-0 - repository: 'file://../common' \ No newline at end of file + repository: 'file://../common' + - name: repositoryGenerator + version: ~6.x-0 + repository: 'file://../repositoryGenerator' \ No newline at end of file diff --git a/kubernetes/common/mariadb-init/templates/configmap.yaml b/kubernetes/common/mariadb-init/templates/configmap.yaml index d021d60b8d..6708efdb60 100644 --- a/kubernetes/common/mariadb-init/templates/configmap.yaml +++ b/kubernetes/common/mariadb-init/templates/configmap.yaml @@ -27,3 +27,19 @@ metadata: heritage: {{ .Release.Service }} data: {{ tpl (.Files.Glob "resources/config/*").AsConfig . | indent 2 }} +--- +{{ if .Values.dbScript }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.fullname" . }}-dbscript + namespace: {{ include "common.namespace" . }} + labels: + app: {{ include "common.name" . }} + chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }} + release: {{ include "common.release" . }} + heritage: {{ .Release.Service }} +data: + db_cmd.sh: | + {{ tpl .Values.dbScript . | indent 4 }} +{{- end }} diff --git a/kubernetes/common/mariadb-init/templates/job.yaml b/kubernetes/common/mariadb-init/templates/job.yaml index cccb118787..ad97cd4ed6 100644 --- a/kubernetes/common/mariadb-init/templates/job.yaml +++ b/kubernetes/common/mariadb-init/templates/job.yaml @@ -49,15 +49,18 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.image.mariadb" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - - bash - - /db_init/db_init.sh + - /bin/sh + - -c + - | + /db_init/db_init.sh {{ if or .Values.dbScriptConfigMap .Values.dbScript }} && + /db_config/db_cmd.sh{{ end }} env: - name: DB_HOST value: "{{ default .Values.global.mariadbGalera.nameOverride .Values.mariadbGalera.serviceName }}" @@ -82,7 +85,10 @@ spec: readOnly: true - name: mariadb-conf mountPath: /db_init/ - readOnly: true +{{- if or .Values.dbScriptConfigMap .Values.dbScript }} + - name: mariadb-init + mountPath: /db_config/ +{{- end }} resources: {{ include "common.resources" . | indent 12 }} {{- if .Values.nodeSelector }} @@ -94,12 +100,23 @@ spec: {{ toYaml .Values.affinity | indent 10 }} {{- end }} volumes: - - name: mariadb-conf - configMap: - name: {{ include "mariadbInit.configMap" . }} - name: localtime hostPath: path: /etc/localtime +{{- if or .Values.dbScriptConfigMap .Values.dbScript }} + - name: mariadb-init + configMap: +{{- if .Values.dbScriptConfigMap }} + name: {{ tpl .Values.dbScriptConfigMap . }} +{{- else -}} + name: {{ include "common.fullname" . }}-dbscript +{{- end }} + defaultMode: 0755 +{{- end }} + - name: mariadb-conf + configMap: + name: {{ include "mariadbInit.configMap" . }} + defaultMode: 0755 restartPolicy: Never imagePullSecrets: - name: "{{ include "common.namespace" . }}-docker-registry-key" diff --git a/kubernetes/common/mariadb-init/values.yaml b/kubernetes/common/mariadb-init/values.yaml index dd5d208190..b2c0a05e46 100644 --- a/kubernetes/common/mariadb-init/values.yaml +++ b/kubernetes/common/mariadb-init/values.yaml @@ -16,8 +16,6 @@ # Global configuration defaults. ################################################################# global: - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 mariadbGalera: nameOverride: mariadb-galera servicePort: 3306 @@ -45,9 +43,15 @@ secrets: # Application configuration defaults. ################################################################# -image: mariadb:10.1.38 pullPolicy: IfNotPresent +# These two values are used to supply commands that are run after the DB is created. +# Components using the shared DB can either pass a string which has a set of commands +# or a config map that contains a shell script. If both are specified only the config +# map will be executed. For reference, please see the VID components for config map +dbScript: "" +dbScriptConfigMap: "" + # Set it if you want to change the name of the different components # nameOverride: diff --git a/kubernetes/common/mongo/requirements.yaml b/kubernetes/common/mongo/requirements.yaml index 6ba617e990..09c09d698b 100644 --- a/kubernetes/common/mongo/requirements.yaml +++ b/kubernetes/common/mongo/requirements.yaml @@ -16,3 +16,6 @@ dependencies: - name: common version: ~6.x-0 repository: 'file://../common' + - name: repositoryGenerator + version: ~6.x-0 + repository: 'file://../repositoryGenerator' diff --git a/kubernetes/common/mongo/templates/statefulset.yaml b/kubernetes/common/mongo/templates/statefulset.yaml index df922ed004..73186b392d 100644 --- a/kubernetes/common/mongo/templates/statefulset.yaml +++ b/kubernetes/common/mongo/templates/statefulset.yaml @@ -39,7 +39,7 @@ spec: {{ include "common.podSecurityContext" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ .Values.dockerHubRepository }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - docker-entrypoint.sh diff --git a/kubernetes/common/mongo/values.yaml b/kubernetes/common/mongo/values.yaml index b21b0bf758..ee1d8c72fa 100644 --- a/kubernetes/common/mongo/values.yaml +++ b/kubernetes/common/mongo/values.yaml @@ -18,14 +18,12 @@ global: nodePortPrefix: 302 persistence: {} - readinessImage: onap/oom/readiness:3.0.1 ################################################################# # Application configuration defaults. ################################################################# -dockerHubRepository: registry.hub.docker.com image: library/mongo:4.0.8 pullPolicy: Always diff --git a/kubernetes/common/postgres/values.yaml b/kubernetes/common/postgres/values.yaml index b653ba1a41..34e9d9137a 100644 --- a/kubernetes/common/postgres/values.yaml +++ b/kubernetes/common/postgres/values.yaml @@ -46,7 +46,7 @@ secrets: ################################################################# # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest postgresRepository: crunchydata diff --git a/kubernetes/common/repository-wrapper/Chart.yaml b/kubernetes/common/repository-wrapper/Chart.yaml new file mode 100644 index 0000000000..7f48d16877 --- /dev/null +++ b/kubernetes/common/repository-wrapper/Chart.yaml @@ -0,0 +1,18 @@ +# 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 +description: Wrapper chart to allow docker secret to be shared all instances +name: repository-wrapper +version: 6.0.0 diff --git a/kubernetes/common/repository-wrapper/requirements.yaml b/kubernetes/common/repository-wrapper/requirements.yaml new file mode 100644 index 0000000000..02d40a57d9 --- /dev/null +++ b/kubernetes/common/repository-wrapper/requirements.yaml @@ -0,0 +1,21 @@ +# Copyright © 2018 Amdocs, Bell Canada +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +dependencies: + - name: common + version: ~6.x-0 + repository: 'file://../common' + - name: repositoryGenerator + version: ~6.x-0 + repository: 'file://../repositoryGenerator' diff --git a/kubernetes/onap/templates/secrets.yaml b/kubernetes/common/repository-wrapper/templates/secrets.yaml similarity index 94% rename from kubernetes/onap/templates/secrets.yaml rename to kubernetes/common/repository-wrapper/templates/secrets.yaml index 725b6d1d41..21b56fadcd 100644 --- a/kubernetes/onap/templates/secrets.yaml +++ b/kubernetes/common/repository-wrapper/templates/secrets.yaml @@ -25,5 +25,5 @@ metadata: release: {{ include "common.release" . }} heritage: {{ .Release.Service }} data: - .dockercfg: {{ include "common.repository.secret" . }} + .dockercfg: {{ include "repositoryGenerator.secret" . }} type: kubernetes.io/dockercfg diff --git a/kubernetes/common/repository-wrapper/values.yaml b/kubernetes/common/repository-wrapper/values.yaml new file mode 100644 index 0000000000..66f679c830 --- /dev/null +++ b/kubernetes/common/repository-wrapper/values.yaml @@ -0,0 +1,15 @@ +# Copyright © 2020 Orange +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +global: {} \ No newline at end of file diff --git a/kubernetes/common/repositoryGenerator/Chart.yaml b/kubernetes/common/repositoryGenerator/Chart.yaml new file mode 100644 index 0000000000..5ff53fa3d4 --- /dev/null +++ b/kubernetes/common/repositoryGenerator/Chart.yaml @@ -0,0 +1,18 @@ +# 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 +description: Template used to generate the right repository link +name: repositoryGenerator +version: 6.0.0 diff --git a/kubernetes/common/repositoryGenerator/requirements.yaml b/kubernetes/common/repositoryGenerator/requirements.yaml new file mode 100644 index 0000000000..70ab2ecce6 --- /dev/null +++ b/kubernetes/common/repositoryGenerator/requirements.yaml @@ -0,0 +1,14 @@ +# Copyright © 2018 Amdocs, Bell Canada +# Copyright © 2020 Orange +# +# 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. diff --git a/kubernetes/common/repositoryGenerator/templates/_repository.tpl b/kubernetes/common/repositoryGenerator/templates/_repository.tpl new file mode 100644 index 0000000000..c351db1ba0 --- /dev/null +++ b/kubernetes/common/repositoryGenerator/templates/_repository.tpl @@ -0,0 +1,177 @@ +{{/* +# 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. +*/}} + +{{- define "repositoryGenerator._repositoryHelper" -}} + {{- $dot := default . .dot -}} + {{- $initRoot := default $dot.Values.repositoryGenerator .initRoot -}} + {{- $repoName := .repoName }} + {{- $overrideName := printf "%s%s" $repoName "Override" }} + {{- if (hasKey $dot.Values $overrideName) -}} + {{- printf "%s" (first (pluck $overrideName $dot.Values)) -}} + {{- else -}} + {{- first (pluck $repoName $dot.Values.global $initRoot.global) -}} + {{- end }} +{{- end -}} + +{{/* + Resolve the name of the common image repository. + + - .Values.global.repository : default image repository for all ONAP images + - .Values.repositoryOverride : override global repository on a per chart basis +*/}} +{{- define "repositoryGenerator.repository" -}} + {{- include "repositoryGenerator._repositoryHelper" (merge (dict "repoName" "repository") .) }} +{{- end -}} + +{{/* + Resolve the name of the dockerHub image repository. + + - .Values.global.dockerHubRepository : default image dockerHubRepository for all dockerHub images + - .Values.dockerHubRepositoryOverride : override global dockerHub repository on a per chart basis +*/}} +{{- define "repositoryGenerator.dockerHubRepository" -}} + {{- include "repositoryGenerator._repositoryHelper" (merge (dict "repoName" "dockerHubRepository") .) }} +{{- end -}} + +{{/* + Resolve the name of the elasticRepository image repository. + + - .Values.global.elasticRepository : default image elasticRepository for all images using elastic repository + - .Values.elasticRepositoryOverride : override global elasticRepository repository on a per chart basis +*/}} +{{- define "repositoryGenerator.elasticRepository" -}} + {{- include "repositoryGenerator._repositoryHelper" (merge (dict "repoName" "elasticRepository") .) }} +{{- end -}} + +{{/* + Resolve the name of the googleK8sRepository image repository. + + - .Values.global.googleK8sRepository : default image dockerHubRepository for all dockerHub images + - .Values.googleK8sRepositoryOverride : override global dockerHub repository on a per chart basis +*/}} +{{- define "repositoryGenerator.googleK8sRepository" -}} + {{- include "repositoryGenerator._repositoryHelper" (merge (dict "repoName" "googleK8sRepository") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image._helper" -}} + {{- $dot := default . .dot -}} + {{- $initRoot := default $dot.Values.repositoryGenerator .initRoot -}} + {{- $image := .image }} + {{- $repoName := first (pluck $image $initRoot.imageRepoMapping) }} + {{- include "repositoryGenerator._repositoryHelper" (merge (dict "repoName" $repoName ) .) }}/{{- first (pluck $image $dot.Values.global $initRoot.global) -}} +{{- end -}} + +{{- define "repositoryGenerator.image.busybox" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "busyboxImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.curl" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "curlImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.envsubst" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "envsubstImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.htpasswd" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "htpasswdImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.kubectl" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "kubectlImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.logging" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "loggingImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.mariadb" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "mariadbImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.nginx" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "nginxImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.postgres" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "postgresImage") .) }} +{{- end -}} + +{{- define "repositoryGenerator.image.readiness" -}} + {{- include "repositoryGenerator.image._helper" (merge (dict "image" "readinessImage") .) }} +{{- end -}} + +{{/* + Resolve the image repository secret token. + The value for .Values.global.repositoryCred is used if provided: + repositoryCred: + user: user + password: password + mail: email (optional) + You can also set the same things for dockerHub, elastic and googleK8s if + needed. +*/}} +{{- define "repositoryGenerator.secret" -}} + {{- $dot := default . .dot -}} + {{- $initRoot := default $dot.Values.repositoryGenerator .initRoot -}} + {{/* Our version of helm doesn't support deepCopy so we need this nasty trick */}} + {{- $subchartDot := fromJson (include "common.subChartDot" (dict "dot" $dot "initRoot" $initRoot)) }} + {{- $repoCreds := "" }} + {{- if $subchartDot.Values.global.dockerHubRepositoryCred }} + {{- $repo := $subchartDot.Values.global.repository }} + {{- $cred := $subchartDot.Values.global.repositoryCred }} + {{- $mail := default "@" $cred.mail }} + {{- $auth := printf "%s:%s" $cred.user $cred.password | b64enc }} + {{- $repoCreds = printf "\"%s\": {\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}" $repo $cred.user $cred.password $mail $auth }} + {{- end }} + {{- if $subchartDot.Values.global.dockerHubRepositoryCred }} + {{- $dhRepo := $subchartDot.Values.global.dockerHubRepository }} + {{- $dhCred := $subchartDot.Values.global.dockerHubRepositoryCred }} + {{- $dhMail := default "@" $dhCred.mail }} + {{- $dhAuth := printf "%s:%s" $dhCred.user $dhCred.password | b64enc }} + {{- $dhRepoCreds := printf "\"%s\":{\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}" $dhRepo $dhCred.user $dhCred.password $dhMail $dhAuth }} + {{- if eq "" $repoCreds }} + {{- $repoCreds = $dhRepoCreds }} + {{- else }} + {{- $repoCreds = printf "%s, %s" $repoCreds $dhRepoCreds }} + {{- end }} + {{- end }} + {{- if $subchartDot.Values.global.elasticRepositoryCred }} + {{- $eRepo := $subchartDot.Values.global.elasticRepository }} + {{- $eCred := $subchartDot.Values.global.elasticRepositoryCred }} + {{- $eMail := default "@" $eCred.mail }} + {{- $eAuth := printf "%s:%s" $eCred.user $eCred.password | b64enc }} + {{- $eRepoCreds := printf "\"%s\":{\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}" $eRepo $eCred.user $eCred.password $eMail $eAuth }} + {{- if eq "" $repoCreds }} + {{- $repoCreds = $eRepoCreds }} + {{- else }} + {{- $repoCreds = printf "%s, %s" $repoCreds $eRepoCreds }} + {{- end }} + {{- end }} + {{- if $subchartDot.Values.global.googleK8sRepositoryCred }} + {{- $gcrRepo := $subchartDot.Values.global.googleK8sRepository }} + {{- $gcrCred := $subchartDot.Values.global.googleK8sRepositoryCred }} + {{- $gcrMail := default "@" $gcrCred.mail }} + {{- $gcrAuth := printf "%s:%s" $gcrCred.user $gcrCred.password | b64enc }} + {{- $gcrRepoCreds := printf "\"%s\":{\"username\":\"%s\",\"password\":\"%s\",\"email\":\"%s\",\"auth\":\"%s\"}" $gcrRepo $gcrCred.user $gcrCred.password $gcrMail $gcrAuth }} + {{- if eq "" $repoCreds }} + {{- $repoCreds = $gcrRepoCreds }} + {{- else }} + {{- $repoCreds = printf "%s, %s" $repoCreds $gcrRepoCreds }} + {{- end }} + {{- end }} + {{- printf "{%s}" $repoCreds | b64enc -}} +{{- end -}} diff --git a/kubernetes/common/repositoryGenerator/values.yaml b/kubernetes/common/repositoryGenerator/values.yaml new file mode 100644 index 0000000000..1ec3a35bd9 --- /dev/null +++ b/kubernetes/common/repositoryGenerator/values.yaml @@ -0,0 +1,62 @@ +# Copyright © 2020 Orange +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +global: + # Repositories used + repository: nexus3.onap.org:10001 + dockerHubRepository: docker.io + elasticRepository: docker.elastic.co + googleK8sRepository: k8s.gcr.io + + # common global images + busyboxImage: busybox:1.32 + curlImage: curlimages/curl:7.69.1 + envsubstImage: dibi/envsubst:1 + # there's only latest image for htpasswd + htpasswdImage: xmartlabs/htpasswd:latest + kubectlImage: bitnami/kubectl:1.19 + loggingImage: beats/filebeat:5.5.0 + mariadbImage: mariadb:10.1.48 + nginxImage: bitnami/nginx:1.18-debian-10 + postgresImage: crunchydata/crunchy-postgres:centos7-10.11-4.2.1 + readinessImage: onap/oom/readiness:3.0.1 + + # Default credentials + # they're optional. If the target repository doesn't need them, comment them + repositoryCred: + user: docker + password: docker + # If you want / need authentication on the repositories, please set + # Don't set them if the target repo is the same than others + # dockerHubCred: + # user: myuser + # password: mypassord + # elasticCred: + # user: myuser + # password: mypassord + # googleK8sCred: + # user: myuser + # password: mypassord + +imageRepoMapping: + busyboxImage: dockerHubRepository + curlImage: dockerHubRepository + envsubstImage: dockerHubRepository + htpasswdImage: dockerHubRepository + kubectlImage: dockerHubRepository + loggingImage: elasticRepository + mariadbImage: dockerHubRepository + nginxImage: dockerHubRepository + postgresImage: dockerHubRepository + readinessImage: repository diff --git a/kubernetes/consul/templates/deployment.yaml b/kubernetes/consul/templates/deployment.yaml index 6f1c57967f..51c6eb72d5 100644 --- a/kubernetes/consul/templates/deployment.yaml +++ b/kubernetes/consul/templates/deployment.yaml @@ -39,34 +39,15 @@ spec: spec: imagePullSecrets: - name: "{{ include "common.namespace" . }}-docker-registry-key" - initContainers: - - name: {{ include "common.name" . }}-chown - image: {{ .Values.global.busyboxRepository | default .Values.busyboxRepository }}/{{ .Values.global.busyboxImage | default .Values.busyboxImage }} - command: - - sh - args: - - -c - - | - cp -r -L /tmp/consul/config/* /consul/config/ - chown -R {{ .Values.consulUID }}:{{ .Values.consulGID }} /consul/config - ls -la /consul/config - volumeMounts: - - mountPath: /tmp/consul/config - name: consul-agent-config - - mountPath: /consul/config - name: consul-agent-config-dir containers: - image: "{{ include "common.repository" . }}/{{ .Values.image }}" command: - - sh - args: - - /usr/local/bin/docker-entrypoint.sh - - agent - - -client - - 0.0.0.0 - - -enable-script-checks - - -retry-join - - {{ .Values.consulServer.nameOverride }} + - /bin/sh + - "-c" + - | + apk update && apk add jq + cp /tmp/consul/config/* /consul/config + /usr/local/bin/docker-entrypoint.sh agent -client 0.0.0.0 -enable-script-checks -retry-join {{ .Values.consulServer.nameOverride }} name: {{ include "common.name" . }} env: - name: SDNC_ODL_COUNT @@ -74,16 +55,14 @@ spec: - name: SDNC_IS_PRIMARY_CLUSTER value: "{{ .Values.sdnc.config.isPrimaryCluster }}" volumeMounts: - - mountPath: /consul/config - name: consul-agent-config-dir + - mountPath: /tmp/consul/config + name: consul-agent-config - mountPath: /consul/scripts name: consul-agent-scripts-config - mountPath: /consul/certs name: consul-agent-certs-config resources: {{ include "common.resources" . | nindent 10 }} volumes: - - name: consul-agent-config-dir - emptyDir: {} - configMap: name: {{ include "common.fullname" . }}-configmap name: consul-agent-config diff --git a/kubernetes/consul/values.yaml b/kubernetes/consul/values.yaml index 8f17dc637f..512c4c3dac 100644 --- a/kubernetes/consul/values.yaml +++ b/kubernetes/consul/values.yaml @@ -20,24 +20,19 @@ global: readinessImage: onap/oom/readiness:3.0.1 loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 - busyboxRepository: registry.hub.docker.com - busyboxImage: library/busybox:latest ################################################################# # Application configuration defaults. ################################################################# # application image repository: docker.io -image: oomk8s/consul:2.0.0 +image: oomk8s/consul:1.0.0 pullPolicy: Always #subchart name consulServer: nameOverride: consul-server -consulUID: 100 -consulGID: 1000 - # flag to enable debugging - application support required debugEnabled: false diff --git a/kubernetes/contrib/components/ejbca/templates/deployment.yaml b/kubernetes/contrib/components/ejbca/templates/deployment.yaml index 3034366b1a..55de54febf 100644 --- a/kubernetes/contrib/components/ejbca/templates/deployment.yaml +++ b/kubernetes/contrib/components/ejbca/templates/deployment.yaml @@ -89,6 +89,7 @@ spec: {{- if .Values.affinity }} affinity: {{ toYaml .Values.affinity | nindent 10 }} {{- end }} + resources: {{ include "common.resources" . | nindent 10 }} volumes: - configMap: name: "{{ include "common.fullname" . }}-config-script" diff --git a/kubernetes/contrib/components/ejbca/values.yaml b/kubernetes/contrib/components/ejbca/values.yaml index 1a9a34bcd1..35160e4b13 100644 --- a/kubernetes/contrib/components/ejbca/values.yaml +++ b/kubernetes/contrib/components/ejbca/values.yaml @@ -13,7 +13,7 @@ # limitations under the License. global: readinessImage: onap/oom/readiness:3.0.1 - mariadbGalera: &mariadbGalera + mariadbGalera: &mariadbGalera #This flag allows EJBCA to instantiate its own mariadb-galera cluster localCluster: false service: mariadb-galera @@ -104,3 +104,23 @@ service: port: 8443 plain_port: 8080 port_protocol: http + +# Resource Limit flavor -By Default using small +flavor: small +# Segregation for Different environment (Small and Large) +resources: + small: + limits: + cpu: 1500m + memory: 1536Mi + requests: + cpu: 10m + memory: 750Mi + large: + limits: + cpu: 2 + memory: 2Gi + requests: + cpu: 20m + memory: 1Gi + unlimited: {} diff --git a/kubernetes/dcaegen2/components/dcae-bootstrap/resources/inputs/k8s-ves-inputs.yaml b/kubernetes/dcaegen2/components/dcae-bootstrap/resources/inputs/k8s-ves-inputs.yaml index e2caf1e51b..3c4e9d95e8 100644 --- a/kubernetes/dcaegen2/components/dcae-bootstrap/resources/inputs/k8s-ves-inputs.yaml +++ b/kubernetes/dcaegen2/components/dcae-bootstrap/resources/inputs/k8s-ves-inputs.yaml @@ -25,9 +25,9 @@ tag_version: {{ include "common.repository" . }}/{{ .Values.componentImages.ves external_port_tls: 0 external_port: {{ .Values.config.address.ves.port }} auth_method: "noAuth" -service_component_type: "dcae-ves-collector-http" -service_id: "dcae-ves-collector-http" -service_component_name_override: "dcae-ves-collector-http" +service_component_type: "dcae-http-ves-collector" +service_id: "dcae-http-ves-collector-http" +service_component_name_override: "dcae-http-ves-collector" ves_other_publish_url: "http://{{ .Values.config.address.message_router }}:3904/events/unauthenticated.SEC_OTHER_OUTPUT/" ves_heartbeat_publish_url: "http://{{ .Values.config.address.message_router }}:3904/events/unauthenticated.SEC_HEARTBEAT_OUTPUT/" ves_fault_publish_url: "http://{{ .Values.config.address.message_router }}:3904/events/unauthenticated.SEC_FAULT_OUTPUT/" diff --git a/kubernetes/dmaap/components/message-router/charts/message-router-kafka/values.yaml b/kubernetes/dmaap/components/message-router/charts/message-router-kafka/values.yaml index 7ab719c31b..ec16876601 100644 --- a/kubernetes/dmaap/components/message-router/charts/message-router-kafka/values.yaml +++ b/kubernetes/dmaap/components/message-router/charts/message-router-kafka/values.yaml @@ -22,7 +22,7 @@ global: loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 persistence: {} - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io envsubstImage: dibi/envsubst ################################################################# diff --git a/kubernetes/dmaap/components/message-router/charts/message-router-zookeeper/values.yaml b/kubernetes/dmaap/components/message-router/charts/message-router-zookeeper/values.yaml index 44259a0fe4..dc19cd09a7 100644 --- a/kubernetes/dmaap/components/message-router/charts/message-router-zookeeper/values.yaml +++ b/kubernetes/dmaap/components/message-router/charts/message-router-zookeeper/values.yaml @@ -21,7 +21,7 @@ global: readinessImage: onap/oom/readiness:3.0.1 loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io persistence: {} envsubstImage: dibi/envsubst diff --git a/kubernetes/esr/Makefile b/kubernetes/esr/Makefile new file mode 100644 index 0000000000..4c79718d02 --- /dev/null +++ b/kubernetes/esr/Makefile @@ -0,0 +1,51 @@ +# Copyright © 2020 Samsung Electronics +# +# 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. + +ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST)))) +OUTPUT_DIR := $(ROOT_DIR)/../dist +PACKAGE_DIR := $(OUTPUT_DIR)/packages +SECRET_DIR := $(OUTPUT_DIR)/secrets + +EXCLUDES := dist resources templates charts docker +HELM_BIN := helm +HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.)))) + +.PHONY: $(EXCLUDES) $(HELM_CHARTS) + +all: $(HELM_CHARTS) + +$(HELM_CHARTS): + @echo "\n[$@]" + @make package-$@ + +make-%: + @if [ -f $*/Makefile ]; then make -C $*; fi + +dep-%: make-% + @if [ -f $*/requirements.yaml ]; then $(HELM_BIN) dep up $*; fi + +lint-%: dep-% + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) lint $*; fi + +package-%: lint-% + @mkdir -p $(PACKAGE_DIR) + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) package -d $(PACKAGE_DIR) $*; fi + @$(HELM_BIN) repo index $(PACKAGE_DIR) + +clean: + @rm -f */requirements.lock + @rm -f *tgz */charts/*tgz + @rm -rf $(PACKAGE_DIR) +%: + @: diff --git a/kubernetes/esr/components/Makefile b/kubernetes/esr/components/Makefile new file mode 100644 index 0000000000..bf267b7720 --- /dev/null +++ b/kubernetes/esr/components/Makefile @@ -0,0 +1,51 @@ +# Copyright © 2020 Samsung Electronics +# +# 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. + +ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST)))) +OUTPUT_DIR := $(ROOT_DIR)/../../dist +PACKAGE_DIR := $(OUTPUT_DIR)/packages +SECRET_DIR := $(OUTPUT_DIR)/secrets + +EXCLUDES := +HELM_BIN := helm +HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.)))) + +.PHONY: $(EXCLUDES) $(HELM_CHARTS) + +all: $(HELM_CHARTS) + +$(HELM_CHARTS): + @echo "\n[$@]" + @make package-$@ + +make-%: + @if [ -f $*/Makefile ]; then make -C $*; fi + +dep-%: make-% + @if [ -f $*/requirements.yaml ]; then $(HELM_BIN) dep up $*; fi + +lint-%: dep-% + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) lint $*; fi + +package-%: lint-% + @mkdir -p $(PACKAGE_DIR) + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) package -d $(PACKAGE_DIR) $*; fi + @$(HELM_BIN) repo index $(PACKAGE_DIR) + +clean: + @rm -f */requirements.lock + @rm -f *tgz */charts/*tgz + @rm -rf $(PACKAGE_DIR) +%: + @: diff --git a/kubernetes/esr/charts/esr-gui/.helmignore b/kubernetes/esr/components/esr-gui/.helmignore similarity index 100% rename from kubernetes/esr/charts/esr-gui/.helmignore rename to kubernetes/esr/components/esr-gui/.helmignore diff --git a/kubernetes/esr/charts/esr-gui/Chart.yaml b/kubernetes/esr/components/esr-gui/Chart.yaml similarity index 100% rename from kubernetes/esr/charts/esr-gui/Chart.yaml rename to kubernetes/esr/components/esr-gui/Chart.yaml diff --git a/kubernetes/esr/charts/esr-server/requirements.yaml b/kubernetes/esr/components/esr-gui/requirements.yaml similarity index 80% rename from kubernetes/esr/charts/esr-server/requirements.yaml rename to kubernetes/esr/components/esr-gui/requirements.yaml index a999e38749..0b77abe706 100644 --- a/kubernetes/esr/charts/esr-server/requirements.yaml +++ b/kubernetes/esr/components/esr-gui/requirements.yaml @@ -1,4 +1,5 @@ -# Copyright © 2018 Amdocs, Bell Canada +# Copyright © 2017 Amdocs, Bell Canada +# Modifications Copyright © 2018 AT&T # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -18,4 +19,7 @@ dependencies: # local reference to common chart, as it is # a part of this chart's package and will not # be published independently to a repo (at this point) - repository: '@local' \ No newline at end of file + repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/esr/charts/esr-gui/templates/NOTES.txt b/kubernetes/esr/components/esr-gui/templates/NOTES.txt similarity index 100% rename from kubernetes/esr/charts/esr-gui/templates/NOTES.txt rename to kubernetes/esr/components/esr-gui/templates/NOTES.txt diff --git a/kubernetes/esr/charts/esr-gui/templates/deployment.yaml b/kubernetes/esr/components/esr-gui/templates/deployment.yaml similarity index 95% rename from kubernetes/esr/charts/esr-gui/templates/deployment.yaml rename to kubernetes/esr/components/esr-gui/templates/deployment.yaml index 985f4a1b2d..74f933572f 100644 --- a/kubernetes/esr/charts/esr-gui/templates/deployment.yaml +++ b/kubernetes/esr/components/esr-gui/templates/deployment.yaml @@ -50,7 +50,7 @@ spec: - /opt/tomcat securityContext: privileged: true - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: create-tomcat-dir volumeMounts: @@ -59,7 +59,7 @@ spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/esr/charts/esr-gui/templates/service.yaml b/kubernetes/esr/components/esr-gui/templates/service.yaml similarity index 100% rename from kubernetes/esr/charts/esr-gui/templates/service.yaml rename to kubernetes/esr/components/esr-gui/templates/service.yaml diff --git a/kubernetes/esr/charts/esr-gui/values.yaml b/kubernetes/esr/components/esr-gui/values.yaml similarity index 98% rename from kubernetes/esr/charts/esr-gui/values.yaml rename to kubernetes/esr/components/esr-gui/values.yaml index a191739948..417ace5ab4 100644 --- a/kubernetes/esr/charts/esr-gui/values.yaml +++ b/kubernetes/esr/components/esr-gui/values.yaml @@ -23,7 +23,6 @@ global: # Application configuration defaults. ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/aai/esr-gui:1.4.0 pullPolicy: Always msbaddr: msb-iag.{{ include "common.namespace" . }}:443 diff --git a/kubernetes/esr/charts/esr-server/Chart.yaml b/kubernetes/esr/components/esr-server/Chart.yaml similarity index 100% rename from kubernetes/esr/charts/esr-server/Chart.yaml rename to kubernetes/esr/components/esr-server/Chart.yaml diff --git a/kubernetes/esr/components/esr-server/requirements.yaml b/kubernetes/esr/components/esr-server/requirements.yaml new file mode 100644 index 0000000000..0b77abe706 --- /dev/null +++ b/kubernetes/esr/components/esr-server/requirements.yaml @@ -0,0 +1,25 @@ +# Copyright © 2017 Amdocs, Bell Canada +# Modifications Copyright © 2018 AT&T +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +dependencies: + - name: common + version: ~6.x-0 + # local reference to common chart, as it is + # a part of this chart's package and will not + # be published independently to a repo (at this point) + repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/esr/charts/esr-server/resources/config/log/filebeat/filebeat.yml b/kubernetes/esr/components/esr-server/resources/config/log/filebeat/filebeat.yml similarity index 100% rename from kubernetes/esr/charts/esr-server/resources/config/log/filebeat/filebeat.yml rename to kubernetes/esr/components/esr-server/resources/config/log/filebeat/filebeat.yml diff --git a/kubernetes/esr/charts/esr-server/resources/config/logback.xml b/kubernetes/esr/components/esr-server/resources/config/logback.xml similarity index 100% rename from kubernetes/esr/charts/esr-server/resources/config/logback.xml rename to kubernetes/esr/components/esr-server/resources/config/logback.xml diff --git a/kubernetes/esr/charts/esr-server/templates/NOTES.txt b/kubernetes/esr/components/esr-server/templates/NOTES.txt similarity index 100% rename from kubernetes/esr/charts/esr-server/templates/NOTES.txt rename to kubernetes/esr/components/esr-server/templates/NOTES.txt diff --git a/kubernetes/esr/charts/esr-server/templates/configmap.yaml b/kubernetes/esr/components/esr-server/templates/configmap.yaml similarity index 100% rename from kubernetes/esr/charts/esr-server/templates/configmap.yaml rename to kubernetes/esr/components/esr-server/templates/configmap.yaml diff --git a/kubernetes/esr/charts/esr-server/templates/deployment.yaml b/kubernetes/esr/components/esr-server/templates/deployment.yaml similarity index 95% rename from kubernetes/esr/charts/esr-server/templates/deployment.yaml rename to kubernetes/esr/components/esr-server/templates/deployment.yaml index e8dd5cd12c..03bcaa09d4 100644 --- a/kubernetes/esr/charts/esr-server/templates/deployment.yaml +++ b/kubernetes/esr/components/esr-server/templates/deployment.yaml @@ -50,7 +50,7 @@ spec: - /opt/conf securityContext: privileged: true - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: create-conf-dir volumeMounts: @@ -59,7 +59,7 @@ spec: containers: - name: {{ .Chart.Name }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} @@ -103,7 +103,7 @@ spec: securityContext: runAsUser: 1000 runAsGroup: 1000 - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/esr/charts/esr-server/templates/service.yaml b/kubernetes/esr/components/esr-server/templates/service.yaml similarity index 100% rename from kubernetes/esr/charts/esr-server/templates/service.yaml rename to kubernetes/esr/components/esr-server/templates/service.yaml diff --git a/kubernetes/esr/charts/esr-server/values.yaml b/kubernetes/esr/components/esr-server/values.yaml similarity index 94% rename from kubernetes/esr/charts/esr-server/values.yaml rename to kubernetes/esr/components/esr-server/values.yaml index 0177690e80..a3fb6862a6 100644 --- a/kubernetes/esr/charts/esr-server/values.yaml +++ b/kubernetes/esr/components/esr-server/values.yaml @@ -17,15 +17,11 @@ ################################################################# global: nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 subChartsOnly: enabled: true # application image -repository: nexus3.onap.org:10001 image: onap/aai/esr-server:1.5.2 pullPolicy: Always msbaddr: msb-iag.{{ include "common.namespace" . }}:443 diff --git a/kubernetes/esr/requirements.yaml b/kubernetes/esr/requirements.yaml index d3c442d32e..8c2a82dedc 100644 --- a/kubernetes/esr/requirements.yaml +++ b/kubernetes/esr/requirements.yaml @@ -14,9 +14,10 @@ # limitations under the License. dependencies: - - name: common + - name: esr-gui version: ~6.x-0 - # local reference to common chart, as it is - # a part of this chart's package and will not - # be published independently to a repo (at this point) - repository: '@local' + repository: 'file://components/esr-gui' + condition: esr-gui.enabled + - name: esr-server + version: ~6.x-0 + repository: 'file://components/esr-server' diff --git a/kubernetes/esr/resources/config/log/esrserver/logback.xml b/kubernetes/esr/resources/config/log/esrserver/logback.xml deleted file mode 100644 index b9a51f1d0a..0000000000 --- a/kubernetes/esr/resources/config/log/esrserver/logback.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - ${pattern} - - diff --git a/kubernetes/esr/values.yaml b/kubernetes/esr/values.yaml index bd123583c6..5b2f776dfe 100644 --- a/kubernetes/esr/values.yaml +++ b/kubernetes/esr/values.yaml @@ -16,11 +16,11 @@ ################################################################# # Global configuration defaults. ################################################################# -global: - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 # application configuration config: logstashServiceName: log-ls - logstashPort: 5044 \ No newline at end of file + logstashPort: 5044 + +esr-gui: + enabled: true \ No newline at end of file diff --git a/kubernetes/helm/starters/onap-app/requirements.yaml b/kubernetes/helm/starters/onap-app/requirements.yaml index 6a61926e9e..b8e59b0910 100644 --- a/kubernetes/helm/starters/onap-app/requirements.yaml +++ b/kubernetes/helm/starters/onap-app/requirements.yaml @@ -14,5 +14,8 @@ dependencies: - name: common + version: ~6.x-0 + repository: '@local' + - name: repositoryGenerator version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/helm/starters/onap-app/templates/deployment.yaml b/kubernetes/helm/starters/onap-app/templates/deployment.yaml index b409781c5e..fc76c1ff6d 100644 --- a/kubernetes/helm/starters/onap-app/templates/deployment.yaml +++ b/kubernetes/helm/starters/onap-app/templates/deployment.yaml @@ -43,12 +43,12 @@ spec: # fieldRef: # apiVersion: v1 # fieldPath: metadata.namespace -# image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" +# image: {{ include "repositoryGenerator.image.readiness" . }} # imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} # name: {{ include "common.name" . }}-readiness containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/helm/starters/onap-app/values.yaml b/kubernetes/helm/starters/onap-app/values.yaml index 5bbe8f25d9..702bfb2a73 100644 --- a/kubernetes/helm/starters/onap-app/values.yaml +++ b/kubernetes/helm/starters/onap-app/values.yaml @@ -17,16 +17,11 @@ ################################################################# global: nodePortPrefix: 302 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 ################################################################# # Application configuration defaults. ################################################################# # application image -repository: nexus3.onap.org:10001 image: :<1.2-STAGING-latest> pullPolicy: Always diff --git a/kubernetes/log/charts/log-elasticsearch/values.yaml b/kubernetes/log/charts/log-elasticsearch/values.yaml index add854717a..2e4f962d23 100644 --- a/kubernetes/log/charts/log-elasticsearch/values.yaml +++ b/kubernetes/log/charts/log-elasticsearch/values.yaml @@ -27,7 +27,7 @@ global: ################################################################# # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest # application image diff --git a/kubernetes/log/charts/log-kibana/values.yaml b/kubernetes/log/charts/log-kibana/values.yaml index a5f05d51b4..5cb2fb0a1c 100644 --- a/kubernetes/log/charts/log-kibana/values.yaml +++ b/kubernetes/log/charts/log-kibana/values.yaml @@ -30,7 +30,7 @@ elasticdumpRepository: docker.io elasticdumpImage: taskrabbit/elasticsearch-dump # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest # application image diff --git a/kubernetes/modeling/Makefile b/kubernetes/modeling/Makefile index 94a9462ada..4c79718d02 100644 --- a/kubernetes/modeling/Makefile +++ b/kubernetes/modeling/Makefile @@ -1,4 +1,4 @@ -# Copyright © 2020 Samsung Electrinics +# Copyright © 2020 Samsung Electronics # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -11,12 +11,41 @@ # 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. + +ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST)))) +OUTPUT_DIR := $(ROOT_DIR)/../dist +PACKAGE_DIR := $(OUTPUT_DIR)/packages +SECRET_DIR := $(OUTPUT_DIR)/secrets + +EXCLUDES := dist resources templates charts docker HELM_BIN := helm +HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.)))) + +.PHONY: $(EXCLUDES) $(HELM_CHARTS) + +all: $(HELM_CHARTS) + +$(HELM_CHARTS): + @echo "\n[$@]" + @make package-$@ + +make-%: + @if [ -f $*/Makefile ]; then make -C $*; fi + +dep-%: make-% + @if [ -f $*/requirements.yaml ]; then $(HELM_BIN) dep up $*; fi + +lint-%: dep-% + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) lint $*; fi -make-modeling: make-modeling-etsicatalog +package-%: lint-% + @mkdir -p $(PACKAGE_DIR) + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) package -d $(PACKAGE_DIR) $*; fi + @$(HELM_BIN) repo index $(PACKAGE_DIR) -make-modeling-etsicatalog: - cd charts && $(HELM_BIN) dep up modeling-etsicatalog && $(HELM_BIN) lint modeling-etsicatalog clean: - @find . -type f -name '*.tgz' -delete - @find . -type f -name '*.lock' -delete + @rm -f */requirements.lock + @rm -f *tgz */charts/*tgz + @rm -rf $(PACKAGE_DIR) +%: + @: diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/configmap.yaml b/kubernetes/modeling/charts/modeling-etsicatalog/templates/configmap.yaml deleted file mode 100644 index c9ef0f0d1e..0000000000 --- a/kubernetes/modeling/charts/modeling-etsicatalog/templates/configmap.yaml +++ /dev/null @@ -1,23 +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. -*/}} - -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.fullname" . }}-logging-configmap - namespace: {{ include "common.namespace" . }} -data: -{{ tpl (.Files.Glob "resources/config/logging/*").AsConfig . | indent 2 }} diff --git a/kubernetes/modeling/components/Makefile b/kubernetes/modeling/components/Makefile new file mode 100644 index 0000000000..bf267b7720 --- /dev/null +++ b/kubernetes/modeling/components/Makefile @@ -0,0 +1,51 @@ +# Copyright © 2020 Samsung Electronics +# +# 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. + +ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST)))) +OUTPUT_DIR := $(ROOT_DIR)/../../dist +PACKAGE_DIR := $(OUTPUT_DIR)/packages +SECRET_DIR := $(OUTPUT_DIR)/secrets + +EXCLUDES := +HELM_BIN := helm +HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.)))) + +.PHONY: $(EXCLUDES) $(HELM_CHARTS) + +all: $(HELM_CHARTS) + +$(HELM_CHARTS): + @echo "\n[$@]" + @make package-$@ + +make-%: + @if [ -f $*/Makefile ]; then make -C $*; fi + +dep-%: make-% + @if [ -f $*/requirements.yaml ]; then $(HELM_BIN) dep up $*; fi + +lint-%: dep-% + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) lint $*; fi + +package-%: lint-% + @mkdir -p $(PACKAGE_DIR) + @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) package -d $(PACKAGE_DIR) $*; fi + @$(HELM_BIN) repo index $(PACKAGE_DIR) + +clean: + @rm -f */requirements.lock + @rm -f *tgz */charts/*tgz + @rm -rf $(PACKAGE_DIR) +%: + @: diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/.helmignore b/kubernetes/modeling/components/modeling-etsicatalog/.helmignore similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/.helmignore rename to kubernetes/modeling/components/modeling-etsicatalog/.helmignore diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/Chart.yaml b/kubernetes/modeling/components/modeling-etsicatalog/Chart.yaml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/Chart.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/Chart.yaml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/requirements.yaml b/kubernetes/modeling/components/modeling-etsicatalog/requirements.yaml similarity index 92% rename from kubernetes/modeling/charts/modeling-etsicatalog/requirements.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/requirements.yaml index 7d89fefe8d..cadf452100 100644 --- a/kubernetes/modeling/charts/modeling-etsicatalog/requirements.yaml +++ b/kubernetes/modeling/components/modeling-etsicatalog/requirements.yaml @@ -27,3 +27,6 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/modeling/resources/config/logging/filebeat/filebeat.yml b/kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/filebeat/filebeat.yml similarity index 100% rename from kubernetes/modeling/resources/config/logging/filebeat/filebeat.yml rename to kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/filebeat/filebeat.yml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/resources/config/logging/log.yml b/kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/server/log.yml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/resources/config/logging/log.yml rename to kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/server/log.yml diff --git a/kubernetes/modeling/templates/configmap.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/configmap.yaml similarity index 69% rename from kubernetes/modeling/templates/configmap.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/configmap.yaml index dee145a0e6..1a2112bbe2 100644 --- a/kubernetes/modeling/templates/configmap.yaml +++ b/kubernetes/modeling/components/modeling-etsicatalog/templates/configmap.yaml @@ -17,7 +17,15 @@ apiVersion: v1 kind: ConfigMap metadata: - name: {{ include "common.release" . }}-modeling-filebeat-configmap + name: {{ include "common.fullname" . }}-logging-configmap namespace: {{ include "common.namespace" . }} data: -{{ tpl (.Files.Glob "resources/config/logging/filebeat/*").AsConfig . | indent 2 }} +{{ tpl (.Files.Glob "resources/config/logging/server/*").AsConfig . | indent 2 }} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.fullname" . }}-modeling-filebeat-configmap + namespace: {{ include "common.namespace" . }} +data: +{{ tpl (.Files.Glob "resources/config/logging/filebeat/*").AsConfig . | indent 2 }} \ No newline at end of file diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/deployment.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/deployment.yaml similarity index 94% rename from kubernetes/modeling/charts/modeling-etsicatalog/templates/deployment.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/deployment.yaml index 347d79401a..1a303ff7aa 100644 --- a/kubernetes/modeling/charts/modeling-etsicatalog/templates/deployment.yaml +++ b/kubernetes/modeling/components/modeling-etsicatalog/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-job-readiness {{ include "common.readinessCheck.waitFor" (dict "dot" . "wait_for" .Values.readinessCheck.wait_for.msb ) | indent 6 | trim }} @@ -57,7 +57,7 @@ spec: - /bin/sh - -c - chown -R 1000:1000 /service/modeling/etsicatalog/static - image: "{{ include "common.repository" . }}/{{ .Values.initImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-init volumeMounts: @@ -65,7 +65,7 @@ spec: mountPath: /service/modeling/etsicatalog/static containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} @@ -128,7 +128,7 @@ spec: # side car containers - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf @@ -158,7 +158,7 @@ spec: - name: {{ include "common.fullname" . }}-filebeat-conf configMap: - name: {{ include "common.release" . }}-modeling-filebeat-configmap + name: {{ include "common.fullname" . }}-modeling-filebeat-configmap - name: {{ include "common.fullname" . }}-data-filebeat emptyDir: {} imagePullSecrets: diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/pv.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/pv.yaml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/templates/pv.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/pv.yaml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/pvc.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/pvc.yaml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/templates/pvc.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/pvc.yaml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/secrets.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/secrets.yaml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/templates/secrets.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/secrets.yaml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/templates/service.yaml b/kubernetes/modeling/components/modeling-etsicatalog/templates/service.yaml similarity index 100% rename from kubernetes/modeling/charts/modeling-etsicatalog/templates/service.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/templates/service.yaml diff --git a/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml b/kubernetes/modeling/components/modeling-etsicatalog/values.yaml similarity index 95% rename from kubernetes/modeling/charts/modeling-etsicatalog/values.yaml rename to kubernetes/modeling/components/modeling-etsicatalog/values.yaml index 9c910badfa..6c1cae2687 100644 --- a/kubernetes/modeling/charts/modeling-etsicatalog/values.yaml +++ b/kubernetes/modeling/components/modeling-etsicatalog/values.yaml @@ -17,9 +17,6 @@ ################################################################# global: nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 persistence: mountPath: /dockerdata-nfs @@ -100,9 +97,7 @@ config: # application image flavor: small -repository: nexus3.onap.org:10001 -image: onap/modeling/etsicatalog:1.0.8 -initImage: busybox:latest +image: onap/modeling/etsicatalog:1.0.9 pullPolicy: Always #Istio sidecar injection policy diff --git a/kubernetes/modeling/requirements.yaml b/kubernetes/modeling/requirements.yaml index f99477141f..ada1ded2c4 100644 --- a/kubernetes/modeling/requirements.yaml +++ b/kubernetes/modeling/requirements.yaml @@ -13,6 +13,6 @@ # limitations under the License. dependencies: - - name: common + - name: modeling-etsicatalog version: ~6.x-0 - repository: '@local' + repository: 'file://components/modeling-etsicatalog' diff --git a/kubernetes/msb/charts/msb-consul/values.yaml b/kubernetes/msb/charts/msb-consul/values.yaml index d11649754f..e87144c87b 100644 --- a/kubernetes/msb/charts/msb-consul/values.yaml +++ b/kubernetes/msb/charts/msb-consul/values.yaml @@ -21,7 +21,7 @@ global: # Application configuration defaults. ################################################################# # application image -dockerHubRepository: registry.hub.docker.com +dockerHubRepository: docker.io image: library/consul:1.4.3 pullPolicy: Always istioSidecar: true diff --git a/kubernetes/multicloud/charts/multicloud-prometheus/values.yaml b/kubernetes/multicloud/charts/multicloud-prometheus/values.yaml index 12bf03e06e..11c09795b7 100644 --- a/kubernetes/multicloud/charts/multicloud-prometheus/values.yaml +++ b/kubernetes/multicloud/charts/multicloud-prometheus/values.yaml @@ -20,7 +20,7 @@ global: readinessImage: onap/oom/readiness:3.0.1 loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:latest alertmanager: enabled: false diff --git a/kubernetes/nbi/requirements.yaml b/kubernetes/nbi/requirements.yaml index 7ce343627a..f76d598417 100644 --- a/kubernetes/nbi/requirements.yaml +++ b/kubernetes/nbi/requirements.yaml @@ -34,3 +34,6 @@ dependencies: version: ~6.x-0 repository: '@local' condition: not global.mariadbGalera.localCluster + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/nbi/templates/deployment.yaml b/kubernetes/nbi/templates/deployment.yaml index 6d5b2d508f..4be444ad1b 100644 --- a/kubernetes/nbi/templates/deployment.yaml +++ b/kubernetes/nbi/templates/deployment.yaml @@ -43,7 +43,7 @@ spec: {{- end }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} @@ -146,31 +146,9 @@ spec: affinity: {{ toYaml .Values.affinity | indent 10 }} {{- end }} - # side car containers - # - name: filebeat-onap - # image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" - # imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - # volumeMounts: - # - mountPath: /usr/share/filebeat/filebeat.yml - # name: filebeat-conf - # subPath: filebeat.yml - # - mountPath: /home/esr/works/logs - # name: esr-server-logs - # - mountPath: /usr/share/filebeat/data - # name: esr-server-filebeat volumes: {{ include "common.certInitializer.volumes" . | nindent 8 }} - name: localtime hostPath: path: /etc/localtime - # - name: filebeat-conf - # configMap: - # name: {{ include "common.fullname" . }}-esr-filebeat - # - name: esr-server-logs - # emptyDir: {} - # - name: esr-server-filebeat - # emptyDir: {} - # - name: esrserver-log - # configMap: - # name: {{ include "common.fullname" . }}-esr-esrserver-log imagePullSecrets: - name: "{{ include "common.namespace" . }}-docker-registry-key" diff --git a/kubernetes/nbi/values.yaml b/kubernetes/nbi/values.yaml index 58fa33611c..61d7680824 100644 --- a/kubernetes/nbi/values.yaml +++ b/kubernetes/nbi/values.yaml @@ -18,9 +18,6 @@ ################################################################# global: nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 mariadbGalera: &mariadbGalera #This flag allows SO to instantiate its own mariadb-galera cluster localCluster: false @@ -28,8 +25,6 @@ global: internalPort: 3306 nameOverride: mariadb-galera aafEnabled: true - busyBoxImage: busybox:1.30 - busyBoxRepository: docker.io ################################################################# # AAF part diff --git a/kubernetes/onap/requirements.yaml b/kubernetes/onap/requirements.yaml index daa2b1e9ca..51f1743773 100755 --- a/kubernetes/onap/requirements.yaml +++ b/kubernetes/onap/requirements.yaml @@ -114,6 +114,9 @@ dependencies: version: ~6.x-0 repository: '@local' condition: oof.enabled + - name: repository-wrapper + version: ~6.x-0 + repository: '@local' - name: robot version: ~6.x-0 repository: '@local' diff --git a/kubernetes/onap/values.yaml b/kubernetes/onap/values.yaml index 9473a6abcb..3c8b1e9d90 100755 --- a/kubernetes/onap/values.yaml +++ b/kubernetes/onap/values.yaml @@ -40,34 +40,73 @@ global: addTestingComponents: &testing false # ONAP Repository - # Uncomment the following to enable the use of a single docker - # repository but ONLY if your repository mirrors all ONAP - # docker images. This includes all images from dockerhub and - # any other repository that hosts images for ONAP components. - #repository: nexus3.onap.org:10001 + # Four different repositories are used + # You can change individually these repositories to ones that will serve the + # right images. If credentials are needed for one of them, see below. + repository: nexus3.onap.org:10001 + dockerHubRepository: &dockerHubRepository docker.io + elasticRepository: &elasticRepository docker.elastic.co + googleK8sRepository: k8s.gcr.io + + + #/!\ DEPRECATED /!\ + # Legacy repositories which will be removed at the end of migration. + # Please don't use + loggingRepository: *elasticRepository + busyboxRepository: *dockerHubRepository + + # Default credentials + # they're optional. If the target repository doesn't need them, comment them repositoryCred: user: docker password: docker - dockerHubRepository: docker.io - - # readiness check - readinessImage: onap/oom/readiness:3.0.1 + # If you want / need authentication on the repositories, please set + # Don't set them if the target repo is the same than others + # so id you've set repository to value `my.private.repo` and same for + # dockerHubRepository, you'll have to configure only repository (exclusive) OR + # dockerHubCred. + # dockerHubCred: + # user: myuser + # password: mypassord + # elasticCred: + # user: myuser + # password: mypassord + # googleK8sCred: + # user: myuser + # password: mypassord + + + # common global images + # Busybox for simple shell manipulation + busyboxImage: busybox:1.32 # curl image curlImage: curlimages/curl:7.69.1 - # logging agent - temporary repo until images migrated to nexus3 - loggingRepository: docker.elastic.co + # env substitution image + envsubstImage: dibi/envsubst:1 + + # generate htpasswd files image + # there's only latest image for htpasswd + htpasswdImage: xmartlabs/htpasswd:latest + + # kubenretes client image + kubectlImage: bitnami/kubectl:1.19 + + # logging agent + loggingImage: beats/filebeat:5.5.0 - # dockerHub main repository - dockerHubRepository: docker.io + # mariadb client image + mariadbImage: mariadb:10.1.48 - # busybox repo and image - busyboxRepository: docker.io - busyboxImage: busybox:1.30 + # nginx server image + nginxImage: bitnami/nginx:1.18-debian-10 - # kubeclt image - kubectlImage: "bitnami/kubectl:1.15" + # postgreSQL client and server image + postgresImage: crunchydata/crunchy-postgres:centos7-10.11-4.2.1 + + # readiness check image + readinessImage: onap/oom/readiness:3.0.1 # image pull policy pullPolicy: Always @@ -146,6 +185,11 @@ global: truststorePath: "/etc/onap/oom/certservice/certs/truststore.jks" truststorePassword: "secret" + # Indicates offline deployment build + # Set to true if you are rendering helm charts for offline deployment + # Otherwise keep it disabled + offlineDeploymentBuild: false + # TLS # Set to false if you want to disable TLS for NodePorts. Be aware that this # will loosen your security. @@ -320,3 +364,5 @@ a1policymanagement: cert-wrapper: enabled: true +repository-wrapper: + enabled: true diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/requirements.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/requirements.yaml index 1d9792fa5f..2b3543a04f 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/requirements.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' \ No newline at end of file diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/templates/deployment.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/templates/deployment.yaml index fb798ef791..c1d2602713 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/templates/deployment.yaml @@ -48,7 +48,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness - name: {{ include "common.name" . }}-db-config-readiness @@ -63,17 +63,17 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-chown command: ["/bin/sh", "-c", "chown -Rf 1000:1000 /share/"] - image: "{{ .Values.global.busyBoxRepository }}/{{ .Values.global.busyBoxImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-logs mountPath: /share/logs - name: db-init - image: "{{ include "common.repository" . }}/{{ .Values.dbinit.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.dbinit.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST @@ -95,7 +95,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/values.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/values.yaml index 6b04cdb0d9..0c7eb8d6a7 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/values.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-optimizer/values.yaml @@ -24,7 +24,6 @@ subChartsOnly: enabled: true # application image -repository: nexus3.onap.org:10001 image: onap/optf-cmso-optimizer:2.3.0 pullPolicy: Always diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/requirements.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/requirements.yaml index 1d9792fa5f..6a956790c7 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/requirements.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/templates/deployment.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/templates/deployment.yaml index 522645e9ce..27d52a24ba 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/templates/deployment.yaml @@ -48,7 +48,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness - name: {{ include "common.name" . }}-db-config-readiness @@ -63,17 +63,17 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-chown command: ["/bin/sh", "-c", "chown -Rf 1000:1000 /share/"] - image: "{{ .Values.global.busyBoxRepository }}/{{ .Values.global.busyBoxImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-logs mountPath: /share/logs - name: db-init - image: "{{ include "common.repository" . }}/{{ .Values.dbinit.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.dbinit.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST @@ -96,7 +96,7 @@ spec: containers: # side car containers - name: filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - mountPath: /usr/share/filebeat/filebeat.yml @@ -109,7 +109,7 @@ spec: resources: {{ include "common.resources" . }} - name: mso-simulator - image: "{{ include "common.repository" . }}/{{ .Values.robotimage }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.robotimage }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-config @@ -119,7 +119,7 @@ spec: resources: {{ include "common.resources" . }} - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/values.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/values.yaml index 4f4503be62..9973f85cff 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/values.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-service/values.yaml @@ -18,13 +18,11 @@ ################################################################# global: # global defaults nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 subChartsOnly: enabled: true # application image -repository: nexus3.onap.org:10001 image: onap/optf-cmso-service:2.3.0 robotimage: onap/optf-cmso-robot:2.3.0 pullPolicy: Always diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/requirements.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/requirements.yaml index 1d9792fa5f..6a956790c7 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/requirements.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/templates/deployment.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/templates/deployment.yaml index 929e0fb731..9f9484ff94 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: initContainers: - name: {{ include "common.name" . }}-chown command: ["/bin/sh", "-c", "chown -Rf 1000:1000 /share/"] - image: "{{ .Values.global.busyBoxRepository }}/{{ .Values.global.busyBoxImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-logs @@ -46,7 +46,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: JAVA_TRUSTSTORE diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/values.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/values.yaml index 1c1ae7ab43..3720c7d44b 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/values.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-ticketmgt/values.yaml @@ -23,7 +23,6 @@ subChartsOnly: enabled: true # application image -repository: nexus3.onap.org:10001 image: onap/optf-cmso-ticketmgt:2.3.0 pullPolicy: Always diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/requirements.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/requirements.yaml index 1d9792fa5f..6a956790c7 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/requirements.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/templates/deployment.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/templates/deployment.yaml index 8b030298ea..c08d9a3451 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: initContainers: - name: {{ include "common.name" . }}-chown command: ["/bin/sh", "-c", "chown -Rf 1000:1000 /share/"] - image: "{{ .Values.global.busyBoxRepository }}/{{ .Values.global.busyBoxImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-logs @@ -46,7 +46,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: JAVA_TRUSTSTORE diff --git a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/values.yaml b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/values.yaml index 9d5cec1014..bdf1606dd4 100644 --- a/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/values.yaml +++ b/kubernetes/oof/components/oof-cmso/components/oof-cmso-topology/values.yaml @@ -17,13 +17,11 @@ ################################################################# global: # global defaults nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 subChartsOnly: enabled: true # application image -repository: nexus3.onap.org:10001 image: onap/optf-cmso-topology:2.3.0 pullPolicy: Always diff --git a/kubernetes/oof/components/oof-cmso/requirements.yaml b/kubernetes/oof/components/oof-cmso/requirements.yaml index 57357a6faf..0e79ed0250 100644 --- a/kubernetes/oof/components/oof-cmso/requirements.yaml +++ b/kubernetes/oof/components/oof-cmso/requirements.yaml @@ -42,3 +42,6 @@ dependencies: version: ~6.x-0 repository: 'file://components/oof-cmso-topology' condition: oof-cmso-topology.enabled + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-cmso/values.yaml b/kubernetes/oof/components/oof-cmso/values.yaml index e83e2dec56..7405c487c4 100644 --- a/kubernetes/oof/components/oof-cmso/values.yaml +++ b/kubernetes/oof/components/oof-cmso/values.yaml @@ -62,12 +62,8 @@ global: commonConfigPrefix: "oof-cmso" truststoreFile: "truststoreONAPall.jks" keystoreFile: "org.onap.oof.jks" - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 truststorePassword: authentication: aaf-auth - busyBoxImage: busybox:1.30 - busyBoxRepository: docker.io mariadb-init: mariadbGalera: diff --git a/kubernetes/oof/components/oof-has/components/oof-has-api/requirements.yaml b/kubernetes/oof/components/oof-has/components/oof-has-api/requirements.yaml index 90fe5dd732..f9673d5b32 100644 --- a/kubernetes/oof/components/oof-has/components/oof-has-api/requirements.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-api/requirements.yaml @@ -22,3 +22,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://../../../oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/components/oof-has-api/templates/deployment.yaml b/kubernetes/oof/components/oof-has/components/oof-has-api/templates/deployment.yaml index 4db9f158b9..491250c72a 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-api/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-api/templates/deployment.yaml @@ -52,7 +52,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-onboard-readiness @@ -67,7 +67,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-has-sms-readiness @@ -86,13 +86,13 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: ["/bin/bash","-c"] args: ["/usr/local/bin/uwsgi -s /run/conductor/uwsgi.sock --chmod-socket=777 --wsgi-file /etc/nginx/conductor.wsgi --callable application --set port={{ .Values.uwsgi.internalPort }} --die-on-term --exit-on-reload --pidfile /run/conductor/conductor-uwsgi.pid --enable-threads --workers 6 --master --vacuum --single-interpreter --socket-timeout 10 --max-worker-lifetime 300 --max-requests 100 --no-defer-accept --protocol=uwsgi --socket 0.0.0.0:{{ .Values.uwsgi.internalPort }}"] @@ -129,7 +129,7 @@ spec: resources: {{ include "common.resources" . | indent 12 }} - name: {{ include "common.name" . }}-nginx - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.nginx.image }}" + image: {{ include "repositoryGenerator.image.nginx" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /bin/sh diff --git a/kubernetes/oof/components/oof-has/components/oof-has-api/values.yaml b/kubernetes/oof/components/oof-has/components/oof-has-api/values.yaml index b17eed6b2f..46d7172b84 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-api/values.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-api/values.yaml @@ -35,9 +35,6 @@ service: nodePort: 75 portName: oof-has-api -#sidecar container image -nginx: - image: bitnami/nginx:1.18-debian-10 #backend container info uwsgi: internalPort: 8080 diff --git a/kubernetes/oof/components/oof-has/components/oof-has-controller/requirements.yaml b/kubernetes/oof/components/oof-has/components/oof-has-controller/requirements.yaml index 1bb059b173..8fde52a4c6 100644 --- a/kubernetes/oof/components/oof-has/components/oof-has-controller/requirements.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-controller/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://../../../oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/components/oof-has-controller/templates/deployment.yaml b/kubernetes/oof/components/oof-has/components/oof-has-controller/templates/deployment.yaml index 9540cc3159..8e0ff1aeb5 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-controller/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-controller/templates/deployment.yaml @@ -51,7 +51,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-onboard-readiness @@ -66,7 +66,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-cont-sms-readiness @@ -85,11 +85,11 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - python diff --git a/kubernetes/oof/components/oof-has/components/oof-has-controller/values.yaml b/kubernetes/oof/components/oof-has/components/oof-has-controller/values.yaml index 327a537f41..99dd66cf0f 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-controller/values.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-controller/values.yaml @@ -13,8 +13,6 @@ # limitations under the License. global: - readinessImage: onap/oom/readiness:3.0.1 - repository: nexus3.onap.org:10001 image: optf_has: onap/optf-has:2.1.2 diff --git a/kubernetes/oof/components/oof-has/components/oof-has-data/requirements.yaml b/kubernetes/oof/components/oof-has/components/oof-has-data/requirements.yaml index 1bb059b173..8fde52a4c6 100644 --- a/kubernetes/oof/components/oof-has/components/oof-has-data/requirements.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-data/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://../../../oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/components/oof-has-data/templates/deployment.yaml b/kubernetes/oof/components/oof-has/components/oof-has-data/templates/deployment.yaml index 4292cb1e4f..f4ccd57773 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-data/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-data/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-onboard-readiness @@ -64,7 +64,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-health-readiness @@ -79,7 +79,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-data-sms-readiness @@ -98,12 +98,12 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - python diff --git a/kubernetes/oof/components/oof-has/components/oof-has-data/values.yaml b/kubernetes/oof/components/oof-has/components/oof-has-data/values.yaml index 570c0df5b2..e7a63c5679 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-data/values.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-data/values.yaml @@ -13,8 +13,6 @@ # limitations under the License. global: - readinessImage: onap/oom/readiness:3.0.1 - repository: nexus3.onap.org:10001 image: optf_has: onap/optf-has:2.1.2 diff --git a/kubernetes/oof/components/oof-has/components/oof-has-reservation/requirements.yaml b/kubernetes/oof/components/oof-has/components/oof-has-reservation/requirements.yaml index 1bb059b173..8fde52a4c6 100644 --- a/kubernetes/oof/components/oof-has/components/oof-has-reservation/requirements.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-reservation/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://../../../oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/components/oof-has-reservation/templates/deployment.yaml b/kubernetes/oof/components/oof-has/components/oof-has-reservation/templates/deployment.yaml index 9acd944ac5..4d04b6fe76 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-reservation/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-reservation/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-onboard-readiness @@ -64,7 +64,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-health-readiness @@ -79,7 +79,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-resrv-sms-readiness @@ -98,12 +98,12 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - python diff --git a/kubernetes/oof/components/oof-has/components/oof-has-reservation/values.yaml b/kubernetes/oof/components/oof-has/components/oof-has-reservation/values.yaml index 570c0df5b2..e7a63c5679 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-reservation/values.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-reservation/values.yaml @@ -13,8 +13,6 @@ # limitations under the License. global: - readinessImage: onap/oom/readiness:3.0.1 - repository: nexus3.onap.org:10001 image: optf_has: onap/optf-has:2.1.2 diff --git a/kubernetes/oof/components/oof-has/components/oof-has-solver/requirements.yaml b/kubernetes/oof/components/oof-has/components/oof-has-solver/requirements.yaml index 1bb059b173..8fde52a4c6 100644 --- a/kubernetes/oof/components/oof-has/components/oof-has-solver/requirements.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-solver/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://../../../oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/components/oof-has-solver/templates/deployment.yaml b/kubernetes/oof/components/oof-has/components/oof-has-solver/templates/deployment.yaml index ec26684111..6079dcfd6e 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-solver/templates/deployment.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-solver/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-onboard-readiness @@ -64,7 +64,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-health-readiness @@ -79,7 +79,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: {{ include "common.name" . }}-solvr-sms-readiness @@ -98,12 +98,12 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - python diff --git a/kubernetes/oof/components/oof-has/components/oof-has-solver/values.yaml b/kubernetes/oof/components/oof-has/components/oof-has-solver/values.yaml index 570c0df5b2..e7a63c5679 100755 --- a/kubernetes/oof/components/oof-has/components/oof-has-solver/values.yaml +++ b/kubernetes/oof/components/oof-has/components/oof-has-solver/values.yaml @@ -13,8 +13,6 @@ # limitations under the License. global: - readinessImage: onap/oom/readiness:3.0.1 - repository: nexus3.onap.org:10001 image: optf_has: onap/optf-has:2.1.2 diff --git a/kubernetes/oof/components/oof-has/requirements.yaml b/kubernetes/oof/components/oof-has/requirements.yaml index b1e0e1a8ec..d21a124449 100755 --- a/kubernetes/oof/components/oof-has/requirements.yaml +++ b/kubernetes/oof/components/oof-has/requirements.yaml @@ -40,3 +40,6 @@ dependencies: version: ~6.x-0 repository: 'file://components/oof-has-solver' condition: oof-has-solver.enabled + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/components/oof-has/templates/job-healthcheck.yaml b/kubernetes/oof/components/oof-has/templates/job-healthcheck.yaml index 393a6bbf2e..49406ba423 100755 --- a/kubernetes/oof/components/oof-has/templates/job-healthcheck.yaml +++ b/kubernetes/oof/components/oof-has/templates/job-healthcheck.yaml @@ -33,7 +33,7 @@ spec: release: {{ include "common.release" . }} spec: initContainers: - - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + - image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness command: @@ -48,7 +48,7 @@ spec: apiVersion: v1 fieldPath: metadata.namespace containers: - - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-healthcheck command: diff --git a/kubernetes/oof/components/oof-has/templates/job-onboard.yaml b/kubernetes/oof/components/oof-has/templates/job-onboard.yaml index a82435bccc..a60372f30a 100755 --- a/kubernetes/oof/components/oof-has/templates/job-onboard.yaml +++ b/kubernetes/oof/components/oof-has/templates/job-onboard.yaml @@ -33,7 +33,7 @@ spec: release: {{ include "common.release" . }} spec: initContainers: - - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + - image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness command: @@ -60,11 +60,11 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-music-db-readiness containers: - - image: "{{ include "common.repository" . }}/{{ .Values.global.image.optf_has }}" + - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.image.optf_has }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-onboard command: diff --git a/kubernetes/oof/components/oof-has/values.yaml b/kubernetes/oof/components/oof-has/values.yaml index ffd11db2dd..1389044870 100755 --- a/kubernetes/oof/components/oof-has/values.yaml +++ b/kubernetes/oof/components/oof-has/values.yaml @@ -17,14 +17,9 @@ # Global configuration defaults. ################################################################# global: - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - repository: nexus3.onap.org:10001 commonConfigPrefix: onap-oof-has image: optf_has: onap/optf-has:2.1.2 - filebeat: docker.elastic.co/beats/filebeat:5.5.0 persistence: enabled: true diff --git a/kubernetes/oof/requirements.yaml b/kubernetes/oof/requirements.yaml index 2d1f9b3596..a68ce411f1 100755 --- a/kubernetes/oof/requirements.yaml +++ b/kubernetes/oof/requirements.yaml @@ -31,3 +31,6 @@ dependencies: - name: oof-templates version: ~6.x-0 repository: 'file://components/oof-templates' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/oof/templates/deployment.yaml b/kubernetes/oof/templates/deployment.yaml index 2f46a6d667..2b1eeba747 100644 --- a/kubernetes/oof/templates/deployment.yaml +++ b/kubernetes/oof/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness - command: @@ -67,13 +67,13 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ .Values.global.dockerHubRepository }}/{{ .Values.global.curlImage }}" + image: {{ include "repositoryGenerator.image.curl" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-osdf-sms-readiness {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /bin/sh diff --git a/kubernetes/oof/values.yaml b/kubernetes/oof/values.yaml index 0cdccfbd8e..db7c9d2231 100644 --- a/kubernetes/oof/values.yaml +++ b/kubernetes/oof/values.yaml @@ -17,9 +17,6 @@ ################################################################# global: nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 persistence: {} ################################################################# @@ -38,7 +35,6 @@ secrets: # Application configuration defaults. ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/optf-osdf:3.0.2 pullPolicy: Always diff --git a/kubernetes/platform/components/oom-cert-service/Makefile b/kubernetes/platform/components/oom-cert-service/Makefile index c4723dfdd1..c15fdc7a51 100644 --- a/kubernetes/platform/components/oom-cert-service/Makefile +++ b/kubernetes/platform/components/oom-cert-service/Makefile @@ -27,7 +27,12 @@ all: start_docker \ # Starts docker container for generating certificates - deletes first, if already running start_docker: @make stop_docker - docker run -d --rm --name ${DOCKER_CONTAINER} --mount type=bind,source=${CURRENT_DIR}/${CERTS_DIR},target=/certs -w /certs docker.io/openjdk:11-jre-slim tail -f /dev/null + $(eval REPOSITORY := $(shell cat ./values.yaml | grep -i "^[ \t]*repository" -m1 | xargs | cut -d ' ' -f2)) + $(eval JAVA_IMAGE := $(shell cat ./values.yaml | grep -i "^[ \t]*certificateGenerationImage" -m1 | xargs | cut -d ' ' -f2)) + $(eval FULL_JAVA_IMAGE := $(REPOSITORY)/$(JAVA_IMAGE)) + $(eval USER :=$(shell id -u)) + $(eval GROUP :=$(shell id -g)) + docker run --rm --name ${DOCKER_CONTAINER} --user "$(USER):$(GROUP)" --mount type=bind,source=${CURRENT_DIR}/${CERTS_DIR},target=/app -w /app --entrypoint "sh" -td $(FULL_JAVA_IMAGE) # Stops docker container for generating certificates. 'true' is used to return 0 status code, if container is already deleted stop_docker: @@ -89,7 +94,7 @@ client_sign_certificate_by_root: #Import root certificate into client client_import_root_certificate: @echo "Import root certificate into intermediate" - ${DOCKER_EXEC} bash -c "cat root.crt >> certServiceClientByRoot.crt" + ${DOCKER_EXEC} sh -c "cat root.crt >> certServiceClientByRoot.crt" @echo "####done####" #Import signed certificate into certService's client @@ -124,7 +129,7 @@ server_sign_certificate_by_root: #Import root certificate into server server_import_root_certificate: @echo "Import root certificate into intermediate(server)" - ${DOCKER_EXEC} bash -c "cat root.crt >> certServiceServerByRoot.crt" + ${DOCKER_EXEC} sh -c "cat root.crt >> certServiceServerByRoot.crt" @echo "####done####" #Import signed certificate into certService diff --git a/kubernetes/platform/components/oom-cert-service/requirements.yaml b/kubernetes/platform/components/oom-cert-service/requirements.yaml index 6afaa06e8a..26bc7a64d8 100644 --- a/kubernetes/platform/components/oom-cert-service/requirements.yaml +++ b/kubernetes/platform/components/oom-cert-service/requirements.yaml @@ -12,7 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. - dependencies: +dependencies: - name: common version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/platform/components/oom-cert-service/templates/deployment.yaml b/kubernetes/platform/components/oom-cert-service/templates/deployment.yaml index a6ce2825ec..c4d7440b20 100644 --- a/kubernetes/platform/components/oom-cert-service/templates/deployment.yaml +++ b/kubernetes/platform/components/oom-cert-service/templates/deployment.yaml @@ -53,10 +53,10 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - name: subsitute-envs - image: "{{ .Values.global.envsubstImage }}" + image: {{ include "repositoryGenerator.image.envsubst" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: ['sh', '-c', "cd /config-input && envsubst < cmpServers.json > {{ .Values.cmpServers.volume.mountPath }}/cmpServers.json"] volumeMounts: @@ -78,7 +78,7 @@ spec: {{- end }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: {{ include "common.containerPorts" . | nindent 10 }} env: diff --git a/kubernetes/platform/components/oom-cert-service/templates/fake_deployment.yaml b/kubernetes/platform/components/oom-cert-service/templates/fake_deployment.yaml new file mode 100644 index 0000000000..1d1224afa4 --- /dev/null +++ b/kubernetes/platform/components/oom-cert-service/templates/fake_deployment.yaml @@ -0,0 +1,31 @@ +{{/* + # Copyright © 2020, Nokia + # + # 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 .Values.global.offlineDeploymentBuild }} +apiVersion: apps/v1 +kind: Deployment +metadata: {{- include "common.resourceMetadata" . | nindent 2 }} +spec: + replicas: {{ .Values.replicaCount }} + selector: {{- include "common.selectors" . | nindent 4 }} + template: + metadata: {{- include "common.templateMetadata" . | nindent 6 }} + spec: + containers: + - name: {{ include "common.name" . }} + image: {{ include "common.repository" . }}/{{ .Values.certifcateGenerationImage }} + imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} +{{ end -}} diff --git a/kubernetes/platform/components/oom-cert-service/values.yaml b/kubernetes/platform/components/oom-cert-service/values.yaml index 3ab9895037..ee51ec7a7d 100644 --- a/kubernetes/platform/components/oom-cert-service/values.yaml +++ b/kubernetes/platform/components/oom-cert-service/values.yaml @@ -16,24 +16,13 @@ # Global global: - envsubstImage: dibi/envsubst nodePortPrefix: 302 - # Readiness image - readinessImage: onap/oom/readiness:3.0.1 - # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com - ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 - # Logging image - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - # BusyBox image - busyboxRepository: registry.hub.docker.com - busyboxImage: library/busybox:1.31 persistence: enabled: true # Standard OOM pullPolicy: "Always" repository: "nexus3.onap.org:10001" + offlineDeploymentBuild: false # Service configuration @@ -44,9 +33,11 @@ service: port: 8443 port_protocol: http +# Certificates generation configuration +certificateGenerationImage: onap/integration-java11:7.1.0 # Deployment configuration -repository: nexus3.onap.org:10001 +repository: "nexus3.onap.org:10001" image: onap/org.onap.oom.platform.cert-service.oom-certservice-api:2.1.0 pullPolicy: Always replicaCount: 1 diff --git a/kubernetes/platform/values.yaml b/kubernetes/platform/values.yaml index 687fb6151e..d21fb791e2 100644 --- a/kubernetes/platform/values.yaml +++ b/kubernetes/platform/values.yaml @@ -20,27 +20,10 @@ global: nodePortPrefix: 302 - # Readiness image - readinessRepository: oomk8s - readinessImage: readiness-check:2.0.2 - # Ubuntu Init image - ubuntuInitRepository: registry.hub.docker.com - ubuntuInitImage: oomk8s/ubuntu-init:2.0.0 - # Logging image - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - # BusyBox image - busyboxRepository: registry.hub.docker.com - busyboxImage: library/busybox:1.31 persistence: enabled: true # Standard OOM pullPolicy: "Always" - repository: "nexus3.onap.org:10001" - - # Use Local - #pullPolicy: IfNotPresent - #repository: "nexus3.onap.org:10003" cmpv2Enabled: true addTestingComponents: false diff --git a/kubernetes/policy/components/policy-apex-pdp/resources/config/OnapPfConfig.json b/kubernetes/policy/components/policy-apex-pdp/resources/config/OnapPfConfig.json index 539ef5a465..66a42f0171 100755 --- a/kubernetes/policy/components/policy-apex-pdp/resources/config/OnapPfConfig.json +++ b/kubernetes/policy/components/policy-apex-pdp/resources/config/OnapPfConfig.json @@ -28,6 +28,7 @@ "topic" : "POLICY-PDP-PAP", "servers" : [ "message-router" ], "useHttps" : true, + "fetchTimeout": 15000, "topicCommInfrastructure" : "dmaap" }], "topicSinks" : [{ diff --git a/kubernetes/policy/components/policy-apex-pdp/values.yaml b/kubernetes/policy/components/policy-apex-pdp/values.yaml index 6243d26dc3..23788e2532 100755 --- a/kubernetes/policy/components/policy-apex-pdp/values.yaml +++ b/kubernetes/policy/components/policy-apex-pdp/values.yaml @@ -52,7 +52,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/policy-apex-pdp:2.4.3 +image: onap/policy-apex-pdp:2.4.4 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/policy/components/policy-drools-pdp/values.yaml b/kubernetes/policy/components/policy-drools-pdp/values.yaml index 61532fa395..6c865d8369 100755 --- a/kubernetes/policy/components/policy-drools-pdp/values.yaml +++ b/kubernetes/policy/components/policy-drools-pdp/values.yaml @@ -39,7 +39,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/policy-pdpd-cl:1.7.4 +image: onap/policy-pdpd-cl:1.7.5 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/pomba/charts/pomba-data-router/values.yaml b/kubernetes/pomba/charts/pomba-data-router/values.yaml index 386f12e73e..fe15bd1b07 100644 --- a/kubernetes/pomba/charts/pomba-data-router/values.yaml +++ b/kubernetes/pomba/charts/pomba-data-router/values.yaml @@ -31,7 +31,7 @@ pullPolicy: Always restartPolicy: Always # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest diff --git a/kubernetes/pomba/charts/pomba-elasticsearch/values.yaml b/kubernetes/pomba/charts/pomba-elasticsearch/values.yaml index 8201eff7b1..f99a79935d 100644 --- a/kubernetes/pomba/charts/pomba-elasticsearch/values.yaml +++ b/kubernetes/pomba/charts/pomba-elasticsearch/values.yaml @@ -24,7 +24,7 @@ global: ################################################################# # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest # application image diff --git a/kubernetes/pomba/charts/pomba-kibana/values.yaml b/kubernetes/pomba/charts/pomba-kibana/values.yaml index 56cbff7ec0..e952e3c226 100644 --- a/kubernetes/pomba/charts/pomba-kibana/values.yaml +++ b/kubernetes/pomba/charts/pomba-kibana/values.yaml @@ -28,7 +28,7 @@ configRepository: docker.io configImage: taskrabbit/elasticsearch-dump # BusyBox image -busyboxRepository: registry.hub.docker.com +busyboxRepository: docker.io busyboxImage: library/busybox:latest # application image diff --git a/kubernetes/portal/components/portal-app/requirements.yaml b/kubernetes/portal/components/portal-app/requirements.yaml index 00b92235f3..bfcaecb7aa 100644 --- a/kubernetes/portal/components/portal-app/requirements.yaml +++ b/kubernetes/portal/components/portal-app/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/portal/components/portal-app/templates/deployment.yaml b/kubernetes/portal/components/portal-app/templates/deployment.yaml index 068a0af3c2..71b2aa3227 100644 --- a/kubernetes/portal/components/portal-app/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-app/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: initContainers: - name: {{ include "common.name" . }}-job-completion - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: "{{ .Values.global.pullPolicy | default .Values.pullPolicy }}" command: - /app/ready.py @@ -52,7 +52,7 @@ spec: apiVersion: v1 fieldPath: metadata.namespace - name: {{ include "common.name" . }}-portal-config - image: "{{ .Values.global.envsubstImage }}" + image: {{ include "repositoryGenerator.image.envsubst" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - sh @@ -90,7 +90,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: ["bash","-c"] {{- if .Values.global.aafEnabled }} @@ -170,7 +170,7 @@ spec: {{ toYaml .Values.affinity | indent 10 }} {{- end }} - name: filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - mountPath: /usr/share/filebeat/filebeat.yml diff --git a/kubernetes/portal/components/portal-app/values.yaml b/kubernetes/portal/components/portal-app/values.yaml index 01d4261bdf..0a818102c6 100644 --- a/kubernetes/portal/components/portal-app/values.yaml +++ b/kubernetes/portal/components/portal-app/values.yaml @@ -20,10 +20,6 @@ global: env: tomcatDir: "/usr/local/tomcat" nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - envsubstImage: dibi/envsubst #AAF service aafEnabled: true @@ -55,7 +51,6 @@ secrets: ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/portal-app:3.4.2 pullPolicy: Always diff --git a/kubernetes/portal/components/portal-cassandra/requirements.yaml b/kubernetes/portal/components/portal-cassandra/requirements.yaml index c5d7864b9d..7c92350367 100644 --- a/kubernetes/portal/components/portal-cassandra/requirements.yaml +++ b/kubernetes/portal/components/portal-cassandra/requirements.yaml @@ -16,3 +16,6 @@ dependencies: - name: common version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml b/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml index c1b49da31a..80197a6094 100644 --- a/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-cassandra/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/portal/components/portal-cassandra/values.yaml b/kubernetes/portal/components/portal-cassandra/values.yaml index eb6fc12274..a0488e5cc7 100644 --- a/kubernetes/portal/components/portal-cassandra/values.yaml +++ b/kubernetes/portal/components/portal-cassandra/values.yaml @@ -22,7 +22,6 @@ global: # global defaults # application image -repository: nexus3.onap.org:10001 image: onap/music/cassandra_music:3.0.0 pullPolicy: Always diff --git a/kubernetes/portal/components/portal-mariadb/requirements.yaml b/kubernetes/portal/components/portal-mariadb/requirements.yaml index c5d7864b9d..7c92350367 100644 --- a/kubernetes/portal/components/portal-mariadb/requirements.yaml +++ b/kubernetes/portal/components/portal-mariadb/requirements.yaml @@ -16,3 +16,6 @@ dependencies: - name: common version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/portal/components/portal-mariadb/templates/deployment.yaml b/kubernetes/portal/components/portal-mariadb/templates/deployment.yaml index 250335f0ce..7e94c76896 100644 --- a/kubernetes/portal/components/portal-mariadb/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-mariadb/templates/deployment.yaml @@ -38,14 +38,14 @@ spec: spec: initContainers: - name: volume-permissions - image: "{{ .Values.global.busyboxRepository }}/{{ .Values.global.busyboxImage }}" + image: {{ include "repositoryGenerator.image.busybox" . }} command: ['sh', '-c', 'chmod -R 777 /var/lib/mysql'] volumeMounts: - mountPath: /var/lib/mysql name: mariadb-data containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/portal/components/portal-mariadb/templates/job.yaml b/kubernetes/portal/components/portal-mariadb/templates/job.yaml index 920ee73169..5a66bb96bd 100644 --- a/kubernetes/portal/components/portal-mariadb/templates/job.yaml +++ b/kubernetes/portal/components/portal-mariadb/templates/job.yaml @@ -35,7 +35,7 @@ spec: restartPolicy: Never initContainers: - name: {{ include "common.name" . }}-init-readiness - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /app/ready.py @@ -50,7 +50,7 @@ spec: fieldPath: metadata.namespace containers: - name: {{ include "common.name" . }}-job - image: "{{ include "common.repository" . }}/{{ .Values.mariadbInitImage }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.mariadbInitImage }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST @@ -63,7 +63,7 @@ spec: - name: SQL_SRC_DIR value: {{ .Values.config.sqlSourceDirectory }} - name: {{ include "common.name" . }}-oom-update-job - image: "{{ include "common.repository" . }}/{{ .Values.mariadbInitImage }}" + image: {{ include "repositoryGenerator.dockerHubRepository" . }}/{{ .Values.mariadbInitImage }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST diff --git a/kubernetes/portal/components/portal-mariadb/values.yaml b/kubernetes/portal/components/portal-mariadb/values.yaml index 5061593739..99dda390b4 100644 --- a/kubernetes/portal/components/portal-mariadb/values.yaml +++ b/kubernetes/portal/components/portal-mariadb/values.yaml @@ -19,17 +19,11 @@ global: # global defaults nodePortPrefix: 302 persistence: {} - readinessImage: onap/oom/readiness:3.0.1 - busyBoxImage: busybox:1.30 - busyBoxRepository: docker.io # application image -repository: nexus3.onap.org:10001 image: onap/portal-db:3.4.1 pullPolicy: Always - - -mariadbInitImage: "oomk8s/mariadb-client-init:3.0.0" +mariadbInitImage: oomk8s/mariadb-client-init:3.0.0 # application configuration config: diff --git a/kubernetes/portal/components/portal-sdk/requirements.yaml b/kubernetes/portal/components/portal-sdk/requirements.yaml index 00b92235f3..bfcaecb7aa 100644 --- a/kubernetes/portal/components/portal-sdk/requirements.yaml +++ b/kubernetes/portal/components/portal-sdk/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: certInitializer version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/portal/components/portal-sdk/templates/deployment.yaml b/kubernetes/portal/components/portal-sdk/templates/deployment.yaml index 75427d1093..95247b3dd2 100644 --- a/kubernetes/portal/components/portal-sdk/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-sdk/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: initContainers: - name: {{ include "common.name" . }}-readiness - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /app/ready.py @@ -52,7 +52,7 @@ spec: apiVersion: v1 fieldPath: metadata.namespace - name: {{ include "common.name" . }}-portalsdk-config - image: "{{ .Values.global.envsubstImage }}" + image: {{ include "repositoryGenerator.image.envsubst" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - sh @@ -90,7 +90,7 @@ spec: {{ include "common.certInitializer.initContainer" . | indent 6 }} containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: ["bash","-c"] {{- if .Values.global.aafEnabled }} @@ -161,7 +161,7 @@ spec: {{ toYaml .Values.affinity | indent 10 }} {{- end }} - name: filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - mountPath: /usr/share/filebeat/filebeat.yml diff --git a/kubernetes/portal/components/portal-sdk/values.yaml b/kubernetes/portal/components/portal-sdk/values.yaml index dc27aaeb92..11ce5a6e42 100644 --- a/kubernetes/portal/components/portal-sdk/values.yaml +++ b/kubernetes/portal/components/portal-sdk/values.yaml @@ -20,11 +20,7 @@ global: env: tomcatDir: "/usr/local/tomcat" nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 persistence: {} - envsubstImage: dibi/envsubst #AAF service aafEnabled: true @@ -56,7 +52,6 @@ secrets: ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/portal-sdk:3.4.2 pullPolicy: Always diff --git a/kubernetes/portal/components/portal-widget/requirements.yaml b/kubernetes/portal/components/portal-widget/requirements.yaml index c5d7864b9d..7c92350367 100644 --- a/kubernetes/portal/components/portal-widget/requirements.yaml +++ b/kubernetes/portal/components/portal-widget/requirements.yaml @@ -16,3 +16,6 @@ dependencies: - name: common version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/portal/components/portal-widget/templates/deployment.yaml b/kubernetes/portal/components/portal-widget/templates/deployment.yaml index eb6fc9eeee..246257651a 100644 --- a/kubernetes/portal/components/portal-widget/templates/deployment.yaml +++ b/kubernetes/portal/components/portal-widget/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: initContainers: - name: {{ include "common.name" . }}-readiness - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /app/ready.py @@ -52,7 +52,7 @@ spec: apiVersion: v1 fieldPath: metadata.namespace - name: {{ include "common.name" . }}-portal-widget-config - image: "{{ .Values.global.envsubstImage }}" + image: {{ include "repositoryGenerator.image.envsubst" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - sh @@ -87,7 +87,7 @@ spec: name: properties-onapwidgetms containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /start-wms.sh diff --git a/kubernetes/portal/components/portal-widget/values.yaml b/kubernetes/portal/components/portal-widget/values.yaml index f1fddde824..f86ff85f75 100644 --- a/kubernetes/portal/components/portal-widget/values.yaml +++ b/kubernetes/portal/components/portal-widget/values.yaml @@ -18,11 +18,6 @@ ################################################################# global: nodePortPrefix: 302 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - ubuntuInit: ubuntu-init:1.0.0 - envsubstImage: dibi/envsubst ################################################################ # Secrets metaconfig @@ -67,7 +62,6 @@ config: # Application configuration defaults. ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/portal-wms:3.4.2 pullPolicy: Always diff --git a/kubernetes/robot b/kubernetes/robot index 4e61a1c981..37ac984e35 160000 --- a/kubernetes/robot +++ b/kubernetes/robot @@ -1 +1 @@ -Subproject commit 4e61a1c981b7e00846c0ca2857cd32be027294e1 +Subproject commit 37ac984e35503182f7fc1b771cefa16bf0c84203 diff --git a/kubernetes/sdc/components/sdc-be/values.yaml b/kubernetes/sdc/components/sdc-be/values.yaml index a44176f964..5903c919e7 100644 --- a/kubernetes/sdc/components/sdc-be/values.yaml +++ b/kubernetes/sdc/components/sdc-be/values.yaml @@ -39,8 +39,8 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdc-backend-all-plugins:1.7.2 -backendInitImage: onap/sdc-backend-init:1.7.2 +image: onap/sdc-backend-all-plugins:1.7.3 +backendInitImage: onap/sdc-backend-init:1.7.3 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/sdc/components/sdc-cs/values.yaml b/kubernetes/sdc/components/sdc-cs/values.yaml index 589d530419..efe6dcddea 100644 --- a/kubernetes/sdc/components/sdc-cs/values.yaml +++ b/kubernetes/sdc/components/sdc-cs/values.yaml @@ -38,8 +38,8 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdc-cassandra:1.7.2 -cassandraInitImage: onap/sdc-cassandra-init:1.7.2 +image: onap/sdc-cassandra:1.7.3 +cassandraInitImage: onap/sdc-cassandra-init:1.7.3 pullPolicy: Always diff --git a/kubernetes/sdc/components/sdc-fe/values.yaml b/kubernetes/sdc/components/sdc-fe/values.yaml index 8cf3d26e8e..55dfcf14d5 100644 --- a/kubernetes/sdc/components/sdc-fe/values.yaml +++ b/kubernetes/sdc/components/sdc-fe/values.yaml @@ -51,7 +51,7 @@ certInitializer: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdc-frontend:1.7.2 +image: onap/sdc-frontend:1.7.3 pullPolicy: Always config: diff --git a/kubernetes/sdc/components/sdc-onboarding-be/templates/deployment.yaml b/kubernetes/sdc/components/sdc-onboarding-be/templates/deployment.yaml index 74757c7be2..9d14dfe5b5 100644 --- a/kubernetes/sdc/components/sdc-onboarding-be/templates/deployment.yaml +++ b/kubernetes/sdc/components/sdc-onboarding-be/templates/deployment.yaml @@ -92,6 +92,27 @@ spec: cpu: 3m memory: 20Mi {{- end }} + - name: volume-permissions + image: {{ .Values.global.busyboxRepository | default .Values.busyboxRepository }}/{{ .Values.global.busyboxImage | default .Values.busyboxImage }} + imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} + command: + - sh + args: + - "-c" + - | + chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.fsGroup }} //onboard/cert + securityContext: + runAsUser: 0 + volumeMounts: + - name: {{ include "common.fullname" . }}-cert-storage + mountPath: "/onboard/cert" + resources: + limits: + cpu: 100m + memory: 100Mi + requests: + cpu: 3m + memory: 20Mi containers: - name: {{ include "common.name" . }} image: "{{ include "common.repository" . }}/{{ .Values.image }}" diff --git a/kubernetes/sdc/components/sdc-onboarding-be/values.yaml b/kubernetes/sdc/components/sdc-onboarding-be/values.yaml index 0d12f074e6..f608dac644 100644 --- a/kubernetes/sdc/components/sdc-onboarding-be/values.yaml +++ b/kubernetes/sdc/components/sdc-onboarding-be/values.yaml @@ -63,8 +63,8 @@ certInitializer: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdc-onboard-backend:1.7.2 -onboardingInitImage: onap/sdc-onboard-cassandra-init:1.7.2 +image: onap/sdc-onboard-backend:1.7.3 +onboardingInitImage: onap/sdc-onboard-cassandra-init:1.7.3 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/sdc/values.yaml b/kubernetes/sdc/values.yaml index f6e0376067..bce40167f4 100644 --- a/kubernetes/sdc/values.yaml +++ b/kubernetes/sdc/values.yaml @@ -26,7 +26,7 @@ global: wf_external_user_password: S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0dHbUp2VXkyVQ== ubuntuInitRepository: oomk8s ubuntuInitImage: ubuntu-init:1.0.0 - busyboxRepository: registry.hub.docker.com + busyboxRepository: docker.io busyboxImage: library/busybox:latest aafEnabled: true cassandra: @@ -67,4 +67,4 @@ cassandra: # dependency / sub-chart configuration sdc-wfd: - enabled: true \ No newline at end of file + enabled: true diff --git a/kubernetes/sdnc/components/dmaap-listener/values.yaml b/kubernetes/sdnc/components/dmaap-listener/values.yaml index dfc1c53ebd..0f3f18b6b2 100644 --- a/kubernetes/sdnc/components/dmaap-listener/values.yaml +++ b/kubernetes/sdnc/components/dmaap-listener/values.yaml @@ -55,7 +55,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdnc-dmaap-listener-image:2.0.3 +image: onap/sdnc-dmaap-listener-image:2.0.4 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/sdnc/components/sdnc-ansible-server/values.yaml b/kubernetes/sdnc/components/sdnc-ansible-server/values.yaml index a674f78b4b..080ae9c15f 100644 --- a/kubernetes/sdnc/components/sdnc-ansible-server/values.yaml +++ b/kubernetes/sdnc/components/sdnc-ansible-server/values.yaml @@ -55,7 +55,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdnc-ansible-server-image:2.0.3 +image: onap/sdnc-ansible-server-image:2.0.4 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/sdnc/components/sdnc-web/values.yaml b/kubernetes/sdnc/components/sdnc-web/values.yaml index 7319e2272f..136379a7a2 100644 --- a/kubernetes/sdnc/components/sdnc-web/values.yaml +++ b/kubernetes/sdnc/components/sdnc-web/values.yaml @@ -27,7 +27,7 @@ global: ################################################################# # application image repository: nexus3.onap.org:10001 -image: "onap/sdnc-web-image:2.0.3" +image: "onap/sdnc-web-image:2.0.4" pullPolicy: Always config: diff --git a/kubernetes/sdnc/components/ueb-listener/values.yaml b/kubernetes/sdnc/components/ueb-listener/values.yaml index 33dbb792f9..2b0da14424 100644 --- a/kubernetes/sdnc/components/ueb-listener/values.yaml +++ b/kubernetes/sdnc/components/ueb-listener/values.yaml @@ -61,7 +61,7 @@ secrets: ################################################################# # application image repository: nexus3.onap.org:10001 -image: onap/sdnc-ueb-listener-image:2.0.3 +image: onap/sdnc-ueb-listener-image:2.0.4 pullPolicy: Always # flag to enable debugging - application support required diff --git a/kubernetes/sdnc/values.yaml b/kubernetes/sdnc/values.yaml index 77b4a0e274..7f6312fd5d 100644 --- a/kubernetes/sdnc/values.yaml +++ b/kubernetes/sdnc/values.yaml @@ -136,7 +136,7 @@ secrets: repository: nexus3.onap.org:10001 pullPolicy: Always -image: onap/sdnc-image:2.0.3 +image: onap/sdnc-image:2.0.4 busyboxRepository: docker.io busyboxImage: busybox:1.30 diff --git a/kubernetes/sniro-emulator/requirements.yaml b/kubernetes/sniro-emulator/requirements.yaml index e85005b9ae..a72069ff78 100644 --- a/kubernetes/sniro-emulator/requirements.yaml +++ b/kubernetes/sniro-emulator/requirements.yaml @@ -19,3 +19,6 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/sniro-emulator/templates/deployment.yaml b/kubernetes/sniro-emulator/templates/deployment.yaml index ed07bb65c5..0dff4eb7be 100644 --- a/kubernetes/sniro-emulator/templates/deployment.yaml +++ b/kubernetes/sniro-emulator/templates/deployment.yaml @@ -38,7 +38,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/sniro-emulator/values.yaml b/kubernetes/sniro-emulator/values.yaml index e81481da2d..81ce818a8a 100644 --- a/kubernetes/sniro-emulator/values.yaml +++ b/kubernetes/sniro-emulator/values.yaml @@ -19,7 +19,6 @@ global: # global defaults nodePortPrefix: 302 # application image -repository: nexus3.onap.org:10001 image: onap/sniroemulator:1.0.0 pullPolicy: IfNotPresent diff --git a/kubernetes/so/components/so-appc-orchestrator/requirements.yaml b/kubernetes/so/components/so-appc-orchestrator/requirements.yaml index 1feea23842..d25c12c663 100755 --- a/kubernetes/so/components/so-appc-orchestrator/requirements.yaml +++ b/kubernetes/so/components/so-appc-orchestrator/requirements.yaml @@ -18,6 +18,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-appc-orchestrator/templates/deployment.yaml b/kubernetes/so/components/so-appc-orchestrator/templates/deployment.yaml index 24592ba50a..917c067681 100644 --- a/kubernetes/so/components/so-appc-orchestrator/templates/deployment.yaml +++ b/kubernetes/so/components/so-appc-orchestrator/templates/deployment.yaml @@ -41,7 +41,7 @@ spec: env: - name: ACTUATOR_PASSWORD {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "server-actuator-creds" "key" "password") | indent 10 }} - image: {{ .Values.global.dockerHubRepository }}/{{ .Values.global.htpasswdImage }} + image: {{ include "repositoryGenerator.image.htpasswd" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: encoder @@ -62,7 +62,7 @@ spec: {{- end }} {{- end }} /app/start-app.sh - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} env: - name: ACTUATOR_USERNAME diff --git a/kubernetes/so/components/so-appc-orchestrator/values.yaml b/kubernetes/so/components/so-appc-orchestrator/values.yaml index 7570116fd5..310cb9f323 100644 --- a/kubernetes/so/components/so-appc-orchestrator/values.yaml +++ b/kubernetes/so/components/so-appc-orchestrator/values.yaml @@ -19,14 +19,8 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - envsubstImage: dibi/envsubst - aafAgentImage: onap/aaf/aaf_agent:2.1.20 persistence: mountPath: /dockerdata-nfs - htpasswdImage: xmartlabs/htpasswd - dockerHubRepository: docker.io security: aaf: enabled: false @@ -63,7 +57,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/so-appc-orchestrator:1.6.4 pullPolicy: Always diff --git a/kubernetes/so/components/so-bpmn-infra/requirements.yaml b/kubernetes/so/components/so-bpmn-infra/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-bpmn-infra/requirements.yaml +++ b/kubernetes/so/components/so-bpmn-infra/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-bpmn-infra/templates/deployment.yaml b/kubernetes/so/components/so-bpmn-infra/templates/deployment.yaml index ac335c859a..3fee225c03 100755 --- a/kubernetes/so/components/so-bpmn-infra/templates/deployment.yaml +++ b/kubernetes/so/components/so-bpmn-infra/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -92,7 +92,7 @@ spec: protocol: TCP # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/components/so-bpmn-infra/values.yaml b/kubernetes/so/components/so-bpmn-infra/values.yaml index 2bb7d7b44c..63011474bf 100755 --- a/kubernetes/so/components/so-bpmn-infra/values.yaml +++ b/kubernetes/so/components/so-bpmn-infra/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs #This configuration specifies Service and port for SDNC OAM interface @@ -66,7 +62,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/bpmn-infra:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-catalog-db-adapter/requirements.yaml b/kubernetes/so/components/so-catalog-db-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-catalog-db-adapter/requirements.yaml +++ b/kubernetes/so/components/so-catalog-db-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-catalog-db-adapter/templates/deployment.yaml b/kubernetes/so/components/so-catalog-db-adapter/templates/deployment.yaml index 0aac5f4b48..75e6b1ee62 100755 --- a/kubernetes/so/components/so-catalog-db-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-catalog-db-adapter/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: diff --git a/kubernetes/so/components/so-catalog-db-adapter/values.yaml b/kubernetes/so/components/so-catalog-db-adapter/values.yaml index b27566d336..81a7c3fba1 100755 --- a/kubernetes/so/components/so-catalog-db-adapter/values.yaml +++ b/kubernetes/so/components/so-catalog-db-adapter/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -65,7 +61,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/catalog-db-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/requirements.yaml b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/requirements.yaml index 1feea23842..d25c12c663 100755 --- a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/requirements.yaml +++ b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/requirements.yaml @@ -18,6 +18,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/templates/deployment.yaml b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/templates/deployment.yaml index fa5f42d5ab..2cf23e23be 100644 --- a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/templates/deployment.yaml +++ b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/templates/deployment.yaml @@ -46,7 +46,7 @@ spec: {{- end }} {{- end }} ./start-app.sh - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} env: - name: ETSI_NFVO_USERNAME diff --git a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/values.yaml b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/values.yaml index 0612f506c5..f5ad18faf6 100644 --- a/kubernetes/so/components/so-etsi-nfvo-ns-lcm/values.yaml +++ b/kubernetes/so/components/so-etsi-nfvo-ns-lcm/values.yaml @@ -17,10 +17,6 @@ ################################################################# global: nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -59,7 +55,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/so-etsi-nfvo-ns-lcm:1.7.7 pullPolicy: Always diff --git a/kubernetes/so/components/so-mariadb/requirements.yaml b/kubernetes/so/components/so-mariadb/requirements.yaml index 22d6333253..0dfef90cff 100755 --- a/kubernetes/so/components/so-mariadb/requirements.yaml +++ b/kubernetes/so/components/so-mariadb/requirements.yaml @@ -18,6 +18,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: readinessCheck version: ~6.x-0 repository: '@local' diff --git a/kubernetes/so/components/so-mariadb/templates/job.yaml b/kubernetes/so/components/so-mariadb/templates/job.yaml index b3bacc1ed4..0eeba7b61a 100644 --- a/kubernetes/so/components/so-mariadb/templates/job.yaml +++ b/kubernetes/so/components/so-mariadb/templates/job.yaml @@ -39,7 +39,7 @@ spec: spec: containers: - name: {{ include "common.fullname" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: DB_HOST @@ -98,7 +98,7 @@ spec: initContainers: {{ include "common.readinessCheck.waitFor" . | nindent 6 }} containers: - name: {{ include "common.name" . }}-config - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /bin/bash diff --git a/kubernetes/so/components/so-mariadb/values.yaml b/kubernetes/so/components/so-mariadb/values.yaml index 809dff77a7..2dfd5b831f 100755 --- a/kubernetes/so/components/so-mariadb/values.yaml +++ b/kubernetes/so/components/so-mariadb/values.yaml @@ -22,7 +22,7 @@ global: nodePortPrefixExt: 304 repository: nexus3.onap.org:10001 readinessImage: onap/oom/readiness:3.0.1 - ubuntuInitRepository: registry.hub.docker.com + ubuntuInitRepository: docker.io mariadbGalera: nameOverride: &mariadbName mariadb-galera serviceName: mariadb-galera diff --git a/kubernetes/so/components/so-monitoring/requirements.yaml b/kubernetes/so/components/so-monitoring/requirements.yaml index 29f9a9fcd0..b9be601082 100755 --- a/kubernetes/so/components/so-monitoring/requirements.yaml +++ b/kubernetes/so/components/so-monitoring/requirements.yaml @@ -19,6 +19,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-monitoring/templates/deployment.yaml b/kubernetes/so/components/so-monitoring/templates/deployment.yaml index 03eccc2d02..dc80d426fc 100644 --- a/kubernetes/so/components/so-monitoring/templates/deployment.yaml +++ b/kubernetes/so/components/so-monitoring/templates/deployment.yaml @@ -47,7 +47,7 @@ spec: spec: initContainers: {{ include "so.certificate.container_importer" . | nindent 6 }} - name: so-chown - image: alpine:3.6 + image: {{ include "repositoryGenerator.image.busybox" . }} volumeMounts: - name: logs mountPath: /app/logs @@ -56,7 +56,7 @@ spec: restartPolicy: Always containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} command: - /bin/sh diff --git a/kubernetes/so/components/so-nssmf-adapter/requirements.yaml b/kubernetes/so/components/so-nssmf-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-nssmf-adapter/requirements.yaml +++ b/kubernetes/so/components/so-nssmf-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-nssmf-adapter/templates/deployment.yaml b/kubernetes/so/components/so-nssmf-adapter/templates/deployment.yaml index 3b28c5bbdd..75d831eba6 100755 --- a/kubernetes/so/components/so-nssmf-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-nssmf-adapter/templates/deployment.yaml @@ -49,7 +49,7 @@ spec: {{- end }} {{- end }} ./start-app.sh - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} ports: {{- include "common.containerPorts" . | nindent 12 }} env: diff --git a/kubernetes/so/components/so-nssmf-adapter/values.yaml b/kubernetes/so/components/so-nssmf-adapter/values.yaml index 40a55c6c0b..b5cfe4eb41 100755 --- a/kubernetes/so/components/so-nssmf-adapter/values.yaml +++ b/kubernetes/so/components/so-nssmf-adapter/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -78,7 +74,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/nssmf-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-oof-adapter/requirements.yaml b/kubernetes/so/components/so-oof-adapter/requirements.yaml index 036860d012..3398a2d39d 100644 --- a/kubernetes/so/components/so-oof-adapter/requirements.yaml +++ b/kubernetes/so/components/so-oof-adapter/requirements.yaml @@ -19,6 +19,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-oof-adapter/templates/deployment.yaml b/kubernetes/so/components/so-oof-adapter/templates/deployment.yaml index 72799d1f5f..62ebfff99f 100755 --- a/kubernetes/so/components/so-oof-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-oof-adapter/templates/deployment.yaml @@ -32,7 +32,7 @@ spec: initContainers: {{ include "so.certificate.container_importer" . | nindent 6 }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | indent 10 }} env: @@ -71,7 +71,7 @@ spec: ports: {{- include "common.containerPorts" . | nindent 12 }} # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/components/so-oof-adapter/values.yaml b/kubernetes/so/components/so-oof-adapter/values.yaml index 6bddf29032..13a0f0f05e 100755 --- a/kubernetes/so/components/so-oof-adapter/values.yaml +++ b/kubernetes/so/components/so-oof-adapter/values.yaml @@ -18,11 +18,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessRepository: oomk8s - readinessImage: readiness-check:2.0.2 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -76,7 +71,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/so-oof-adapter:1.7.4 pullPolicy: Always diff --git a/kubernetes/so/components/so-openstack-adapter/requirements.yaml b/kubernetes/so/components/so-openstack-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-openstack-adapter/requirements.yaml +++ b/kubernetes/so/components/so-openstack-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-openstack-adapter/templates/deployment.yaml b/kubernetes/so/components/so-openstack-adapter/templates/deployment.yaml index ac335c859a..3fee225c03 100755 --- a/kubernetes/so/components/so-openstack-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-openstack-adapter/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -92,7 +92,7 @@ spec: protocol: TCP # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/components/so-openstack-adapter/values.yaml b/kubernetes/so/components/so-openstack-adapter/values.yaml index 129ad59385..392f8472d4 100755 --- a/kubernetes/so/components/so-openstack-adapter/values.yaml +++ b/kubernetes/so/components/so-openstack-adapter/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -63,7 +59,6 @@ secrets: ################################################################# image: onap/so/openstack-adapter:1.7.10 pullPolicy: Always -repository: nexus3.onap.org:10001 db: userName: so_user diff --git a/kubernetes/so/components/so-request-db-adapter/requirements.yaml b/kubernetes/so/components/so-request-db-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-request-db-adapter/requirements.yaml +++ b/kubernetes/so/components/so-request-db-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml b/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml index 0aac5f4b48..75e6b1ee62 100755 --- a/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-request-db-adapter/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: diff --git a/kubernetes/so/components/so-request-db-adapter/values.yaml b/kubernetes/so/components/so-request-db-adapter/values.yaml index e221870306..208cf64b6f 100755 --- a/kubernetes/so/components/so-request-db-adapter/values.yaml +++ b/kubernetes/so/components/so-request-db-adapter/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -61,7 +57,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/request-db-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-sdc-controller/requirements.yaml b/kubernetes/so/components/so-sdc-controller/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-sdc-controller/requirements.yaml +++ b/kubernetes/so/components/so-sdc-controller/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-sdc-controller/templates/deployment.yaml b/kubernetes/so/components/so-sdc-controller/templates/deployment.yaml index ac335c859a..3fee225c03 100755 --- a/kubernetes/so/components/so-sdc-controller/templates/deployment.yaml +++ b/kubernetes/so/components/so-sdc-controller/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -92,7 +92,7 @@ spec: protocol: TCP # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/components/so-sdc-controller/values.yaml b/kubernetes/so/components/so-sdc-controller/values.yaml index be3be26bc3..6dd662e9b2 100755 --- a/kubernetes/so/components/so-sdc-controller/values.yaml +++ b/kubernetes/so/components/so-sdc-controller/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -61,7 +57,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/sdc-controller:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-sdnc-adapter/requirements.yaml b/kubernetes/so/components/so-sdnc-adapter/requirements.yaml index 1feea23842..d25c12c663 100755 --- a/kubernetes/so/components/so-sdnc-adapter/requirements.yaml +++ b/kubernetes/so/components/so-sdnc-adapter/requirements.yaml @@ -18,6 +18,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-sdnc-adapter/templates/deployment.yaml b/kubernetes/so/components/so-sdnc-adapter/templates/deployment.yaml index 5186523ba1..6f9d7f7b16 100755 --- a/kubernetes/so/components/so-sdnc-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-sdnc-adapter/templates/deployment.yaml @@ -42,7 +42,7 @@ spec: initContainers: {{ include "so.certificate.container_importer" . | nindent 6 }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -90,7 +90,7 @@ spec: protocol: TCP # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/components/so-sdnc-adapter/values.yaml b/kubernetes/so/components/so-sdnc-adapter/values.yaml index cabd60e011..be58ae6154 100755 --- a/kubernetes/so/components/so-sdnc-adapter/values.yaml +++ b/kubernetes/so/components/so-sdnc-adapter/values.yaml @@ -17,10 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs #This configuration specifies Service and port for SDNC OAM interface @@ -60,7 +56,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/sdnc-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-ve-vnfm-adapter/requirements.yaml b/kubernetes/so/components/so-ve-vnfm-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-ve-vnfm-adapter/requirements.yaml +++ b/kubernetes/so/components/so-ve-vnfm-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-ve-vnfm-adapter/templates/deployment.yaml b/kubernetes/so/components/so-ve-vnfm-adapter/templates/deployment.yaml index 7c528b0290..ac4f574bec 100755 --- a/kubernetes/so/components/so-ve-vnfm-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-ve-vnfm-adapter/templates/deployment.yaml @@ -19,7 +19,7 @@ kind: Deployment metadata: {{- include "common.resourceMetadata" . | nindent 2 }} spec: selector: {{- include "common.selectors" . | nindent 4 }} - replicas: {{ index .Values.replicaCount }} + replicas: {{ .Values.replicaCount }} template: metadata: labels: {{- include "common.labels" . | nindent 8 }} @@ -31,7 +31,7 @@ spec: envFrom: - configMapRef: name: {{ include "common.fullname" . }}-configmap - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: {{ include "so.certificate.volumeMount" . | nindent 12 }} @@ -42,11 +42,11 @@ spec: readOnly: true livenessProbe: tcpSocket: - port: {{ index .Values.livenessProbe.port }} - initialDelaySeconds: {{ index .Values.livenessProbe.initialDelaySeconds}} - periodSeconds: {{ index .Values.livenessProbe.periodSeconds}} - successThreshold: {{ index .Values.livenessProbe.successThreshold}} - failureThreshold: {{ index .Values.livenessProbe.failureThreshold}} + port: {{ .Values.livenessProbe.port }} + initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds}} + periodSeconds: {{ .Values.livenessProbe.periodSeconds}} + successThreshold: {{ .Values.livenessProbe.successThreshold}} + failureThreshold: {{ .Values.livenessProbe.failureThreshold}} ports: {{- include "common.containerPorts" . | nindent 10 }} volumes: {{ include "so.certificate.volumes" . | nindent 8 }} - name: logs diff --git a/kubernetes/so/components/so-ve-vnfm-adapter/values.yaml b/kubernetes/so/components/so-ve-vnfm-adapter/values.yaml index 9237b994ac..83ec78d857 100755 --- a/kubernetes/so/components/so-ve-vnfm-adapter/values.yaml +++ b/kubernetes/so/components/so-ve-vnfm-adapter/values.yaml @@ -15,10 +15,6 @@ # Global configuration defaults. ################################################################# global: - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs diff --git a/kubernetes/so/components/so-vfc-adapter/requirements.yaml b/kubernetes/so/components/so-vfc-adapter/requirements.yaml index b0bda362dd..82296bee1d 100755 --- a/kubernetes/so/components/so-vfc-adapter/requirements.yaml +++ b/kubernetes/so/components/so-vfc-adapter/requirements.yaml @@ -21,6 +21,9 @@ dependencies: - name: readinessCheck version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-vfc-adapter/templates/deployment.yaml b/kubernetes/so/components/so-vfc-adapter/templates/deployment.yaml index 94759ced65..7c10e7f8ed 100755 --- a/kubernetes/so/components/so-vfc-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-vfc-adapter/templates/deployment.yaml @@ -26,13 +26,13 @@ spec: selector: matchLabels: app: {{ include "common.name" . }} - replicas: {{ index .Values.replicaCount }} - minReadySeconds: {{ index .Values.minReadySeconds }} + replicas: {{ .Values.replicaCount }} + minReadySeconds: {{ .Values.minReadySeconds }} strategy: - type: {{ index .Values.updateStrategy.type }} + type: {{ .Values.updateStrategy.type }} rollingUpdate: - maxUnavailable: {{ index .Values.updateStrategy.maxUnavailable }} - maxSurge: {{ index .Values.updateStrategy.maxSurge }} + maxUnavailable: {{ .Values.updateStrategy.maxUnavailable }} + maxSurge: {{ .Values.updateStrategy.maxSurge }} template: metadata: labels: @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -85,16 +85,16 @@ spec: readOnly: true livenessProbe: httpGet: - path: {{- index .Values.livenessProbe.path|indent 2}} - port: {{ index .Values.containerPort }} - scheme: {{- index .Values.livenessProbe.scheme| indent 2}} - initialDelaySeconds: {{ index .Values.livenessProbe.initialDelaySeconds}} - periodSeconds: {{ index .Values.livenessProbe.periodSeconds}} - timeoutSeconds: {{ index .Values.livenessProbe.timeoutSeconds}} - successThreshold: {{ index .Values.livenessProbe.successThreshold}} - failureThreshold: {{ index .Values.livenessProbe.failureThreshold}} + path: {{- .Values.livenessProbe.path|indent 2}} + port: {{ .Values.containerPort }} + scheme: {{- .Values.livenessProbe.scheme| indent 2}} + initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds}} + periodSeconds: {{ .Values.livenessProbe.periodSeconds}} + timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds}} + successThreshold: {{ .Values.livenessProbe.successThreshold}} + failureThreshold: {{ .Values.livenessProbe.failureThreshold}} ports: - - containerPort: {{ index .Values.containerPort }} + - containerPort: {{ .Values.containerPort }} name: {{ .Values.service.portName }} protocol: TCP volumes: {{ include "so.certificate.volumes" . | nindent 6 }} diff --git a/kubernetes/so/components/so-vfc-adapter/values.yaml b/kubernetes/so/components/so-vfc-adapter/values.yaml index f88e117fae..698cbf4b63 100755 --- a/kubernetes/so/components/so-vfc-adapter/values.yaml +++ b/kubernetes/so/components/so-vfc-adapter/values.yaml @@ -17,9 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 persistence: mountPath: /dockerdata-nfs security: @@ -60,7 +57,6 @@ secrets: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/vfc-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/so-vnfm-adapter/requirements.yaml b/kubernetes/so/components/so-vnfm-adapter/requirements.yaml index 1feea23842..d25c12c663 100755 --- a/kubernetes/so/components/so-vnfm-adapter/requirements.yaml +++ b/kubernetes/so/components/so-vnfm-adapter/requirements.yaml @@ -18,6 +18,9 @@ dependencies: # a part of this chart's package and will not # be published independently to a repo (at this point) repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://../soHelpers' diff --git a/kubernetes/so/components/so-vnfm-adapter/templates/deployment.yaml b/kubernetes/so/components/so-vnfm-adapter/templates/deployment.yaml index 24dd3d6d21..8abd9a9796 100755 --- a/kubernetes/so/components/so-vnfm-adapter/templates/deployment.yaml +++ b/kubernetes/so/components/so-vnfm-adapter/templates/deployment.yaml @@ -26,13 +26,13 @@ spec: selector: matchLabels: app: {{ include "common.name" . }} - replicas: {{ index .Values.replicaCount }} - minReadySeconds: {{ index .Values.minReadySeconds }} + replicas: {{ .Values.replicaCount }} + minReadySeconds: {{ .Values.minReadySeconds }} strategy: - type: {{ index .Values.updateStrategy.type }} + type: {{ .Values.updateStrategy.type }} rollingUpdate: - maxUnavailable: {{ index .Values.updateStrategy.maxUnavailable }} - maxSurge: {{ index .Values.updateStrategy.maxSurge }} + maxUnavailable: {{ .Values.updateStrategy.maxUnavailable }} + maxSurge: {{ .Values.updateStrategy.maxSurge }} template: metadata: labels: @@ -42,7 +42,7 @@ spec: initContainers: {{ include "so.certificate.container_importer" . | nindent 6 }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -70,13 +70,13 @@ spec: readOnly: true livenessProbe: tcpSocket: - port: {{ index .Values.livenessProbe.port }} - initialDelaySeconds: {{ index .Values.livenessProbe.initialDelaySeconds}} - periodSeconds: {{ index .Values.livenessProbe.periodSeconds}} - successThreshold: {{ index .Values.livenessProbe.successThreshold}} - failureThreshold: {{ index .Values.livenessProbe.failureThreshold}} + port: {{ .Values.livenessProbe.port }} + initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds}} + periodSeconds: {{ .Values.livenessProbe.periodSeconds}} + successThreshold: {{ .Values.livenessProbe.successThreshold}} + failureThreshold: {{ .Values.livenessProbe.failureThreshold}} ports: - - containerPort: {{ index .Values.containerPort }} + - containerPort: {{ .Values.containerPort }} name: {{ .Values.service.portName }} protocol: TCP volumes: {{ include "so.certificate.volumes" . | nindent 6 }} diff --git a/kubernetes/so/components/so-vnfm-adapter/values.yaml b/kubernetes/so/components/so-vnfm-adapter/values.yaml index f8fa7c93be..6aebf31932 100755 --- a/kubernetes/so/components/so-vnfm-adapter/values.yaml +++ b/kubernetes/so/components/so-vnfm-adapter/values.yaml @@ -16,10 +16,6 @@ ################################################################# global: nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - aafAgentImage: onap/aaf/aaf_agent:2.1.20 - envsubstImage: dibi/envsubst persistence: mountPath: /dockerdata-nfs security: @@ -32,7 +28,6 @@ global: ################################################################# # Application configuration defaults. ################################################################# -repository: nexus3.onap.org:10001 image: onap/so/vnfm-adapter:1.7.10 pullPolicy: Always diff --git a/kubernetes/so/components/soHelpers/templates/_certificates.tpl b/kubernetes/so/components/soHelpers/templates/_certificates.tpl index d148a1cd60..66497e1afa 100644 --- a/kubernetes/so/components/soHelpers/templates/_certificates.tpl +++ b/kubernetes/so/components/soHelpers/templates/_certificates.tpl @@ -5,7 +5,7 @@ {{ include "common.certInitializer.initContainer" $subchartDot }} {{- if $dot.Values.global.aafEnabled }} - name: {{ include "common.name" $dot }}-msb-cert-importer - image: "{{ include "common.repository" $subchartDot }}/{{ $dot.Values.global.aafAgentImage }}" + image: {{ include "repositoryGenerator.repository" $subchartDot }}/{{ $dot.Values.global.aafAgentImage }} imagePullPolicy: {{ $dot.Values.global.pullPolicy | default $subchartDot.Values.pullPolicy }} command: - "/bin/sh" diff --git a/kubernetes/so/components/soHelpers/values.yaml b/kubernetes/so/components/soHelpers/values.yaml index 391938199e..a367272d9a 100755 --- a/kubernetes/so/components/soHelpers/values.yaml +++ b/kubernetes/so/components/soHelpers/values.yaml @@ -15,7 +15,6 @@ # Global configuration defaults. ################################################################# global: - soBaseImage: onap/so/base-image:1.0 aafAgentImage: onap/aaf/aaf_agent:2.1.20 msbEnabled: true security: diff --git a/kubernetes/so/requirements.yaml b/kubernetes/so/requirements.yaml index bbd84cfcfd..2e0a40610d 100755 --- a/kubernetes/so/requirements.yaml +++ b/kubernetes/so/requirements.yaml @@ -25,6 +25,9 @@ dependencies: version: ~6.x-0 repository: '@local' condition: global.mariadbGalera.localCluster + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' - name: soHelpers version: ~6.x-0 repository: 'file://components/soHelpers' diff --git a/kubernetes/so/templates/deployment.yaml b/kubernetes/so/templates/deployment.yaml index ac335c859a..3fee225c03 100755 --- a/kubernetes/so/templates/deployment.yaml +++ b/kubernetes/so/templates/deployment.yaml @@ -44,7 +44,7 @@ spec: {{ include "common.readinessCheck.waitFor" . | indent 6 | trim }} containers: - name: {{ include "common.name" . }} - image: {{ include "common.repository" . }}/{{ .Values.image }} + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} resources: {{ include "common.resources" . | nindent 12 }} {{- if .Values.global.aafEnabled }} command: @@ -92,7 +92,7 @@ spec: protocol: TCP # Filebeat sidecar container - name: {{ include "common.name" . }}-filebeat-onap - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}" + image: {{ include "repositoryGenerator.image.logging" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} volumeMounts: - name: {{ include "common.fullname" . }}-filebeat-conf diff --git a/kubernetes/so/values.yaml b/kubernetes/so/values.yaml index 05df60bb0b..de1918b7ae 100755 --- a/kubernetes/so/values.yaml +++ b/kubernetes/so/values.yaml @@ -17,11 +17,6 @@ global: nodePortPrefix: 302 nodePortPrefixExt: 304 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - soBaseImage: onap/so/base-image:1.0 aafAgentImage: onap/aaf/aaf_agent:2.1.20 mariadbGalera: nameOverride: mariadb-galera @@ -146,7 +141,6 @@ dbCreds: userName: so_user adminName: so_admin -repository: nexus3.onap.org:10001 image: onap/so/api-handler-infra:1.7.10 pullPolicy: Always replicaCount: 1 diff --git a/kubernetes/uui/charts/uui-server/templates/deployment.yaml b/kubernetes/uui/charts/uui-server/templates/deployment.yaml index 55b7b23426..ea6f7b7a23 100644 --- a/kubernetes/uui/charts/uui-server/templates/deployment.yaml +++ b/kubernetes/uui/charts/uui-server/templates/deployment.yaml @@ -37,7 +37,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} ports: - containerPort: {{ .Values.service.internalPort }} diff --git a/kubernetes/uui/requirements.yaml b/kubernetes/uui/requirements.yaml index cf085205ab..8f74b745d3 100644 --- a/kubernetes/uui/requirements.yaml +++ b/kubernetes/uui/requirements.yaml @@ -18,4 +18,7 @@ dependencies: # local reference to common chart, as it is # a part of this chart's package and will not # be published independently to a repo (at this point) + repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 repository: '@local' \ No newline at end of file diff --git a/kubernetes/uui/templates/deployment.yaml b/kubernetes/uui/templates/deployment.yaml index ef73642095..8c523b2388 100644 --- a/kubernetes/uui/templates/deployment.yaml +++ b/kubernetes/uui/templates/deployment.yaml @@ -37,7 +37,7 @@ spec: spec: containers: - name: {{ include "common.name" . }} - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} command: - /bin/bash diff --git a/kubernetes/uui/values.yaml b/kubernetes/uui/values.yaml index 77351f9f3e..1adb2565a0 100644 --- a/kubernetes/uui/values.yaml +++ b/kubernetes/uui/values.yaml @@ -17,7 +17,6 @@ # Declare variables to be passed into your templates. global: uuiPortPrefix: 303 - readinessImage: onap/oom/readiness:3.0.1 subChartsOnly: enabled: true @@ -25,7 +24,6 @@ subChartsOnly: flavor: small # application image -repository: nexus3.onap.org:10001 image: onap/usecase-ui:3.0.6 pullPolicy: Always diff --git a/kubernetes/vid/requirements.yaml b/kubernetes/vid/requirements.yaml index e7764e08e8..ed8b8057d9 100644 --- a/kubernetes/vid/requirements.yaml +++ b/kubernetes/vid/requirements.yaml @@ -22,3 +22,9 @@ dependencies: - name: mariadb-galera version: ~6.x-0 repository: '@local' + condition: global.mariadbGalera.localCluster + - name: mariadb-init + version: ~6.x-0 + repository: '@local' + condition: not global.mariadbGalera.localCluster + diff --git a/kubernetes/vid/resources/config/db_cmd.sh b/kubernetes/vid/resources/config/db_cmd.sh old mode 100644 new mode 100755 index e573c02f9f..efd92b223f --- a/kubernetes/vid/resources/config/db_cmd.sh +++ b/kubernetes/vid/resources/config/db_cmd.sh @@ -1,6 +1,7 @@ #!/bin/sh {{/* # Copyright © 2018 AT&T +# Copyright © 2020 Aarna Networks # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -15,10 +16,29 @@ # limitations under the License. */}} -echo "Going to run mysql -u${MYSQL_USER} -p${MYSQL_PASSWORD} -h${MYSQL_HOST} -P${MYSQL_PORT} ..." -mysql -u${MYSQL_USER} -p${MYSQL_PASSWORD} -h${MYSQL_HOST} -P${MYSQL_PORT} < /db-config/vid-pre-init.sql +DB={{index .Values "mariadb-galera" "config" "mysqlDatabase" | upper }} +eval "MYSQL_USER=\$MYSQL_USER_${DB}" +eval "MYSQL_PASSWORD=\$MYSQL_PASSWORD_${DB}" + +#echo "Going to run mysql ${DB} -u${MYSQL_USER} -p${MYSQL_PASSWORD} -h${DB_HOST} -P${DB_PORT} ..." +mysql -u${MYSQL_USER} -p${MYSQL_PASSWORD} -h${DB_HOST} -P${DB_PORT} <<'EOD' +CREATE TABLE IF NOT EXISTS `{{index .Values "mariadb-galera" "config" "mysqlDatabase" }}`.`schema_info` ( +`SCHEMA_ID` VARCHAR(25) NOT NULL, +`SCHEMA_DESC` VARCHAR(75) NOT NULL, +`DATASOURCE_TYPE` VARCHAR(100) NULL DEFAULT NULL, +`CONNECTION_URL` VARCHAR(200) NOT NULL, +`USER_NAME` VARCHAR(45) NOT NULL, +`PASSWORD` VARCHAR(45) NULL DEFAULT NULL, +`DRIVER_CLASS` VARCHAR(100) NOT NULL, +`MIN_POOL_SIZE` INT(11) NOT NULL, +`MAX_POOL_SIZE` INT(11) NOT NULL, +`IDLE_CONNECTION_TEST_PERIOD` INT(11) NOT NULL) +ENGINE = InnoDB +DEFAULT CHARACTER SET = utf8; +EOD + if [ $? -ne 0 ];then - echo "ERROR: Failed to run ${cmd} vid-pre-init.sql" + echo "ERROR: Failed to run cmd vid-pre-init.sql" exit 1 else echo "INFO: Database initialized successfully" diff --git a/kubernetes/vid/resources/config/vid-pre-init.sql b/kubernetes/vid/resources/config/vid-pre-init.sql deleted file mode 100644 index 2dbbbcce6d..0000000000 --- a/kubernetes/vid/resources/config/vid-pre-init.sql +++ /dev/null @@ -1,29 +0,0 @@ -/* -# Copyright © 2018 AT&T -# -# 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. -*/ - -CREATE TABLE IF NOT EXISTS `vid_openecomp_epsdk`.`schema_info` ( -`SCHEMA_ID` VARCHAR(25) NOT NULL, -`SCHEMA_DESC` VARCHAR(75) NOT NULL, -`DATASOURCE_TYPE` VARCHAR(100) NULL DEFAULT NULL, -`CONNECTION_URL` VARCHAR(200) NOT NULL, -`USER_NAME` VARCHAR(45) NOT NULL, -`PASSWORD` VARCHAR(45) NULL DEFAULT NULL, -`DRIVER_CLASS` VARCHAR(100) NOT NULL, -`MIN_POOL_SIZE` INT(11) NOT NULL, -`MAX_POOL_SIZE` INT(11) NOT NULL, -`IDLE_CONNECTION_TEST_PERIOD` INT(11) NOT NULL) -ENGINE = InnoDB -DEFAULT CHARACTER SET = utf8; \ No newline at end of file diff --git a/kubernetes/vid/templates/configmap.yaml b/kubernetes/vid/templates/configmap.yaml index b1509a95ad..0ba466dfb9 100644 --- a/kubernetes/vid/templates/configmap.yaml +++ b/kubernetes/vid/templates/configmap.yaml @@ -43,7 +43,7 @@ data: apiVersion: v1 kind: ConfigMap metadata: - name: {{ include "common.fullname" . }} + name: {{ include "common.fullname" . }}-db-init namespace: {{ include "common.namespace" . }} labels: app: {{ include "common.name" . }} @@ -51,4 +51,4 @@ metadata: release: {{ include "common.release" . }} heritage: {{ .Release.Service }} data: -{{ tpl (.Files.Glob "resources/config/*").AsConfig . | indent 2 }} \ No newline at end of file +{{ tpl (.Files.Glob "resources/config/db_cmd.sh").AsConfig . | indent 2 }} diff --git a/kubernetes/vid/templates/deployment.yaml b/kubernetes/vid/templates/deployment.yaml index 5423febaf5..41b0019cbe 100644 --- a/kubernetes/vid/templates/deployment.yaml +++ b/kubernetes/vid/templates/deployment.yaml @@ -41,7 +41,7 @@ spec: - /app/ready.py args: - --job-name - - {{ include "common.fullname" . }}-galera-config + - {{ include "common.fullname" . }}-mariadb-init-config-job env: - name: NAMESPACE valueFrom: @@ -105,9 +105,9 @@ spec: - name: VID_UEB_URL_LIST value: message-router.{{ include "common.namespace" . }} - name: VID_MYSQL_HOST - value: {{ index .Values "mariadb-galera" "service" "name" }} + value: {{ include "common.mariadbService" . }} - name: VID_MYSQL_PORT - value: "{{ index .Values "mariadb-galera" "service" "internalPort" }}" + value: "{{ include "common.mariadbPort" . }}" - name: VID_MYSQL_DBNAME value: {{ index .Values "mariadb-galera" "config" "mysqlDatabase" }} - name: VID_MYSQL_USER diff --git a/kubernetes/vid/templates/job.yaml b/kubernetes/vid/templates/job.yaml deleted file mode 100644 index b051cdec36..0000000000 --- a/kubernetes/vid/templates/job.yaml +++ /dev/null @@ -1,82 +0,0 @@ -{{/* -# Copyright © 2018 Amdocs, Bell Canada -# Copyright © 2020 Samsung Electronics -# -# 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: batch/v1 -kind: Job -metadata: - name: {{ include "common.fullname" . }}-galera-config - namespace: {{ include "common.namespace" . }} - labels: - app: {{ include "common.name" . }}-job - release: {{ include "common.release" . }} -spec: - template: - metadata: - labels: - app: {{ include "common.name" . }}-job - release: {{ include "common.release" . }} - spec: - initContainers: -#This container checks that all galera instances are up before initializing it. - - name: {{ include "common.name" . }}-readiness - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" - imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - command: - - /app/ready.py - - --container-name - - {{ index .Values "mariadb-galera" "service" "name" }} - env: - - name: NAMESPACE - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: metadata.namespace - containers: - - name: {{ include "common.name" . }}-job - image: {{ .Values.mariadb_image }} - imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} - volumeMounts: - - mountPath: /dbcmd-config/db_cmd.sh - name: {{ include "common.fullname" . }}-config - subPath: db_cmd.sh - - mountPath: /db-config/vid-pre-init.sql - name: {{ include "common.fullname" . }}-config - subPath: vid-pre-init.sql - command: - - /bin/sh - args: - - -x - - /dbcmd-config/db_cmd.sh - env: - - name: MYSQL_PASSWORD - {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "vid-db-user-secret" "key" "password") | indent 10 }} - - name: MYSQL_HOST - value: {{ index .Values "mariadb-galera" "service" "name" }} - - name: MYSQL_USER - {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "vid-db-user-secret" "key" "login") | indent 10 }} - - name: MYSQL_PORT - value: "{{ index .Values "mariadb-galera" "service" "internalPort" }}" - restartPolicy: Never - volumes: - - name: {{ include "common.fullname" . }}-config - configMap: - name: {{ include "common.fullname" . }} - items: - - key: db_cmd.sh - path: db_cmd.sh - - key: vid-pre-init.sql - path: vid-pre-init.sql diff --git a/kubernetes/vid/values.yaml b/kubernetes/vid/values.yaml index 3c9b8ceb63..93de57e4b3 100644 --- a/kubernetes/vid/values.yaml +++ b/kubernetes/vid/values.yaml @@ -21,6 +21,12 @@ global: readinessImage: onap/oom/readiness:3.0.1 loggingRepository: docker.elastic.co loggingImage: beats/filebeat:5.5.0 + mariadbGalera: &mariadbGalera + #This flag allows VID to instantiate its own mariadb-galera cluster + localCluster: false + service: mariadb-galera + internalPort: 3306 + nameOverride: mariadb-galera ################################################################# # Secrets metaconfig @@ -41,9 +47,6 @@ repository: nexus3.onap.org:10001 image: onap/vid:7.0.0 pullPolicy: Always -# mariadb image for initializing -mariadb_image: library/mariadb:10 - # application configuration config: db: @@ -67,7 +70,9 @@ config: roleaccesscentralized: remote mariadb-galera: - config: + # '&mariadbConfig' means we "store" the values for later use in the file + # with '*mariadbConfig' pointer. + config: &mariadbConfig userCredentialsExternalSecret: '{{ include "common.release" . }}-vid-db-user-secret' mysqlDatabase: vid_openecomp_epsdk nameOverride: vid-galera @@ -83,6 +88,13 @@ mariadb-galera: [mysqld] lower_case_table_names = 1 +mariadb-init: + config: *mariadbConfig + nameOverride: vid-mariadb-init + # A configMap of same name is created. It points to file that will be run after + # The DB has been created. + dbScriptConfigMap: '{{ include "common.release" . }}-vid-db-init' + # default number of instances replicaCount: 1 diff --git a/kubernetes/vnfsdk/requirements.yaml b/kubernetes/vnfsdk/requirements.yaml index a287d9c928..1b01fddcd9 100644 --- a/kubernetes/vnfsdk/requirements.yaml +++ b/kubernetes/vnfsdk/requirements.yaml @@ -19,3 +19,6 @@ dependencies: - name: postgres version: ~6.x-0 repository: '@local' + - name: repositoryGenerator + version: ~6.x-0 + repository: '@local' diff --git a/kubernetes/vnfsdk/templates/deployment.yaml b/kubernetes/vnfsdk/templates/deployment.yaml index 9baec482c9..7e4ad5bd92 100644 --- a/kubernetes/vnfsdk/templates/deployment.yaml +++ b/kubernetes/vnfsdk/templates/deployment.yaml @@ -51,7 +51,7 @@ spec: name: init-data-input - mountPath: /config name: init-data - image: "{{ .Values.global.envsubstImage }}" + image: {{ include "repositoryGenerator.image.envsubst" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-update-config @@ -66,11 +66,11 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }}-readiness containers: - - image: "{{ include "common.repository" . }}/{{ .Values.image }}" + - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} name: {{ include "common.name" . }} resources: diff --git a/kubernetes/vnfsdk/templates/job.yaml b/kubernetes/vnfsdk/templates/job.yaml index ea7e22fc4d..7c320fc86f 100644 --- a/kubernetes/vnfsdk/templates/job.yaml +++ b/kubernetes/vnfsdk/templates/job.yaml @@ -45,12 +45,12 @@ spec: fieldRef: apiVersion: v1 fieldPath: metadata.namespace - image: "{{ include "common.repository" . }}/{{ .Values.global.readinessImage }}" + image: {{ include "repositoryGenerator.image.readiness" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy}} name: {{ include "common.name" . }}-readiness containers: - name: {{ include "common.name" . }}-job - image: "{{ .Values.postgresRepository }}/{{ .Values.postgresImage }}" + image: {{ include "repositoryGenerator.image.postgres" . }} imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} env: - name: PGUSER diff --git a/kubernetes/vnfsdk/values.yaml b/kubernetes/vnfsdk/values.yaml index 2cdc1e9a32..55eea0fa60 100644 --- a/kubernetes/vnfsdk/values.yaml +++ b/kubernetes/vnfsdk/values.yaml @@ -17,11 +17,6 @@ ################################################################# global: nodePortPrefix: 302 - repository: nexus3.onap.org:10001 - readinessImage: onap/oom/readiness:3.0.1 - loggingRepository: docker.elastic.co - loggingImage: beats/filebeat:5.5.0 - envsubstImage: dibi/envsubst secrets: - uid: pg-root-pass @@ -42,10 +37,7 @@ secrets: # Application configuration defaults. ################################################################# # application image -repository: nexus3.onap.org:10001 image: onap/vnfsdk/refrepo:1.6.2 -postgresRepository: crunchydata -postgresImage: crunchy-postgres:centos7-10.3-1.8.2 pullPolicy: Always # application configuration override for postgres