Merge "[DCAEMOD] RuntimAPI updates for HELM-gen integration"
authorSylvain Desbureaux <sylvain.desbureaux@orange.com>
Thu, 2 Dec 2021 07:16:32 +0000 (07:16 +0000)
committerGerrit Code Review <gerrit@onap.org>
Thu, 2 Dec 2021 07:16:32 +0000 (07:16 +0000)
114 files changed:
kubernetes/a1policymanagement/templates/statefulset.yaml
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/artifact.dat
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/cred.dat
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/ns.dat
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/perm.dat
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/role.dat
kubernetes/aaf/components/aaf-cass/resources/cass-init-dats/user_role.dat
kubernetes/aaf/resources/data/identities.dat
kubernetes/aai/components/aai-graphadmin/requirements.yaml
kubernetes/aai/components/aai-graphadmin/resources/config/aaiconfig.properties
kubernetes/aai/components/aai-graphadmin/resources/config/application.properties
kubernetes/aai/components/aai-graphadmin/resources/config/logback.xml
kubernetes/aai/components/aai-graphadmin/templates/configmap.yaml
kubernetes/aai/components/aai-graphadmin/templates/deployment.yaml
kubernetes/aai/components/aai-graphadmin/templates/job-copy-db-backup.yaml
kubernetes/aai/components/aai-graphadmin/templates/job-create-db.yaml
kubernetes/aai/components/aai-graphadmin/templates/job-migration.yaml
kubernetes/aai/components/aai-graphadmin/templates/service.yaml
kubernetes/aai/components/aai-graphadmin/values.yaml
kubernetes/aai/components/aai-modelloader/templates/deployment.yaml
kubernetes/aai/components/aai-schema-service/config/aaiconfig.properties
kubernetes/aai/components/aai-schema-service/config/application.properties
kubernetes/aai/components/aai-schema-service/config/logback.xml
kubernetes/aai/components/aai-schema-service/config/realm.properties
kubernetes/aai/components/aai-schema-service/requirements.yaml
kubernetes/aai/components/aai-schema-service/templates/configmap.yaml
kubernetes/aai/components/aai-schema-service/templates/deployment.yaml
kubernetes/aai/components/aai-schema-service/values.yaml
kubernetes/aai/components/aai-sparky-be/templates/deployment.yaml
kubernetes/aai/components/aai-traversal/templates/job.yaml
kubernetes/aai/resources/config/aai/aai_keystore
kubernetes/cps/components/cps-core/values.yaml
kubernetes/cps/components/cps-temporal/values.yaml
kubernetes/cps/components/ncmp-dmi-plugin/values.yaml
kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl
kubernetes/dcaegen2-services/components/dcae-ms-healthcheck/values.yaml
kubernetes/dcaegen2-services/components/dcae-tcagen2/requirements.yaml
kubernetes/dcaegen2-services/components/dcae-tcagen2/values.yaml
kubernetes/dcaegen2-services/resources/expected-components.json
kubernetes/dcaegen2/components/dcae-bootstrap/requirements.yaml
kubernetes/dcaegen2/components/dcae-bootstrap/values.yaml
kubernetes/dcaegen2/components/dcae-config-binding-service/templates/deployment.yaml
kubernetes/dcaegen2/components/dcae-healthcheck/values.yaml
kubernetes/dcaegen2/resources/expected-components.json
kubernetes/dcaegen2/values.yaml
kubernetes/modeling/components/modeling-etsicatalog/resources/config/log/filebeat/filebeat.yml [moved from kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/filebeat/filebeat.yml with 100% similarity]
kubernetes/modeling/components/modeling-etsicatalog/resources/config/log/server/log.yml [moved from kubernetes/modeling/components/modeling-etsicatalog/resources/config/logging/server/log.yml with 100% similarity]
kubernetes/modeling/components/modeling-etsicatalog/templates/configmap.yaml
kubernetes/modeling/components/modeling-etsicatalog/templates/deployment.yaml
kubernetes/modeling/components/modeling-etsicatalog/values.yaml
kubernetes/msb/components/msb-discovery/templates/deployment.yaml
kubernetes/msb/components/msb-discovery/values.yaml
kubernetes/msb/components/msb-eag/templates/deployment.yaml
kubernetes/msb/components/msb-eag/values.yaml
kubernetes/msb/components/msb-iag/templates/deployment.yaml
kubernetes/msb/components/msb-iag/values.yaml
kubernetes/msb/templates/configmap.yaml
kubernetes/msb/values.yaml
kubernetes/multicloud/components/multicloud-fcaps/templates/deployment.yaml
kubernetes/multicloud/components/multicloud-fcaps/values.yaml
kubernetes/multicloud/components/multicloud-pike/templates/deployment.yaml
kubernetes/multicloud/components/multicloud-pike/values.yaml
kubernetes/multicloud/components/multicloud-starlingx/templates/deployment.yaml
kubernetes/multicloud/components/multicloud-starlingx/values.yaml
kubernetes/multicloud/components/multicloud-vio/templates/deployment.yaml
kubernetes/multicloud/components/multicloud-vio/values.yaml
kubernetes/multicloud/components/multicloud-windriver/templates/deployment.yaml
kubernetes/multicloud/components/multicloud-windriver/values.yaml
kubernetes/multicloud/templates/configmap.yaml
kubernetes/multicloud/templates/deployment.yaml
kubernetes/multicloud/values.yaml
kubernetes/oof/resources/config/conf/common_config.yaml
kubernetes/policy/components/policy-clamp-cl-pf-ppnt/resources/config/PolicyParticipantParameters.yaml
kubernetes/portal/components/portal-app/templates/deployment.yaml
kubernetes/portal/components/portal-app/values.yaml
kubernetes/portal/components/portal-sdk/templates/deployment.yaml
kubernetes/portal/components/portal-sdk/values.yaml
kubernetes/portal/templates/configmap.yaml
kubernetes/portal/values.yaml
kubernetes/sdc/components/sdc-be/values.yaml
kubernetes/sdc/components/sdc-cs/values.yaml
kubernetes/sdc/components/sdc-fe/values.yaml
kubernetes/sdc/components/sdc-onboarding-be/values.yaml
kubernetes/sdnc/templates/statefulset.yaml
kubernetes/sdnc/values.yaml
kubernetes/uui/components/uui-nlp/Chart.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/requirements.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/templates/deployment.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/templates/ingress.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/templates/pv.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/templates/pvc.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/templates/service.yaml [new file with mode: 0644]
kubernetes/uui/components/uui-nlp/values.yaml [new file with mode: 0644]
kubernetes/uui/requirements.yaml
kubernetes/vfc/components/vfc-generic-vnfm-driver/templates/deployment.yaml
kubernetes/vfc/components/vfc-generic-vnfm-driver/values.yaml
kubernetes/vfc/components/vfc-huawei-vnfm-driver/templates/deployment.yaml
kubernetes/vfc/components/vfc-huawei-vnfm-driver/values.yaml
kubernetes/vfc/components/vfc-nslcm/templates/deployment.yaml
kubernetes/vfc/components/vfc-nslcm/values.yaml
kubernetes/vfc/components/vfc-vnflcm/templates/deployment.yaml
kubernetes/vfc/components/vfc-vnflcm/values.yaml
kubernetes/vfc/components/vfc-vnfmgr/templates/deployment.yaml
kubernetes/vfc/components/vfc-vnfmgr/values.yaml
kubernetes/vfc/components/vfc-vnfres/templates/deployment.yaml
kubernetes/vfc/components/vfc-vnfres/values.yaml
kubernetes/vfc/components/vfc-zte-vnfm-driver/templates/deployment.yaml
kubernetes/vfc/components/vfc-zte-vnfm-driver/values.yaml
kubernetes/vfc/resources/config/log/filebeat/filebeat.yml [moved from kubernetes/vfc/resources/config/logging/filebeat/filebeat.yml with 100% similarity]
kubernetes/vfc/templates/configmap.yaml
kubernetes/vfc/values.yaml
kubernetes/vid/templates/configmap.yaml
kubernetes/vid/templates/deployment.yaml
kubernetes/vid/values.yaml

index 1d25f31..0114b30 100644 (file)
@@ -28,6 +28,8 @@ spec:
     metadata:
       labels: {{- include "common.labels" . | nindent 8 }}
     spec:
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
       initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
       - name: {{ include "common.name" . }}-bootstrap-config
         image: {{ include "repositoryGenerator.image.envsubst" . }}
@@ -58,7 +60,7 @@ spec:
           name: config
       containers:
       - name: {{ include "common.name" . }}-update-config
-        image: "{{ .Values.global.envsubstImage }}"
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         securityContext:
           runAsGroup: {{ .Values.groupID }}
index a463985..8a923b2 100644 (file)
@@ -4,10 +4,11 @@ aaf@aaf.osaaf.org|aaf|local|/opt/app/osaaf/local||mailto:|org.osaaf.aaf|root|30|
 aaf-sms@aaf-sms.onap.org|aaf-sms|local|/opt/app/osaaf/local||mailto:|org.onap.aaf-sms|root|30|{'aaf-sms-db.onap', 'aaf-sms.api.simpledemo.onap.org', 'aaf-sms.onap', 'aaf-sms.simpledemo.onap.org'}|aaf_admin@osaaf.org|{'pkcs12', 'file'}
 aai@aai.onap.org|aai1|local|/opt/app/osaaf/local||mailto:|org.onap.aai|root|30|{'aai-babel.onap', 'aai-babel', 'aai-modelloader.onap', 'aai-modelloader', 'aai-sparky-be.onap', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org'}|aaf_admin@osaaf.org|{'pkcs12'}
 aai@aai.onap.org|aai2|aaf|/Users/jf2512||mailto:|org.onap.aai|jf2512|60|{'aai-babel.onap', 'aai-babel', 'aai-modelloader.onap', 'aai-modelloader', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.onap aai-sparky-be.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org aai1.onap'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12', 'script'}
-aai@aai.onap.org|aai|local|/opt/app/osaaf/local||mailto:|org.onap.aai|root|60|{'aai-babel.onap', 'aai-babel', 'aai-modelloader.onap', 'aai-modelloader', 'aai-search-data.onap', 'aai-sparky-be.onap', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12'}
+aai@aai.onap.org|aai|local|/opt/app/osaaf/local||mailto:|org.onap.aai|root|60|{'aai-babel.onap', 'aai-babel', 'aai-graphadmin', 'aai-graphadmin.onap', 'aai-modelloader.onap', 'aai-modelloader', 'aai-search-data.onap', 'aai-sparky-be.onap', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12'}
 aai@aai.onap.org|aai.onap|local|/opt/app/osaaf/local||mailto:|org.onap.aai|root|30|{'aai-babel.onap', 'aai-babel', 'aai-modelloader.onap', 'aai-modelloader', 'aai-sparky-be.onap', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org'}|aaf_admin@osaaf.org|{'file', 'jks', 'pkcs12'}
 aai@aai.onap.org|mithrilcsp.sbc.com|local|/tmp/onap||mailto:|org.onap.aai|jg1555|30|{'aai-babel.onap', 'aai-babel', 'aai-modelloader.onap', 'aai-modelloader', 'aai-sparky-be.onap', 'aai.api.simpledemo.onap.org', 'aai.elasticsearch.simpledemo.onap.org', 'aai.gremlinserver.simpledemo.onap.org', 'aai.hbase.simpledemo.onap.org', 'aai.onap', 'aai.searchservice.simpledemo.onap.org', 'aai.simpledemo.onap.org', 'aai.ui.simpledemo.onap.org'}|aaf_admin@osaaf.org|{'file', 'pkcs12', 'script'}
 aai-resources@aai-resources.onap.org|aai-resources|local|/opt/app/osaaf/local||mailto:|org.onap.aai-resources|root|30|{'aai-resources', 'aai-resources.onap'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12'}
+aai-schema-service@aai-schema-service.onap.org|aai-schema-service|local|/opt/app/osaaf/local||mailto:|org.onap.aai-schema-service|root|30|{'aai-schema-service', 'aai-schema-service.onap'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12'}
 aai-traversal@aai-traversal.onap.org|aai-traversal|local|/opt/app/osaaf/local||mailto:|org.onap.aai-traversal|root|30|{'aai-traversal', 'aai-traversal.onap'}|mmanager@osaaf.org|{'file', 'jks', 'pkcs12'}
 appc@appc.onap.org|appc|local|/opt/app/osaaf/local||mailto:|org.onap.appc|root|60|{'appc.api.simpledemo.onap.org', 'appc.onap', 'appc.simpledemo.onap.org'}|mmanager@osaaf.org|{'pkcs12'}
 appc-cdt@appc-cdt.onap.org|appc-cdt|local|/opt/app/osaaf/local||mailto:|org.onap.appc-cdt|root|30|{'appc-cdt', 'appc-cdt.api.simpledemo.onap.org', 'appc-cdt.onap'}|mmanager@osaaf.org|{'file', 'pkcs12', 'script'}
index 7112b0b..1279c36 100644 (file)
@@ -6,6 +6,7 @@ aaf-sms@aaf-sms.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d0
 clamp@clamp.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.clamp|53344||
 aai@aai.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.aai|53344||
 aai-resources@aai-resources.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.aai-resources|53344||
+aai-schema-service@aai-schema-service.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.aai-schema-service|53344||
 aai-traversal@aai-traversal.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.aai-traversal|53344||
 appc@appc.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.appc|53344||
 appc-cdt@appc-cdt.onap.org|2|2020-11-26 12:31:54.000+0000|0xd993c5617486296f1b99d04de31633332b8ba1a550038e23860f9dbf0b2fcf95|Initial ID|org.onap.appc-cdt|53344||
index 6763069..7d20d55 100644 (file)
@@ -2,6 +2,7 @@ org.onap.a1p||org.onap||3
 org.onap.aaf-sms||org.onap||3
 org.onap.aai||org.onap||3
 org.onap.aai-resources||org.onap||3
+org.onap.aai-schema-service||org.onap||3
 org.onap.aai-traversal||org.onap||3
 org.onap.appc||org.onap||3
 org.onap.appc-cdt||org.onap||3
index 48ec26e..89c726f 100644 (file)
@@ -20,6 +20,9 @@ org.onap.aai|traversal|*|basic||"{'org.onap.aai|traversal_basic'}"
 org.onap.aai-resources|access|*|*|AAF Namespace Write Access|"{'org.onap.aai-resources|admin', 'org.onap.aai-resources|service'}"
 org.onap.aai-resources|access|*|read|AAF Namespace Read Access|"{'org.onap.aai-resources|owner'}"
 org.onap.aai-resources|certman|local|request,ignoreIPs,showpass||"{'org.osaaf.aaf|deploy'}"
+org.onap.aai-schema-service|access|*|*|AAF Namespace Write Access|"{'org.onap.aai-schema-service|admin', 'org.onap.aai-schema-service|service'}"
+org.onap.aai-schema-service|access|*|read|AAF Namespace Read Access|"{'org.onap.aai-schema-service|owner'}"
+org.onap.aai-schema-service|certman|local|request,ignoreIPs,showpass||"{'org.osaaf.aaf|deploy'}"
 org.onap.aai-traversal|access|*|*|AAF Namespace Write Access|"{'org.onap.aai-traversal|admin', 'org.onap.aai-traversal|service'}"
 org.onap.aai-traversal|access|*|read|AAF Namespace Read Access|"{'org.onap.aai-traversal|owner'}"
 org.onap.aai-traversal|certman|local|request,ignoreIPs,showpass||"{'org.osaaf.aaf|deploy'}"
index 397846c..111b94e 100644 (file)
@@ -15,10 +15,13 @@ org.onap.aai|traversal_advanced|traversal_advanced|"{'org.onap.aai|traversal|*|a
 org.onap.aai|traversal_basic|traversal_basic|"{'org.onap.aai|traversal|*|basic'}"
 org.onap.aai-resources|admin|AAF Namespace Administrators|"{'org.onap.aai-resources|access|*|*'}"
 org.onap.aai-resources|owner|AAF Namespace Owners|"{'org.onap.aai-resources|access|*|read'}"
-org.onap.aai-resources|service||"{'org.onapaai-resources|access|*|*'}"
+org.onap.aai-resources|service||"{'org.onap.aai-resources|access|*|*'}"
+org.onap.aai-schema-service|admin|AAF Namespace Administrators|"{'org.onap.aai-schema-service|access|*|*'}"
+org.onap.aai-schema-service|owner|AAF Namespace Owners|"{'org.onap.aai-schema-service|access|*|read'}"
+org.onap.aai-schema-service|service||"{'org.onap.aai-schema-service|access|*|*'}"
 org.onap.aai-traversal|admin|AAF Namespace Administrators|"{'org.onap.aai-traversal|access|*|*'}"
 org.onap.aai-traversal|owner|AAF Namespace Owners|"{'org.onap.aai-traversal|access|*|read'}"
-org.onap.aai-traversal|service||"{'org.onapaai-traversal|access|*|*'}"
+org.onap.aai-traversal|service||"{'org.onap.aai-traversal|access|*|*'}"
 org.onap|admin|Onap Admins|"{'org.onap.access|*|*'}"
 org.onap.appc|admin|AAF Namespace Administrators|"{'org.onap.appc|access|*|*'}"
 org.onap.appc|apidoc||"{'org.onap.appc|apidoc|/apidoc/.*|ALL'}"
@@ -339,7 +342,7 @@ org.openecomp.dmaapBC|admin|AAF Admins|"{'org.openecomp.dmaapBC.access|*|*', 'or
 org.openecomp.dmaapBC|owner|AAF Owners|"{'org.openecomp.dmaapBC.access|*|read'}"
 org.openecomp|owner|OpenEcomp Owners|"{'org.openecomp.access|*|read'}"
 org.osaaf.aaf|admin|AAF Admins|"{'org.osaaf.aaf.access|*|*', 'org.osaaf.aaf|cache|all|clear', 'org.osaaf.aaf|cache|role|clear', 'org.osaaf.aaf|password|*|create,reset'}"
-org.osaaf.aaf|deploy|ONAP Deployment Role|"{'org.onap.a1p|certman|local|request,ignoreIPs,showpass', 'org.onap.aaf-sms|certman|local|request,ignoreIPs,showpass', 'org.onap.aai|certman|local|request,ignoreIPs,showpass', 'org.onap.aai-resources|certman|local|request,ignoreIPs,showpass', 'org.onap.aai-traversal|certman|local|request,ignoreIPs,showpass', 'org.onap.appc|certman|local|request,ignoreIPs,showpass', 'org.onap.appc-cdt|certman|local|request,ignoreIPs,showpass', 'org.onap.clamp|certman|local|request,ignoreIPs,showpass', 'org.onap.cli|certman|local|request,ignoreIPs,showpass', 'org.onap.dcae|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc-mm-prov|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc-topic-mgr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-dr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-mr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap.mr|certman|local|request,ignoreIPs,showpass', 'org.onap.holmes-engine-mgmt|certman|local|request,ignoreIPs,showpass', 'org.onap.holmes-rule-mgmt|certman|local|request,ignoreIPs,showpass', 'org.onap.msb-eag|certman|local|request,ignoreIPs,showpass', 'org.onap.msb-iag|certman|local|request,ignoreIPs,showpass', 'org.onap.music|certman|local|request,ignoreIPs,showpass', 'org.onap.nbi|certman|local|request,ignoreIPs,showpass', 'org.onap.oof|certman|local|request,ignoreIPs,showpass', 'org.onap.policy|certman|local|request,ignoreIPs,showpass', 'org.onap.pomba|certman|local|request,ignoreIPs,showpass', 'org.onap.portal|certman|local|request,ignoreIPs,showpass', 'org.onap.refrepo|certman|local|request,ignoreIPs,showpass', 'org.onap.sdc|certman|local|request,ignoreIPs,showpass', 'org.onap.sdnc-cds|certman|local|request,ignoreIPs,showpass', 'org.onap.sdnc|certman|local|request,ignoreIPs,showpass', 'org.onap.so|certman|local|request,ignoreIPs,showpass', 'org.onap.vfc|certman|local|request,ignoreIPs,showpass', 'org.onap.vid1|certman|local|request,ignoreIPs,showpass', 'org.onap.vid2|certman|local|request,ignoreIPs,showpass', 'org.onap.vid|certman|local|request,ignoreIPs,showpass', 'org.onap.uui|certman|local|request,ignoreIPs,showpass', 'org.osaaf.aaf|certman|local|request,ignoreIPs,showpass'}"
+org.osaaf.aaf|deploy|ONAP Deployment Role|"{'org.onap.a1p|certman|local|request,ignoreIPs,showpass', 'org.onap.aaf-sms|certman|local|request,ignoreIPs,showpass', 'org.onap.aai|certman|local|request,ignoreIPs,showpass', 'org.onap.aai-resources|certman|local|request,ignoreIPs,showpass', 'org.onap.aai-schema-service|certman|local|request,ignoreIPs,showpass', 'org.onap.aai-traversal|certman|local|request,ignoreIPs,showpass', 'org.onap.appc|certman|local|request,ignoreIPs,showpass', 'org.onap.appc-cdt|certman|local|request,ignoreIPs,showpass', 'org.onap.clamp|certman|local|request,ignoreIPs,showpass', 'org.onap.cli|certman|local|request,ignoreIPs,showpass', 'org.onap.dcae|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc-mm-prov|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc-topic-mgr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-bc|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-dr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap-mr|certman|local|request,ignoreIPs,showpass', 'org.onap.dmaap.mr|certman|local|request,ignoreIPs,showpass', 'org.onap.holmes-engine-mgmt|certman|local|request,ignoreIPs,showpass', 'org.onap.holmes-rule-mgmt|certman|local|request,ignoreIPs,showpass', 'org.onap.msb-eag|certman|local|request,ignoreIPs,showpass', 'org.onap.msb-iag|certman|local|request,ignoreIPs,showpass', 'org.onap.music|certman|local|request,ignoreIPs,showpass', 'org.onap.nbi|certman|local|request,ignoreIPs,showpass', 'org.onap.oof|certman|local|request,ignoreIPs,showpass', 'org.onap.policy|certman|local|request,ignoreIPs,showpass', 'org.onap.pomba|certman|local|request,ignoreIPs,showpass', 'org.onap.portal|certman|local|request,ignoreIPs,showpass', 'org.onap.refrepo|certman|local|request,ignoreIPs,showpass', 'org.onap.sdc|certman|local|request,ignoreIPs,showpass', 'org.onap.sdnc-cds|certman|local|request,ignoreIPs,showpass', 'org.onap.sdnc|certman|local|request,ignoreIPs,showpass', 'org.onap.so|certman|local|request,ignoreIPs,showpass', 'org.onap.vfc|certman|local|request,ignoreIPs,showpass', 'org.onap.vid1|certman|local|request,ignoreIPs,showpass', 'org.onap.vid2|certman|local|request,ignoreIPs,showpass', 'org.onap.vid|certman|local|request,ignoreIPs,showpass', 'org.onap.uui|certman|local|request,ignoreIPs,showpass', 'org.osaaf.aaf|certman|local|request,ignoreIPs,showpass'}"
 org.osaaf.aaf|owner|AAF Owners|"{'org.osaaf.aaf.access|*|read,approve'}"
 org.osaaf.aaf|service||"{'org.osaaf.aaf|cache|*|clear'}"
 org.osaaf|admin|OSAAF Admins|"{'org.osaaf.access|*|*'}"
index 0dabc4d..bc9f0ec 100644 (file)
@@ -6,6 +6,8 @@ mmanager@people.osaaf.org|org.onap.aai.admin|2020-11-26 12:31:54.000+0000|org.on
 mmanager@people.osaaf.org|org.onap.aai.owner|2020-11-26 12:31:54.000+0000|org.onap.aai|owner
 mmanager@people.osaaf.org|org.onap.aai-resources.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-resources|admin
 mmanager@people.osaaf.org|org.onap.aai-resources.owner|2020-11-26 12:31:54.000+0000|org.onap.aai-resources|owner
+mmanager@people.osaaf.org|org.onap.aai-schema-service.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-schema-service|admin
+mmanager@people.osaaf.org|org.onap.aai-schema-service.owner|2020-11-26 12:31:54.000+0000|org.onap.aai-schema-service|owner
 mmanager@people.osaaf.org|org.onap.aai-traversal.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-traversal|admin
 mmanager@people.osaaf.org|org.onap.aai-traversal.owner|2020-11-26 12:31:54.000+0000|org.onap.aai-traversal|owner
 mmanager@people.osaaf.org|org.onap.admin|2020-11-26 12:31:54.000+0000|org.onap|admin
@@ -202,6 +204,7 @@ aaf_admin@people.osaaf.org|org.onap.a1p.admin|2020-11-26 12:31:54.000+0000|org.o
 aaf_admin@people.osaaf.org|org.onap.aaf-sms.admin|2020-11-26 12:31:54.000+0000|org.onap.aaf-sms|admin
 aaf_admin@people.osaaf.org|org.onap.aai.admin|2020-11-26 12:31:54.000+0000|org.onap.aai|admin
 aaf_admin@people.osaaf.org|org.onap.aai-resources.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-resources|admin
+aaf_admin@people.osaaf.org|org.onap.aai-schema-service.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-schema-service|admin
 aaf_admin@people.osaaf.org|org.onap.aai-traversal.admin|2020-11-26 12:31:54.000+0000|org.onap.aai-traversal|admin
 aaf_admin@people.osaaf.org|org.onap.appc.admin|2020-11-26 12:31:54.000+0000|org.onap.appc|admin
 aaf_admin@people.osaaf.org|org.onap.appc.apidoc|2020-11-26 12:31:54.000+0000|org.onap.appc|apidoc
@@ -272,6 +275,7 @@ aai@aai.onap.org|org.onap.aai.admin|2020-11-26 12:31:54.000+0000|org.onap.aai|ad
 aai@aai.onap.org|org.onap.aai.resources_all|2020-11-26 12:31:54.000+0000|org.onap.aai|resources_all
 aai@aai.onap.org|org.onap.aai.traversal_advanced|2020-11-26 12:31:54.000+0000|org.onap.aai|traversal_advanced
 aai-resources@aai-resources.onap.org|org.onap.aai-resources.service|2020-11-26 12:31:54.000+0000|org.onap.aai-resources|service
+aai-schema-service@aai-schema-service.onap.org|org.onap.aai-schema-service.service|2020-11-26 12:31:54.000+0000|org.onap.aai-schema-service|service
 aai-traversal@aai-traversal.onap.org|org.onap.aai-traversal.service|2020-11-26 12:31:54.000+0000|org.onap.aai-traversal|service
 appc@appc.onap.org|org.onap.aai.resources_all|2020-11-26 12:31:54.000+0000|org.onap.aai|resources_all
 appc@appc.onap.org|org.onap.aai.traversal_advanced|2020-11-26 12:31:54.000+0000|org.onap.aai|traversal_advanced
index 972b2ed..4813cc1 100644 (file)
@@ -54,6 +54,7 @@ aaf-sms|AAF SMS Application|AAF SMS|Application|314-123-1234|no_reply@people.osa
 clamp|ONAP CLAMP Application|CLAMP|Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
 aai|ONAP AAI Application|AAI|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
 aai-resources|ONAP AAI Resources Application|AAI Resources|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
+aai-schema-service|ONAP AAI Schema Service Application|AAI Schema Service|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
 aai-traversal|ONAP AAI Traversal Application|AAI Resources|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
 appc|ONAP APPC Application|APPC|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
 appc-cdt|ONAP APPC CDT Application|APPC|ONAP Application|314-123-1234|no_reply@people.osaaf.com|a|mmanager
index d80dc5a..5a41aef 100644 (file)
@@ -21,6 +21,9 @@ dependencies:
     # a part of this chart's package and will not
     # be published independently to a repo (at this point)
     repository: '@local'
+  - name: certInitializer
+    version: ~9.x-0
+    repository: '@local'
   - name: repositoryGenerator
     version: ~9.x-0
     repository: '@local'
index 512e906..f768338 100644 (file)
@@ -4,6 +4,7 @@
 # org.onap.aai
 # ================================================================================
 # Copyright Â© 2018 AT&T Intellectual Property. All rights reserved.
+# Modifications Copyright Â© 2021 Orange
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -41,10 +42,10 @@ aai.tools.password={{ .Values.global.config.basic.auth.passwd }}
 {{ end }}
 
 {{ if ( include "common.needTLS" .) }}
-aai.truststore.filename={{ .Values.global.config.truststore.filename }}
-aai.truststore.passwd.x={{ .Values.global.config.truststore.passwd }}
-aai.keystore.filename={{ .Values.global.config.keystore.filename }}
-aai.keystore.passwd.x={{ .Values.global.config.keystore.passwd }}
+aai.truststore.filename={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+aai.truststore.passwd.x=${TRUSTSTORE_PASSWORD}
+aai.keystore.filename={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.p12
+aai.keystore.passwd.x=${KEYSTORE_PASSWORD}
 {{ end }}
 
 aai.notification.current.version={{ .Values.global.config.schema.version.api.default }}
index 367e903..2760602 100644 (file)
@@ -4,6 +4,7 @@
 # org.onap.aai
 # ================================================================================
 # Copyright ï¿½ 2018 AT&T Intellectual Property. All rights reserved.
+# Modifications Copyright Â© 2021 Orange
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -44,16 +45,16 @@ server.tomcat.max-idle-time=60000
 
 # If you get an application startup failure that the port is already taken
 # If thats not it, please check if the key-store file path makes sense
-server.local.startpath=aai-graphadmin/src/main/resources/
+server.local.startpath=/opt/app/aai-graphadmin/resources/
 server.basic.auth.location=${server.local.startpath}etc/auth/realm.properties
 
 server.port=8449
 {{ if ( include "common.needTLS" .) }}
 server.ssl.enabled-protocols=TLSv1.1,TLSv1.2
-server.ssl.key-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.keystore.filename }}
-server.ssl.key-store-password=password({{ .Values.global.config.keystore.passwd }})
-server.ssl.trust-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.truststore.filename }}
-server.ssl.trust-store-password=password({{ .Values.global.config.truststore.passwd }})
+server.ssl.key-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.jks
+server.ssl.key-store-password=password(${KEYSTORE_JKS_PASSWORD})
+server.ssl.trust-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+server.ssl.trust-store-password=password(${TRUSTSTORE_PASSWORD})
 server.ssl.client-auth=want
 server.ssl.key-store-type=JKS
 {{ else }}
@@ -103,10 +104,10 @@ schema.service.versions.endpoint=versions
 schema.service.client={{ (eq "true" (include "common.needTLS" .)) | ternary .Values.global.config.schema.service.client "no-auth" }}
 
 {{ if ( include "common.needTLS" .) }}
-schema.service.ssl.key-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.keystore.filename }}
-schema.service.ssl.trust-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.truststore.filename }}
-schema.service.ssl.key-store-password=password({{ .Values.global.config.keystore.passwd }})
-schema.service.ssl.trust-store-password=password({{ .Values.global.config.truststore.passwd }})
+schema.service.ssl.key-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.jks
+schema.service.ssl.trust-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+schema.service.ssl.key-store-password=password(${KEYSTORE_JKS_PASSWORD})
+schema.service.ssl.trust-store-password=password(${TRUSTSTORE_PASSWORD})
 {{ end }}
 
 aperture.rdbmsname=aai_relational
@@ -115,9 +116,9 @@ aperture.service.client={{ (eq "true" (include "common.needTLS" .)) | ternary .V
 
 aperture.service.base.url=http://localhost:8457/aai/aperture
 {{ if ( include "common.needTLS" .) }}
-aperture.service.ssl.key-store=${server.local.startpath}etc/auth/{{ .Values.global.config.keystore.filename }}
-aperture.service.ssl.trust-store=${server.local.startpath}etc/auth/{{ .Values.global.config.truststore.filename }}
-aperture.service.ssl.key-store-password=password({{ .Values.global.config.keystore.passwd }})
-aperture.service.ssl.trust-store-password=password({{ .Values.global.config.truststore.passwd }})
+aperture.service.ssl.key-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.jks
+aperture.service.ssl.trust-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+aperture.service.ssl.key-store-password=password(${KEYSTORE_JKS_PASSWORD})
+aperture.service.ssl.trust-store-password=password(${TRUSTSTORE_PASSWORD})
 {{ end }}
 aperture.service.timeout-in-milliseconds=300000
index 95b8140..243acd2 100644 (file)
   <!-- logback jms appenders & loggers definition ends here -->
   <logger name="org.onap.aai.aaf" level="DEBUG" additivity="false">
     <appender-ref ref="asyncAUTH"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.aailog.filter.RestClientLoggingInterceptor" level="INFO">
     <appender-ref ref="asyncMETRIC"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.logging.filter.base.AbstractMetricLogFilter" level="INFO">
     <appender-ref ref="asyncMETRIC"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.aailog.logs.AaiScheduledTaskAuditLog" level="INFO">
     <appender-ref ref="asyncAUDIT"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.logging.filter.base.AbstractAuditLogFilter" level="INFO">
     <appender-ref ref="asyncAUDIT"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.aailog.logs.AaiDBMetricLog" level="INFO">
     <appender-ref ref="asyncMETRIC"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.logging.ErrorLogHelper" level="WARN">
     <appender-ref ref="asyncERROR"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.interceptors.post" level="DEBUG" additivity="false">
     <appender-ref ref="asynctranslog"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.dmaap" level="DEBUG" additivity="false">
     <appender-ref ref="dmaapAAIEventConsumer"/>
     <appender-ref ref="dmaapAAIEventConsumerDebug"/>
     <appender-ref ref="dmaapAAIEventConsumerMetric"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.datasnapshot" level="DEBUG" additivity="false">
     <appender-ref ref="dataSnapshot"/>
     <appender-ref ref="asyncDEBUG"/>
     <appender-ref ref="asyncERROR"/>
     <appender-ref ref="asyncMETRIC"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <root level="DEBUG">
     <appender-ref ref="external"/>
index 91cd748..8eb4a4a 100644 (file)
@@ -4,6 +4,7 @@
 # org.onap.aai
 # ================================================================================
 # Copyright Â© 2018 AT&T Intellectual Property. All rights reserved.
+# Modifications Copyright Â© 2021 Orange
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -22,7 +23,7 @@
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-configmap
+  name: {{ include "common.fullname" . }}
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
@@ -40,16 +41,33 @@ data:
 {{ tpl (.Files.Glob "resources/config/localhost-access-logback.xml").AsConfig . | indent 2 }}
 {{ tpl (.Files.Glob "resources/config/janusgraph-realtime.properties").AsConfig . | indent 2 }}
 {{ tpl (.Files.Glob "resources/config/janusgraph-cached.properties").AsConfig . | indent 2 }}
+{{ tpl (.Files.Glob "resources/config/realm.properties").AsConfig . | indent 2 }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: {{ include "common.fullname" . }}-properties
+  namespace: {{ include "common.namespace" . }}
+  labels:
+    app: {{ include "common.name" . }}
+    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
+    release: {{ include "common.release" . }}
+    heritage: {{ .Release.Service }}
+  {{- if .Values.global.jobs.migration.enabled }}
+  annotations:
+    "helm.sh/hook": pre-upgrade,pre-install
+    "helm.sh/hook-weight": "0"
+    "helm.sh/hook-delete-policy": before-hook-creation
+  {{- end }}
+data:
 {{ tpl (.Files.Glob "resources/config/aaiconfig.properties").AsConfig . | indent 2 }}
 {{ tpl (.Files.Glob "resources/config/application.properties").AsConfig . | indent 2 }}
-{{ tpl (.Files.Glob "resources/config/realm.properties").AsConfig . | indent 2 }}
-
 {{- if .Values.global.jobs.migration.enabled }}
 ---
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-migration-configmap
+  name: {{ include "common.fullname" . }}-migration
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
index 6de34e9..cccc2b1 100644 (file)
@@ -5,7 +5,7 @@
 # ================================================================================
 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
 # Copyright (c) 2020 Nokia Intellectual Property. All rights reserved.
-# Copyright (c) 2020 Orange Intellectual Property. All rights reserved.
+# Copyright (c) 2020-2021 Orange Intellectual Property. All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -53,7 +53,49 @@ spec:
       hostname: aai-graphadmin
       terminationGracePeriodSeconds: {{ .Values.service.terminationGracePeriodSeconds }}
     {{ if .Values.global.initContainers.enabled }}
-      initContainers:
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      {{- if .Values.global.aafEnabled }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export KEYSTORE_JKS_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_JKS_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "KEYSTORE_JKS_PASSWORD=${KEYSTORE_JKS_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** Set obfuscated Truststore and Keystore password into configuration file"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          cd /config-input
+          for PFILE in `ls -1`
+          do
+            envsubst <${PFILE} >/config/${PFILE}
+          done
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        - mountPath: /config-input
+          name: properties-input
+        - mountPath: /config
+          name: properties
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-update-config
+      {{- end }}
       - command:
       {{ if .Values.global.jobs.migration.enabled }}
         - /app/ready.py
@@ -93,46 +135,40 @@ spec:
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
+          value: {{ .Values.securityContext.group_id | quote }}
         - name: INTERNAL_PORT_1
           value: {{ .Values.service.internalPort | quote }}
         - name: INTERNAL_PORT_2
           value: {{ .Values.service.internalPort2 | quote }}
-        volumeMounts:
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-realtime.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-RES
           name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/etc/auth/realm.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: realm.properties
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-          {{ $global := . }}
-          {{ range $job := .Values.global.config.auth.files }}
-        - mountPath: /opt/app/aai-graphadmin/resources/etc/auth/{{ . }}
-          name: {{ include "common.fullname" $global }}-auth-truststore-sec
-          subPath: {{ . }}
-          {{ end }}
         ports:
         - containerPort: {{ .Values.service.internalPort }}
         - containerPort: {{ .Values.service.internalPort2 }}
@@ -176,24 +212,24 @@ spec:
       # side car containers
       {{ include "common.log.sidecar" . | nindent 6 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
-      volumes:
+      volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: localtime
         hostPath:
           path: /etc/localtime
       - name: logs
         emptyDir: {}
       {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix .)) | nindent 6 }}
-      - name: {{ include "common.fullname" . }}-config
+      - name: config
+        configMap:
+          name: {{ include "common.fullname" . }}
+      - name: properties
+      {{- if .Values.global.aafEnabled }}
+        emptyDir:
+          medium: Memory
+      - name: properties-input
+      {{- end }}
         configMap:
-          name: {{ include "common.fullname" . }}-configmap
-      - name: {{ include "common.fullname" . }}-auth-truststore-sec
-        secret:
-          secretName: aai-common-truststore
-          items:
-            {{ range $job := .Values.global.config.auth.files }}
-            - key: {{ . }}
-              path: {{ . }}
-            {{ end }}
+          name: {{ include "common.fullname" . }}-properties
       restartPolicy: {{ .Values.restartPolicy }}
       imagePullSecrets:
       - name: {{ include "common.namespace" . }}-docker-registry-key
index 0cdce11..95c3fe2 100644 (file)
@@ -5,7 +5,7 @@
 # ================================================================================
 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
 # Copyright (c) 2020 Nokia Intellectual Property. All rights reserved.
-# Copyright (c) 2020 Orange Intellectual Property. All rights reserved.
+# Copyright (c) 2020-2021 Orange Intellectual Property. All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -58,8 +58,50 @@ spec:
         release: {{ include "common.release" . }}
       name: {{ include "common.name" . }}
     spec:
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      {{- if .Values.global.aafEnabled }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export KEYSTORE_JKS_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_JKS_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "KEYSTORE_JKS_PASSWORD=${KEYSTORE_JKS_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** Set obfuscated Truststore and Keystore password into configuration file"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          cd /config-input
+          for PFILE in `ls -1`
+          do
+            envsubst <${PFILE} >/config/${PFILE}
+          done
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        - mountPath: /config-input
+          name: properties-input
+        - mountPath: /config
+          name: properties
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-update-config
+      {{- end }}
       {{ if eq .Values.global.jobs.migration.remoteCassandra.enabled false }}
-      initContainers:
       - command:
         - /bin/bash
         - -c
@@ -79,65 +121,71 @@ spec:
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         command:
-        - /bin/bash
+        - sh
+        args:
         - -c
         - |
-           bash docker-entrypoint.sh dataSnapshot.sh ;
-           {{- include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
+           bash docker-entrypoint.sh dataSnapshot.sh
+           {{ include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/logs/data/dataSnapshots
-          name: {{ include "common.fullname" . }}-snapshots
+          name: snapshots
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-migration
+          name: migration
           subPath: janusgraph-migration-real.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-migration
+          name: migration
           subPath: janusgraph-migration-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-RES/
-          name: {{ include "common.fullname" . }}-logs
+          name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-        resources:
-{{ include "common.resources" . | indent 10 }}
+        resources: {{ include "common.resources" . | nindent 10 }}
       {{- if .Values.nodeSelector }}
-      nodeSelector:
-{{ toYaml .Values.nodeSelector | indent 8 }}
-      {{- end -}}
+      nodeSelector: {{ toYaml .Values.nodeSelector | nindent 8 }}
+      {{- end }}
       {{- if .Values.affinity }}
-      affinity:
-{{ toYaml .Values.affinity | indent 8 }}
+      affinity: {{ toYaml .Values.affinity | nindent 8 }}
       {{- end }}
-      volumes:
+      volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: localtime
         hostPath:
           path: /etc/localtime
-      - name: {{ include "common.fullname" . }}-logs
+      - name: logs
         emptyDir: {}
-      - name: {{ include "common.fullname" . }}-config
+      - name: config
+        configMap:
+          name: {{ include "common.fullname" . }}
+      - name: properties
+      {{- if .Values.global.aafEnabled }}
+        emptyDir:
+          medium: Memory
+      - name: properties-input
+      {{- end }}
         configMap:
-          name: {{ include "common.fullname" . }}-configmap
-      - name: {{ include "common.fullname" . }}-migration
+          name: {{ include "common.fullname" . }}-properties
+      - name: migration
         configMap:
-          name: {{ include "common.fullname" . }}-migration-configmap
-      - name: {{ include "common.fullname" . }}-snapshots
+          name: {{ include "common.fullname" . }}-migration
+      - name: snapshots
         persistentVolumeClaim:
           claimName: {{ include "common.fullname" . }}-migration
       restartPolicy: Never
index 1705cf5..62e27b6 100644 (file)
@@ -5,7 +5,7 @@
 # ================================================================================
 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
 # Copyright (c) 2020 Nokia Intellectual Property. All rights reserved.
-# Copyright (c) 2020 Orange Intellectual Property. All rights reserved.
+# Copyright (c) 2020-2021 Orange Intellectual Property. All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -53,7 +53,49 @@ spec:
         release: {{ include "common.release" . }}
       name: {{ include "common.name" . }}
     spec:
-      initContainers:
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      {{- if .Values.global.aafEnabled }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export KEYSTORE_JKS_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_JKS_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "KEYSTORE_JKS_PASSWORD=${KEYSTORE_JKS_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** Set obfuscated Truststore and Keystore password into configuration file"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          cd /config-input
+          for PFILE in `ls -1`
+          do
+            envsubst <${PFILE} >/config/${PFILE}
+          done
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        - mountPath: /config-input
+          name: properties-input
+        - mountPath: /config
+          name: properties
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-update-config
+      {{- end }}
       - command:
         - /app/ready.py
         args:
@@ -79,74 +121,66 @@ spec:
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         command:
-        - /bin/bash
+        - sh
+        args:
         - -c
         - |
-           bash docker-entrypoint.sh createDBSchema.sh ;
-           {{- include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
+           bash docker-entrypoint.sh createDBSchema.sh
+           {{ include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-realtime.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-GA
-          name: {{ include "common.fullname" . }}-logs
+          name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-          {{ $global := . }}
-          {{ range $job := .Values.global.config.auth.files }}
-        - mountPath: /opt/app/aai-graphadmin/resources/etc/auth/{{ . }}
-          name: {{ include "common.fullname" $global }}-auth-truststore-sec
-          subPath: {{ . }}
-          {{ end }}
-        resources:
-{{ include "common.resources" . }}
+        resources: {{ include "common.resources" . | nindent 10 }}
       {{- if .Values.nodeSelector }}
-      nodeSelector:
-{{ toYaml .Values.nodeSelector | indent 8 }}
-      {{- end -}}
+      nodeSelector: {{ toYaml .Values.nodeSelector | nindent 8 }}
+      {{- end }}
       {{- if .Values.affinity }}
-      affinity:
-{{ toYaml .Values.affinity | indent 8 }}
+      affinity: {{ toYaml .Values.affinity | nindent 8 }}
       {{- end }}
-      volumes:
+      volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: localtime
         hostPath:
           path: /etc/localtime
       {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix .)) | nindent 6 }}
-      - name: {{ include "common.fullname" . }}-logs
+      - name: logs
         emptyDir: {}
-      - name: {{ include "common.fullname" . }}-config
+      - name: config
+        configMap:
+          name: {{ include "common.fullname" . }}
+      - name: properties
+      {{- if .Values.global.aafEnabled }}
+        emptyDir:
+          medium: Memory
+      - name: properties-input
+      {{- end }}
         configMap:
-          name: {{ include "common.fullname" . }}-configmap
-      - name: {{ include "common.fullname" . }}-auth-truststore-sec
-        secret:
-          secretName: aai-common-truststore
-          items:
-            {{ range $job := .Values.global.config.auth.files }}
-            - key: {{ . }}
-              path: {{ . }}
-            {{ end }}
+          name: {{ include "common.fullname" . }}-properties
       restartPolicy: Never
       imagePullSecrets:
       - name: {{ include "common.namespace" . }}-docker-registry-key
index 5752e54..07009b2 100644 (file)
@@ -5,7 +5,7 @@
 # ================================================================================
 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
 # Copyright (c) 2020 Nokia Intellectual Property. All rights reserved.
-# Copyright (c) 2020 Orange Intellectual Property. All rights reserved.
+# Copyright (c) 2020-2021 Orange Intellectual Property. All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -58,7 +58,49 @@ spec:
         release: {{ include "common.release" . }}
       name: {{ include "common.name" . }}
     spec:
-      initContainers:
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      {{- if .Values.global.aafEnabled }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export KEYSTORE_JKS_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_JKS_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "KEYSTORE_JKS_PASSWORD=${KEYSTORE_JKS_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** Set obfuscated Truststore and Keystore password into configuration file"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          cd /config-input
+          for PFILE in `ls -1`
+          do
+            envsubst <${PFILE} >/config/${PFILE}
+          done
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        - mountPath: /config-input
+          name: properties-input
+        - mountPath: /config
+          name: properties
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-update-config
+      {{- end }}
       - command:
         - /app/ready.py
         args:
@@ -80,46 +122,42 @@ spec:
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-readiness
       - command:
-        - /bin/bash
+        - sh
+        args:
         - -c
-        - bash docker-entrypoint.sh dataRestoreFromSnapshot.sh `ls -t /opt/app/aai-graphadmin/logs/data/dataSnapshots|head -1|awk -F".P" '{ print $1 }'`
+        - |
+           bash docker-entrypoint.sh dataRestoreFromSnapshot.sh `ls -t /opt/app/aai-graphadmin/logs/data/dataSnapshots|head -1|awk -F".P" '{ print $1 }'`
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-realtime.properties
         - mountPath: /opt/app/aai-graphadmin/logs/data/dataSnapshots
-          name: {{ include "common.fullname" . }}-snapshots
+          name: snapshots
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-GA
-          name: {{ include "common.fullname" . }}-logs
+          name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-          {{ $global := . }}
-          {{ range $job := .Values.global.config.auth.files }}
-        - mountPath: /opt/app/aai-graphadmin/resources/etc/auth/{{ . }}
-          name: {{ include "common.fullname" $global }}-auth-truststore-sec
-          subPath: {{ . }}
-          {{ end }}
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-restore-backup
@@ -128,57 +166,49 @@ spec:
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-perform-migration
         command:
-        - /bin/bash
+        - sh
+        args:
         - -c
         - |
            bash docker-entrypoint.sh run_Migrations.sh -e UpdateAaiUriIndexMigration --commit --skipPreMigrationSnapShot --runDisabled RebuildAllEdges ;
-           {{- include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
+           {{ include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-realtime.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: janusgraph-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-GA
-          name: {{ include "common.fullname" . }}-logs
+          name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-          {{ $global := . }}
-          {{ range $job := .Values.global.config.auth.files }}
-        - mountPath: /opt/app/aai-graphadmin/resources/etc/auth/{{ . }}
-          name: {{ include "common.fullname" $global }}-auth-truststore-sec
-          subPath: {{ . }}
-          {{ end }}
-        resources:
-{{ include "common.resources" . }}
+        resources: {{ include "common.resources" . | nindent 10 }}
       {{- if .Values.nodeSelector }}
-      nodeSelector:
-{{ toYaml .Values.nodeSelector | indent 8 }}
-      {{- end -}}
+      nodeSelector: {{ toYaml .Values.nodeSelector | nindent 8 }}
+      {{- end }}
       {{- if .Values.affinity }}
-      affinity:
-{{ toYaml .Values.affinity | indent 8 }}
+      affinity: {{ toYaml .Values.affinity | nindent 8 }}
       {{- end }}
-      volumes:
+      volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: localtime
         hostPath:
           path: /etc/localtime
@@ -191,14 +221,14 @@ spec:
       - name: {{ include "common.fullname" . }}-snapshots
         persistentVolumeClaim:
           claimName: {{ include "common.fullname" . }}-migration
-      - name: {{ include "common.fullname" . }}-auth-truststore-sec
-        secret:
-          secretName: aai-common-truststore
-          items:
-            {{ range $job := .Values.global.config.auth.files }}
-            - key: {{ . }}
-              path: {{ . }}
-            {{ end }}
+      - name: properties
+      {{- if .Values.global.aafEnabled }}
+        emptyDir:
+          medium: Memory
+      - name: properties-input
+      {{- end }}
+        configMap:
+          name: {{ include "common.fullname" . }}-properties
       restartPolicy: Never
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
@@ -226,8 +256,50 @@ spec:
         release: {{ include "common.release" . }}
       name: {{ include "common.name" . }}
     spec:
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      {{- if .Values.global.aafEnabled }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export KEYSTORE_JKS_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_JKS_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "KEYSTORE_JKS_PASSWORD=${KEYSTORE_JKS_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** Set obfuscated Truststore and Keystore password into configuration file"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          cd /config-input
+          for PFILE in `ls -1`
+          do
+            envsubst <${PFILE} >/config/${PFILE}
+          done
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        - mountPath: /config-input
+          name: properties-input
+        - mountPath: /config
+          name: properties
+        image: {{ include "repositoryGenerator.image.envsubst" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-update-config
+      {{- end }}
       {{ if eq .Values.global.jobs.migration.remoteCassandra.enabled false }}
-      initContainers:
       - command:
         - /bin/bash
         - -c
@@ -247,65 +319,69 @@ spec:
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         command:
-        - /bin/bash
+        - sh
+        args:
         - -c
         - |
-           bash docker-entrypoint.sh dataSnapshot.sh ;
-           {{- include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
+           bash docker-entrypoint.sh dataSnapshot.sh
+           {{ include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
         - mountPath: /opt/app/aai-graphadmin/logs/data/dataSnapshots
-          name: {{ include "common.fullname" . }}-snapshots
+          name: snapshots
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-realtime.properties
-          name: {{ include "common.fullname" . }}-migration
+          name: migration
           subPath: janusgraph-migration-real.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/janusgraph-cached.properties
-          name: {{ include "common.fullname" . }}-migration
+          name: migration
           subPath: janusgraph-migration-cached.properties
         - mountPath: /opt/app/aai-graphadmin/resources/etc/appprops/aaiconfig.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: aaiconfig.properties
         - mountPath: /opt/aai/logroot/AAI-RES/
-          name: {{ include "common.fullname" . }}-logs
+          name: logs
         - mountPath: /opt/app/aai-graphadmin/resources/logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/localhost-access-logback.xml
-          name: {{ include "common.fullname" . }}-config
+          name: config
           subPath: localhost-access-logback.xml
         - mountPath: /opt/app/aai-graphadmin/resources/application.properties
-          name: {{ include "common.fullname" . }}-config
+          name: properties
           subPath: application.properties
-        resources:
-{{ include "common.resources" . | indent 10 }}
+        resources: {{ include "common.resources" . | nindent 10 }}
       {{- if .Values.nodeSelector }}
-      nodeSelector:
-{{ toYaml .Values.nodeSelector | indent 8 }}
-      {{- end -}}
+      nodeSelector: {{ toYaml .Values.nodeSelector | nindent 8 }}
+      {{- end }}
       {{- if .Values.affinity }}
-      affinity:
-{{ toYaml .Values.affinity | indent 8 }}
+      affinity: {{ toYaml .Values.affinity | nindent 8 }}
       {{- end }}
-      volumes:
+      volumes: {{ include "common.resources" . | nindent 10 }}
       - name: localtime
         hostPath:
           path: /etc/localtime
-      - name: {{ include "common.fullname" . }}-logs
+      - name: logs
         emptyDir: {}
-      - name: {{ include "common.fullname" . }}-config
+      - name: config
         configMap:
-          name: {{ include "common.fullname" . }}-configmap
-      - name: {{ include "common.fullname" . }}-migration
+          name: {{ include "common.fullname" . }}
+      - name: properties-input
         configMap:
-          name: {{ include "common.fullname" . }}-migration-configmap
-      - name: {{ include "common.fullname" . }}-snapshots
+          name: {{ include "common.fullname" . }}-properties
+      - name: properties
+        emptyDir:
+          medium: Memory
+      - name: migration
+        configMap:
+          name: {{ include "common.fullname" . }}-migration
+      - name: snapshots
         persistentVolumeClaim:
           claimName: {{ include "common.fullname" . }}-migration
       restartPolicy: Never
index 85165e2..cf46553 100644 (file)
@@ -4,6 +4,7 @@
 # org.onap.aai
 # ================================================================================
 # Copyright Â© 2018 AT&T Intellectual Property. All rights reserved.
+# Modifications Copyright Â© 2021 Orange
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
index b02e5cd..2774609 100644 (file)
@@ -4,7 +4,7 @@
 # ================================================================================
 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
 # Copyright (c) 2020 Nokia Intellectual Property. All rights reserved.
-# Copyright (c) 2020 Orange Intellectual Property. All rights reserved.
+# Copyright (c) 2020-2021 Orange Intellectual Property. All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -37,8 +37,6 @@ global: # global defaults
     migration:
       enabled: false
   config:
-    # User information for the admin user in container
-    userId: 1000
 
     # Specifies that the cluster connected to a dynamic
     # cluster being spinned up by kubernetes deployment
@@ -96,27 +94,54 @@ global: # global defaults
         edge:
           label: v12
 
-    # Keystore configuration password and filename
-    keystore:
-      filename: aai_keystore
-      passwd: OBF:1vn21ugu1saj1v9i1v941sar1ugw1vo0 # changeit
-
-    # Truststore configuration password and filename
-    truststore:
-      filename: aai_keystore
-      passwd: OBF:1vn21ugu1saj1v9i1v941sar1ugw1vo0 # changeit
-
-
-
-    # Specifies a list of files to be included in auth volume
-    auth:
-      files:
-        - aai_keystore
-
     # Specifies which clients should always default to realtime graph connection
     realtime:
       clients: SDNC,MSO,SO,robot-ete
 
+#################################################################
+# Certificate configuration
+#################################################################
+certInitializer:
+  nameOverride: aai-graphadmin-cert-initializer
+  aafDeployFqi: deployer@people.osaaf.org
+  aafDeployPass: demo123456!
+  # aafDeployCredsExternalSecret: some secret
+  fqdn: aai
+  fqi: aai@aai.onap.org
+  public_fqdn: aai.onap.org
+  cadi_longitude: "0.0"
+  cadi_latitude: "0.0"
+  app_ns: org.osaaf.aaf
+  credsPath: /opt/app/osaaf/local
+  fqi_namespace: org.onap.aai
+  user_id: &user_id 1000
+  group_id: &group_id 1000
+  aaf_add_config: |
+    echo "*** changing them into shell safe ones"
+    export KEYSTORE_PLAIN_PASSWORD=$(tr -cd '[:alnum:]' < /dev/urandom | fold -w64 | head -n1)
+    export KEYSTORE_JKS_PLAIN_PASSWORD=$(tr -cd '[:alnum:]' < /dev/urandom | fold -w64 | head -n1)
+    export TRUSTSTORE_PLAIN_PASSWORD=$(tr -cd '[:alnum:]' < /dev/urandom | fold -w64 | head -n1)
+    cd {{ .Values.credsPath }}
+    keytool -storepasswd -new "${KEYSTORE_PLAIN_PASSWORD}" \
+      -storepass "${cadi_keystore_password_p12}" \
+      -keystore {{ .Values.fqi_namespace }}.p12
+    keytool -storepasswd -new "${TRUSTSTORE_PLAIN_PASSWORD}" \
+      -storepass "${cadi_truststore_password}" \
+      -keystore {{ .Values.fqi_namespace }}.trust.jks
+    keytool -storepasswd -new "${KEYSTORE_JKS_PLAIN_PASSWORD}" \
+        -storepass "${cadi_keystore_password_jks}" \
+        -keystore {{ .Values.fqi_namespace }}.jks
+    echo "*** set key password as same password as keystore password"
+    keytool -keypasswd -new "${KEYSTORE_JKS_PLAIN_PASSWORD}" \
+      -keystore {{ .Values.fqi_namespace }}.jks \
+      -keypass "${cadi_keystore_password_jks}" \
+      -storepass "${KEYSTORE_JKS_PLAIN_PASSWORD}" -alias {{ .Values.fqi }}
+    echo "*** writing passwords into prop file"
+    echo "KEYSTORE_PLAIN_PASSWORD=${KEYSTORE_PLAIN_PASSWORD}" > {{ .Values.credsPath }}/mycreds.prop
+    echo "KEYSTORE_JKS_PLAIN_PASSWORD=${KEYSTORE_JKS_PLAIN_PASSWORD}" >> {{ .Values.credsPath }}/mycreds.prop
+    echo "TRUSTSTORE_PLAIN_PASSWORD=${TRUSTSTORE_PLAIN_PASSWORD}" >> {{ .Values.credsPath }}/mycreds.prop
+    echo "*** change ownership of certificates to targeted user"
+    chown -R {{ .Values.user_id }}:{{ .Values.group_id }} {{ .Values.credsPath }}
 
 # application image
 image: onap/aai-graphadmin:1.9.1
@@ -259,6 +284,11 @@ resources:
       memory: 2Gi
   unlimited: {}
 
+# Not fully used for now
+securityContext:
+  user_id: *user_id
+  group_id: *group_id
+
 #Pods Service Account
 serviceAccount:
   nameOverride: aai-graphadmin
index 0213d63..c4098b1 100644 (file)
@@ -116,12 +116,14 @@ spec:
       - name: localtime
         hostPath:
           path: /etc/localtime
-      - name: prop-config-input
-        configMap:
-          name: {{ include "common.fullname" . }}-prop
       - name: prop-config
+      {{- if .Values.global.aafEnabled }}
         emptyDir:
           medium: Memory
+      - name: prop-config-input
+      {{- end }}
+        configMap:
+          name: {{ include "common.fullname" . }}-prop
       - name: auth-config
         secret:
           secretName: {{ include "common.fullname" . }}
index b0ed0e8..a2abaf3 100644 (file)
@@ -36,10 +36,10 @@ aai.tools.password={{ .Values.global.config.basic.auth.passwd }}
 {{ end }}
 
 {{ if ( include "common.needTLS" .) }}
-aai.truststore.filename={{ .Values.global.config.truststore.filename }}
-aai.truststore.passwd.x={{ .Values.global.config.truststore.passwd }}
-aai.keystore.filename={{ .Values.global.config.keystore.filename }}
-aai.keystore.passwd.x={{ .Values.global.config.keystore.passwd }}
+aai.truststore.filename={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+aai.truststore.passwd.x=${TRUSTSTORE_PASSWORD}
+aai.keystore.filename={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.p12
+aai.keystore.passwd.x=${KEYSTORE_PASSWORD}
 {{ end }}
 
 aai.default.api.version={{ .Values.global.config.schema.version.api.default }}
index ad700dc..a3f7998 100644 (file)
@@ -39,12 +39,12 @@ server.basic.auth.location=${server.local.startpath}/etc/auth/realm.properties
 server.port=8452
 {{ if ( include "common.needTLS" .) }}
 server.ssl.enabled-protocols=TLSv1.1,TLSv1.2
-server.ssl.key-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.keystore.filename }}
-server.ssl.key-store-password=password({{ .Values.global.config.keystore.passwd }})
-server.ssl.trust-store=${server.local.startpath}/etc/auth/{{ .Values.global.config.truststore.filename }}
-server.ssl.trust-store-password=password({{ .Values.global.config.truststore.passwd }})
+server.ssl.key-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.p12
+server.ssl.key-store-password=${KEYSTORE_PASSWORD}
+server.ssl.trust-store={{ .Values.certInitializer.credsPath }}/{{ .Values.certInitializer.fqi_namespace }}.trust.jks
+server.ssl.trust-store-password=${TRUSTSTORE_PASSWORD}
 server.ssl.client-auth=want
-server.ssl.key-store-type=JKS
+server.ssl.key-store-type=PKCS12
 {{ else }}
 security.require-ssl=false
 server.ssl.enabled=false
index cfcd3c0..e91e257 100644 (file)
 
   <logger name="org.onap.aai.aaf.auth" level="DEBUG" additivity="false">
     <appender-ref ref="asyncAUTH" />
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.aailog.logs.AaiScheduledTaskAuditLog" level="INFO">
     <appender-ref ref="asyncAUDIT"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
 
   <logger name="org.onap.logging.filter.base.AbstractAuditLogFilter" level="INFO">
     <appender-ref ref="asyncAUDIT"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
 
   <logger name="org.onap.aai.logging.ErrorLogHelper" level="WARN">
     <appender-ref ref="asyncERROR"/>
+    <appender-ref ref="STDOUT"/>
   </logger>
   <logger name="org.onap.aai.schemaservice.interceptors.post" level="DEBUG" additivity="false">
     <appender-ref ref="asynctranslog" />
+    <appender-ref ref="STDOUT"/>
   </logger>
 
   <logger name="org.apache" level="OFF"/>
index 988bb24..7c8539d 100644 (file)
@@ -10,6 +10,7 @@ ModelLoader:OBF:1qvu1v2h1sov1sar1wfw1j7j1wg21saj1sov1v1x1qxw,admin
 AaiUI:OBF:1gfr1p571unz1p4j1gg7,admin
 OOF:OBF:1img1ke71ily,admin
 aai@aai.onap.org:OBF:1fia1ju61l871lfe18xp18xr18xt1lc41l531jrk1fek,admin
+aai-graphadmin@aai-graphadmin.onap.org:OBF:1fia1ju61l871lfe18xp18xr18xt1lc41l531jrk1fek,admin
 so@so.onap.org:OBF:1fia1ju61l871lfe18xp18xr18xt1lc41l531jrk1fek,admin
 sdnc@sdnc.onap.org:OBF:1fia1ju61l871lfe18xp18xr18xt1lc41l531jrk1fek,admin
 dcae@dcae.onap.org:OBF:1fia1ju61l871lfe18xp18xr18xt1lc41l531jrk1fek,admin
index d80dc5a..5a41aef 100644 (file)
@@ -21,6 +21,9 @@ dependencies:
     # a part of this chart's package and will not
     # be published independently to a repo (at this point)
     repository: '@local'
+  - name: certInitializer
+    version: ~9.x-0
+    repository: '@local'
   - name: repositoryGenerator
     version: ~9.x-0
     repository: '@local'
index 23a2af5..9573871 100644 (file)
@@ -30,7 +30,7 @@ data:
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-localhost-access-log-configmap
+  name: {{ include "common.fullname" . }}-localhost-access-log
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
@@ -43,7 +43,7 @@ data:
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-aaiconfig-configmap
+  name: {{ include "common.fullname" . }}-aaiconfig
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
@@ -56,7 +56,7 @@ data:
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-springapp-configmap
+  name: {{ include "common.fullname" . }}-springapp
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
@@ -69,7 +69,7 @@ data:
 apiVersion: v1
 kind: ConfigMap
 metadata:
-  name: {{ include "common.fullname" . }}-realm-configmap
+  name: {{ include "common.fullname" . }}-realm
   namespace: {{ include "common.namespace" . }}
   labels:
     app: {{ include "common.name" . }}
index 7c25ab7..e4f1d72 100644 (file)
@@ -40,16 +40,52 @@ spec:
       annotations:
         checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
     spec:
+      {{- if .Values.global.aafEnabled }}
+      initContainers: {{ include "common.certInitializer.initContainer" . | nindent 6 }}
+      - command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop | xargs -0)
+          echo "*** obfuscate them "
+          export KEYSTORE_PLAIN_PASSWORD=${KEYSTORE_PLAIN_PASSWORD}
+          export TRUSTSTORE_PLAIN_PASSWORD=${TRUSTSTORE_PLAIN_PASSWORD}
+          export KEYSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${KEYSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          export TRUSTSTORE_PASSWORD=`java -cp /usr/local/jetty/lib/jetty-util-9.4.44.v20210927.jar org.eclipse.jetty.util.security.Password ${TRUSTSTORE_PLAIN_PASSWORD} 2>&1 | grep "OBF:"`
+          echo "KEYSTORE_PASSWORD=${KEYSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+          echo "TRUSTSTORE_PASSWORD=${TRUSTSTORE_PASSWORD}" >> {{ .Values.certInitializer.appMountPath }}/local/mycreds.prop
+        image: {{ include "repositoryGenerator.image.jetty" . }}
+        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        name: {{ include "common.name" . }}-obfuscate
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
+        securityContext:
+          runAsUser: {{ .Values.securityContext.user_id }}
+      {{- end }}
       containers:
       - name: {{ include "common.name" . }}
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+        {{- if .Values.global.aafEnabled }}
+        command:
+        - sh
+        args:
+        - -c
+        - |
+          echo "*** retrieve Truststore and Keystore password"
+          export $(cat {{ .Values.certInitializer.credsPath }}/mycreds.prop | xargs -0)
+          echo "keystore pass: $KEYSTORE_PASSWORD"
+          echo "truststore pass: $TRUSTSTORE_PASSWORD"
+          echo "*** actual launch of AAI Schema Service"
+          /bin/bash /opt/app/aai-schema-service/docker-entrypoint.sh
+        {{- end }}
         env:
         - name: LOCAL_USER_ID
-          value: {{ .Values.global.config.userId | quote }}
+          value: {{ .Values.securityContext.user_id | quote }}
         - name: LOCAL_GROUP_ID
-          value: {{ .Values.global.config.groupId | quote }}
-        volumeMounts:
+          value: {{ .Values.securityContext.group_id | quote }}
+        volumeMounts: {{ include "common.certInitializer.volumeMount" . | nindent 8 }}
         - mountPath: /etc/localtime
           name: localtime
           readOnly: true
@@ -59,7 +95,7 @@ spec:
         - mountPath: /opt/aai/logroot/AAI-SS
           name: logs
         - mountPath: /opt/app/aai-schema-service/resources/logback.xml
-          name: {{ include "common.fullname" . }}-log-conf
+          name: log-conf
           subPath: logback.xml
         - mountPath: /opt/app/aai-schema-service/resources/localhost-access-logback.xml
           name: localhost-access-log-conf
@@ -70,12 +106,6 @@ spec:
         - mountPath: /opt/app/aai-schema-service/resources/application.properties
           name: springapp-conf
           subPath: application.properties
-          {{ $global := . }}
-          {{ range $job := .Values.global.config.auth.files }}
-        - mountPath: /opt/app/aai-schema-service/resources/etc/auth/{{ . }}
-          name: auth-truststore-sec
-          subPath: {{ . }}
-          {{ end }}
         ports:
         - containerPort: {{ .Values.service.internalPort }}
         - containerPort: {{ .Values.service.internalPort2 }}
@@ -107,7 +137,7 @@ spec:
       # side car containers
       {{ include "common.log.sidecar" . | nindent 6 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
-      volumes:
+      volumes: {{ include "common.certInitializer.volumes" . | nindent 6 }}
       - name: aai-common-aai-auth-mount
         secret:
           secretName: aai-common-aai-auth
@@ -117,29 +147,21 @@ spec:
       - name: logs
         emptyDir: {}
       {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix .)) | nindent 6 }}
-      - name: {{ include "common.fullname" . }}-log-conf
+      - name: log-conf
         configMap:
           name: {{ include "common.fullname" . }}-log
       - name: localhost-access-log-conf
         configMap:
-          name: {{ include "common.fullname" . }}-localhost-access-log-configmap
+          name: {{ include "common.fullname" . }}-localhost-access-log
       - name: springapp-conf
         configMap:
-          name: {{ include "common.fullname" . }}-springapp-configmap
+          name: {{ include "common.fullname" . }}-springapp
       - name: aaiconfig-conf
         configMap:
-          name: {{ include "common.fullname" . }}-aaiconfig-configmap
+          name: {{ include "common.fullname" . }}-aaiconfig
       - name: realm-conf
         configMap:
-          name: {{ include "common.fullname" . }}-realm-configmap
-      - name: auth-truststore-sec
-        secret:
-          secretName: aai-common-truststore
-          items:
-            {{ range $job := .Values.global.config.auth.files }}
-            - key: {{ . }}
-              path: {{ . }}
-            {{ end }}
+          name: {{ include "common.fullname" . }}-realm
       restartPolicy: {{ .Values.restartPolicy }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 121809e..7989bcc 100644 (file)
@@ -58,20 +58,40 @@ global: # global defaults
         edge:
           label: v12
 
-    # Keystore configuration password and filename
-    keystore:
-      filename: aai_keystore
-      passwd: OBF:1vn21ugu1saj1v9i1v941sar1ugw1vo0 # changeit
-
-    # Truststore configuration password and filename
-    truststore:
-      filename: aai_keystore
-      passwd: OBF:1vn21ugu1saj1v9i1v941sar1ugw1vo0 # changeit
-
-    # Specifies a list of files to be included in auth volume
-    auth:
-      files:
-        - aai_keystore
+#################################################################
+# Certificate configuration
+#################################################################
+certInitializer:
+  nameOverride: aai-schema-service-cert-initializer
+  aafDeployFqi: deployer@people.osaaf.org
+  aafDeployPass: demo123456!
+  # aafDeployCredsExternalSecret: some secret
+  fqdn: aai-schema-service
+  fqi: aai-schema-service@aai-schema-service.onap.org
+  public_fqdn: aai-schema-service.onap.org
+  cadi_longitude: "0.0"
+  cadi_latitude: "0.0"
+  app_ns: org.osaaf.aaf
+  credsPath: /opt/app/osaaf/local
+  fqi_namespace: org.onap.aai-schema-service
+  user_id: &user_id 1000
+  group_id: &group_id 1000
+  aaf_add_config: |
+    echo "*** changing them into shell safe ones"
+    export KEYSTORE_PLAIN_PASSWORD=$(tr -cd '[:alnum:]' < /dev/urandom | fold -w64 | head -n1)
+    export TRUSTSTORE_PLAIN_PASSWORD=$(tr -cd '[:alnum:]' < /dev/urandom | fold -w64 | head -n1)
+    cd {{ .Values.credsPath }}
+    keytool -storepasswd -new "${KEYSTORE_PLAIN_PASSWORD}" \
+      -storepass "${cadi_keystore_password_p12}" \
+      -keystore {{ .Values.fqi_namespace }}.p12
+    keytool -storepasswd -new "${TRUSTSTORE_PLAIN_PASSWORD}" \
+      -storepass "${cadi_truststore_password}" \
+      -keystore {{ .Values.fqi_namespace }}.trust.jks
+    echo "*** writing passwords into prop file"
+    echo "KEYSTORE_PLAIN_PASSWORD=${KEYSTORE_PLAIN_PASSWORD}" > {{ .Values.credsPath }}/mycreds.prop
+    echo "TRUSTSTORE_PLAIN_PASSWORD=${TRUSTSTORE_PLAIN_PASSWORD}" >> {{ .Values.credsPath }}/mycreds.prop
+    echo "*** change ownership of certificates to targeted user"
+    chown -R {{ .Values.user_id }}:{{ .Values.group_id }} {{ .Values.credsPath }}
 
 # application image
 image: onap/aai-schema-service:1.9.2
@@ -147,6 +167,11 @@ serviceAccount:
   roles:
     - read
 
+# Not fully used for now
+securityContext:
+  user_id: *user_id
+  group_id: *group_id
+
 #Log configuration
 log:
   path: /var/log/onap
index 48a6b04..6e5ab8b 100644 (file)
@@ -174,9 +174,11 @@ spec:
         configMap:
           name: {{ include "common.fullname" . }}
       - name: portal-config
+      {{- if .Values.global.aafEnabled }}
         emptyDir:
           medium: Memory
       - name: portal-config-input
+      {{- end }}
         configMap:
           name: {{ include "common.fullname" . }}-portal
       - name: portal-config-props
index f2e6ee6..ddd325d 100644 (file)
@@ -77,7 +77,7 @@ spec:
           {{- else }}
            until nc -w10 -z -v aai.{{.Release.Namespace}} 80; do echo "Retrying to reach aai on port 80"; done;
            bash -x /opt/app/aai-traversal/docker-entrypoint.sh install/updateQueryData.sh ;
-           {{- include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
+           {{ include "common.serviceMesh.killSidecar" . | indent 11 | trim }}
           {{- end }}
         env:
         - name: LOCAL_USER_ID
index b9a3e45..dc86acc 100644 (file)
Binary files a/kubernetes/aai/resources/config/aai/aai_keystore and b/kubernetes/aai/resources/config/aai/aai_keystore differ
index eb7aa54..a482152 100644 (file)
@@ -78,11 +78,10 @@ service:
       targetPort: *mgt_port
 
 prometheus:
-  enabled: true
+  enabled: false
 
 metrics:
   serviceMonitor:
-    enabled: true
     port: http-management
       ## specify target port if name is not given to the port in the service definition
       ##
index f831169..8b3f16b 100644 (file)
@@ -45,7 +45,7 @@ containerPort: &svc_port 8080
 managementPort: &mgt_port 8081
 
 prometheus:
-  enabled: true
+  enabled: false
 
 service:
   type: ClusterIP
@@ -60,7 +60,6 @@ service:
 
 metrics:
   serviceMonitor:
-    enabled: true
     port: http-management
       ## specify target port if name is not given to the port in the service definition
       ##
index a4a56de..753b8ba 100644 (file)
@@ -52,7 +52,7 @@ containerPort: &svc_port 8080
 managementPort: &mgt_port 8081
 
 prometheus:
-  enabled: true
+  enabled: false
 
 service:
   type: ClusterIP
@@ -66,7 +66,6 @@ service:
 
 metrics:
   serviceMonitor:
-    enabled: true
     port: http-management
       ## specify target port if name is not given to the port in the service definition
       ##
index dd0bf4b..aac0f4b 100644 (file)
@@ -272,6 +272,9 @@ spec:
         args:
         - --key-yaml
         - "{{ include "common.name" . }}|/app-config/application_config.yaml"
+        env:
+        - name: CONSUL_HOST
+          value: {{ .Values.consulHost | default "consul-server-ui" }}.{{ include "common.namespace" . }}
         resources: {{ include "common.resources" . | nindent 2 }}
         volumeMounts:
           - mountPath: /app-config
index 8ec60a7..58ae706 100644 (file)
@@ -43,7 +43,7 @@ readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
 # application image
-image: onap/org.onap.dcaegen2.deployments.healthcheck-container:2.2.0
+image: onap/org.onap.dcaegen2.deployments.healthcheck-container:2.3.0
 
 # Resource Limit flavor -By Default using small
 flavor: small
index 48673fe..a5ab9d6 100644 (file)
@@ -33,3 +33,6 @@ dependencies:
   - name: serviceAccount
     version: ~9.x-0
     repository: '@local'
+  - name: mongo
+    version: ~9.x-0
+    repository: '@local'
\ No newline at end of file
index e7707dc..2ba8edb 100644 (file)
@@ -86,6 +86,21 @@ service:
     - port: 9091
       name: http
 
+# mongoDB overrides
+mongo:
+  nameOverride: dcae-mongo
+  config:
+    dbName: dcaecommondb
+  service:
+    name: dcae-mongohost
+    internalPort: 27017
+  nfsprovisionerPrefix: dcaemongo
+  sdnctlPrefix: tcagen2
+  persistence:
+    mountSubPath: dcae/mongo/data
+    enabled: true
+  disableNfsProvisioner: true
+
 # Policy configuraiton properties
 # if enabled, policy-sync side car will be deployed
 #dcaePolicySyncImage: onap/org.onap.dcaegen2.deployments.dcae-services-policy-sync:1.0.1
index 948c479..f654ac8 100644 (file)
@@ -1,28 +1,52 @@
 {{/*
-#============LICENSE_START========================================================
-================================================================================
-# Copyright (c) 2021 J. F. Lucas. All rights reserved.
-================================================================================
-# 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.
-============LICENSE_END=========================================================
+  ============LICENSE_START========================================================
+  =================================================================================
+  Copyright (c) 2021 J. F. Lucas. All rights reserved.
+  =================================================================================
+  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.
+  =============LICENSE_END=========================================================
 */}}
-[
-{{- $ctx := . }}
-{{- $components := tuple "dcae-hv-ves-collector" "dcae-prh" "dcae-tcagen2" "dcae-ves-collector" }}
-{{- range $i, $v := $components }}
-{{- if index $ctx.Values . "enabled" }}
-{{- if $i }},{{ end }}
-{{ $v | quote | indent 2 }}
+
+{{/*
+
+  This template generates a JSON file with an array containing the names of the
+  components that the healthcheck container always expects to see--that is, the
+  components that are enabled in the top-level values.yaml file.
+
+  The code loops through the list of components ($components) and checks each component's
+  entry in the values.yaml file is set to "enabled".  It adds the name of each enabled
+  component to the list.
+
+  There is a bit of Helm trickery here--the code uses a dict ($enabled), because that's
+  apparently the only way to create a variable outside of a range loop that can be updated
+  from within the range loop.  The code here generates a list of the components that are
+  enabled in values.yaml, and stores it into the list called "enabled" in the dictionary
+  $enabled.
+
+  Note also the assignment to an otherwise unused variable ($x) in the loop.  Without that
+  assignment, the updated value of the $enabled.enabled list would be rendered into the
+  file each time an enabled component is found.
+
+*/}}
+
+{{- $ctx := . -}}
+{{- $components := list "dcae-hv-ves-collector" "dcae-prh" "dcae-tcagen2" "dcae-ves-collector" -}}
+{{- $enabled := dict "enabled" list -}}
+{{- range $components -}}
+  {{- if index $ctx.Values . "enabled" -}}
+    {{- $x:= . | append $enabled.enabled  | set $enabled "enabled" -}}
+  {{- end -}}
 {{- end -}}
-{{- end }}
-]
+{{- $enabled.enabled | toJson }}
+
+
index 4dcaff6..aa47c66 100644 (file)
@@ -27,9 +27,6 @@ dependencies:
     version: ~9.x-0
     repository: '@local'
     alias: postgres
-  - name: mongo
-    version: ~9.x-0
-    repository: '@local'
   - name: repositoryGenerator
     version: ~9.x-0
     repository: '@local'
index b012ee4..5b568c6 100644 (file)
@@ -89,20 +89,6 @@ postgres:
     mountSubPath: dcae/data
     mountInitPath: dcae
 
-mongo:
-  nameOverride: dcae-mongo
-  config:
-    dbName: dcaecommondb
-  service:
-    name: dcae-mongohost
-    internalPort: 27017
-  nfsprovisionerPrefix: dcaemongo
-  sdnctlPrefix: tcagen2
-  persistence:
-    mountSubPath: dcae/mongo/data
-    enabled: true
-  disableNfsProvisioner: true
-
 # application image
 image: onap/org.onap.dcaegen2.deployments.k8s-bootstrap-container:3.3.5
 default_k8s_location: central
index c7e1d70..171fc7c 100644 (file)
@@ -2,6 +2,7 @@
 #============LICENSE_START========================================================
 # ================================================================================
 # Copyright (c) 2019 AT&T Intellectual Property. All rights reserved.
+# Copyright (c) 2021 J. F. Lucas.  All rights reserved.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -106,7 +107,7 @@ spec:
             mountPath: /opt/tls
           env:
             - name: CONSUL_HOST
-              value: consul.{{ include "common.namespace" . }}
+              value: consul-server-ui.{{ include "common.namespace" . }}
             - name: USE_HTTPS
               value: "1"
             - name: HTTPS_CERT_PATH
@@ -154,7 +155,7 @@ spec:
             mountPath: /opt/logs
           env:
             - name: CONSUL_HOST
-              value: consul.{{ include "common.namespace" . }}
+              value: consul-server-ui.{{ include "common.namespace" . }}
         - name: {{ include "common.name" . }}-fb-onap-i
           image: {{ include "repositoryGenerator.image.logging" . }}
           imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
index 1c6cff0..8134e0d 100644 (file)
@@ -42,7 +42,7 @@ readiness:
   initialDelaySeconds: 10
   periodSeconds: 10
 # application image
-image: onap/org.onap.dcaegen2.deployments.healthcheck-container:2.2.0
+image: onap/org.onap.dcaegen2.deployments.healthcheck-container:2.3.0
 
 # Resource Limit flavor -By Default using small
 flavor: small
index 6b3a221..50c3184 100644 (file)
@@ -1,10 +1,51 @@
-[
-{{- $ctx := . }}
-{{- $components := tuple "dcae-cloudify-manager" "dcae-config-binding-service" "dcae-dashboard" "dcae-deployment-handler" "dcae-inventory-api" "dcae-policy-handler" "dcae-servicechange-handler" "dcae-ves-openapi-manager" }}
-{{- range $i, $v := $components }}
-{{- if index $ctx.Values . "enabled" }}
-{{- if $i }},{{ end }}
-{{ $v | quote | indent 2 }}
+{{/*
+  ============LICENSE_START========================================================
+  =================================================================================
+  Copyright (c) 2021 J. F. Lucas. All rights reserved.
+  =================================================================================
+  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.
+  =============LICENSE_END=========================================================
+*/}}
+
+{{/*
+
+  This template generates a JSON file with an array containing the names of the
+  components that the healthcheck container always expects to see--that is, the
+  components that are enabled in the top-level values.yaml file.
+
+  The code loops through the list of components ($components) and checks each component's
+  entry in the values.yaml file is set to "enabled".  It adds the name of each enabled
+  component to the list.
+
+  There is a bit of Helm trickery here--the code uses a dict ($enabled), because that's
+  apparently the only way to create a variable outside of a range loop that can be updated
+  from within the range loop.  The code here generates a list of the components that are
+  enabled in values.yaml, and stores it into the list called "enabled" in the dictionary
+  $enabled.
+
+  Note also the assignment to an otherwise unused variable ($x) in the loop.  Without that
+  assignment, the updated value of the $enabled.enabled list would be rendered into the
+  file each time an enabled component is found.
+
+*/}}
+
+{{- $ctx := . -}}
+{{- $components := list "dcae-cloudify-manager" "dcae-config-binding-service" "dcae-dashboard" "dcae-deployment-handler" "dcae-inventory-api" "dcae-policy-handler" "dcae-servicechange-handler" "dcae-ves-openapi-manager" -}}
+{{- $enabled := dict "enabled" list -}}
+{{- range $components -}}
+  {{- if index $ctx.Values . "enabled" -}}
+    {{- $x:= . | append $enabled.enabled  | set $enabled "enabled" -}}
+  {{- end -}}
 {{- end -}}
-{{- end }}
-]
+{{- $enabled.enabled | toJson }}
+
index 17b077b..7ce58ba 100644 (file)
@@ -40,32 +40,32 @@ passwordStrengthOverride: basic
 
 # Enable all DCAE components by default
 dcae-bootstrap:
-  enabled: true
+  enabled: false
   config:
     cloudifyManagerPasswordExternalSecret: *cmPassSecretName
 dcae-cloudify-manager:
-  enabled: true
+  enabled: false
   config:
     cloudifyManagerPasswordExternalSecret: *cmPassSecretName
 dcae-config-binding-service:
   enabled: true
 dcae-dashboard:
-  enabled: true
+  enabled: false
   config:
     cloudifyManagerPasswordExternalSecret: *cmPassSecretName
 dcae-deployment-handler:
-  enabled: true
+  enabled: false
   config:
     cloudifyManagerPasswordExternalSecret: *cmPassSecretName
 dcae-healthcheck:
   enabled: true
 dcae-inventory-api:
-  enabled: true
+  enabled: false
 dcae-policy-handler:
-  enabled: true
+  enabled: false
   config:
     cloudifyManagerPasswordExternalSecret: *cmPassSecretName
 dcae-servicechange-handler:
-  enabled: true
+  enabled: false
 dcae-ves-openapi-manager:
   enabled: true
index 1a2112b..fc16d8c 100644 (file)
@@ -20,12 +20,6 @@ metadata:
   name: {{ include "common.fullname" . }}-logging-configmap
   namespace: {{ include "common.namespace" . }}
 data:
-{{ tpl (.Files.Glob "resources/config/logging/server/*").AsConfig . | indent 2 }}
+{{ tpl (.Files.Glob "resources/config/log/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
+{{ include "common.log.configMap" . }}
index 8e28071..d9cbbef 100644 (file)
@@ -111,7 +111,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: {{ .Values.log.path }}
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/modeling/etsicatalog/config/log.yml
             subPath: log.yml
@@ -127,17 +127,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
+      {{ include "common.log.sidecar" . | nindent 8 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
         - name: {{ include "common.fullname" . }}-etsicatalog
@@ -156,10 +146,6 @@ spec:
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
 
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.fullname" . }}-modeling-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" . | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 3af4bae..b4d8837 100644 (file)
@@ -28,6 +28,8 @@ global:
     internalPort: 3306
     nameOverride: mariadb-galera
 
+  centralizedLoggingEnabled: true
+
 readinessCheck:
   wait_for:
     msb:
@@ -183,3 +185,7 @@ serviceAccount:
   nameOverride: modeling-etsicatalog
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
index 00d91fe..d9f902b 100644 (file)
@@ -92,30 +92,13 @@ spec:
         {{- end }}
 
         # Filebeat sidecar container
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap/msb/msb-discovery
-          - mountPath: /opt/ajsc/etc/config/logback.xml
-            name: {{ include "common.fullname" . }}-log-conf
-            subPath: logback.xml
+        {{ include "common.log.sidecar" . | nindent 8 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
         - name: {{ include "common.fullname" . }}-log-conf
           configMap:
             name: {{ include "common.fullname" . }}-log
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-msb-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
         - name:  {{ include "common.fullname" . }}-logs
           emptyDir: {}
         - name: localtime
index e980023..2d18d14 100644 (file)
@@ -88,3 +88,8 @@ serviceAccount:
   nameOverride: msb-discovery
   roles:
     - read
+
+#Logs configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index c30fc34..db24152 100644 (file)
@@ -104,20 +104,7 @@ spec:
 {{ toYaml .Values.affinity | indent 10 }}
         {{- end }}
         # side car containers
-        - name: filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap/msb/msb-eag
-          - mountPath: /opt/ajsc/etc/config/logback.xml
-            name: {{ include "common.fullname" . }}-log-conf
-            subPath: logback.xml
+        {{ include "common.log.sidecar" . | nindent 8 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
         {{ include "common.certInitializer.volumes" . | indent 8 | trim }}
@@ -127,11 +114,7 @@ spec:
         - name: {{ include "common.fullname" . }}-nginx-conf
           configMap:
             name: {{ include "common.fullname" . }}-nginx
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-msb-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
         - name:  {{ include "common.fullname" . }}-logs
           emptyDir: {}
         - name: localtime
index 9345341..565ff1f 100644 (file)
@@ -122,3 +122,8 @@ serviceAccount:
   nameOverride: msb-eag
   roles:
     - read
+
+#Logs configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 2a855c7..db24152 100644 (file)
@@ -104,20 +104,7 @@ spec:
 {{ toYaml .Values.affinity | indent 10 }}
         {{- end }}
         # side car containers
-        - name: filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap/msb/msb-iag
-          - mountPath: /opt/ajsc/etc/config/logback.xml
-            name: {{ include "common.fullname" . }}-log-conf
-            subPath: logback.xml
+        {{ include "common.log.sidecar" . | nindent 8 }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
         {{ include "common.certInitializer.volumes" . | indent 8 | trim }}
@@ -127,11 +114,7 @@ spec:
         - name: {{ include "common.fullname" . }}-nginx-conf
           configMap:
             name: {{ include "common.fullname" . }}-nginx
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-msb-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
         - name:  {{ include "common.fullname" . }}-logs
           emptyDir: {}
         - name: localtime
index 21f22dd..ca4935e 100644 (file)
@@ -123,3 +123,8 @@ serviceAccount:
   nameOverride: msb-iag
   roles:
     - read
+
+#Logs configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 5271429..385a37f 100644 (file)
 # See the License for the specific language governing permissions and
 # limitations under the License.
 */}}
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: {{ include "common.release" . }}-msb-filebeat-configmap
-  namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/filebeat/filebeat.yml").AsConfig . | indent 2 }}
+{{ include "common.log.configMap" . }}
index 5d3ffe0..4f1b659 100644 (file)
 #################################################################
 global:
   nodePortPrefix: 302
+  centralizedLoggingEnabled: true
 
 # application configuration
 config:
   logstashServiceName: log-ls
   logstashPort: 5044
+
+msb-discovery:
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-msb'
+msb-eag:
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-msb'
+msb-iag:
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-msb'
index b438bf0..fc46a65 100644 (file)
@@ -60,7 +60,7 @@ spec:
          value: "{{ .Values.config.ssl_enabled }}"
        name: {{ include "common.name" . }}
        volumeMounts:
-       - mountPath: /var/log/onap
+       - mountPath: "{{ .Values.log.path }}"
          name: fcaps-log
        - mountPath: /opt/fcaps/fcaps/pub/config/log.yml
          name: fcaps-logconfig
@@ -86,17 +86,7 @@ spec:
          failureThreshold: {{ .Values.liveness.failureThreshold }}
        {{ end }}
      # side car containers
-     - image: {{ include "repositoryGenerator.image.logging" . }}
-       imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-       name: filebeat-onap
-       volumeMounts:
-       - mountPath: /usr/share/filebeat/filebeat.yml
-         name: filebeat-conf
-         subPath: filebeat.yml
-       - mountPath: /var/log/onap
-         name: fcaps-log
-       - mountPath: /usr/share/filebeat/data
-         name: fcaps-data-filebeat
+     {{ include "common.log.sidecar" . | nindent 5 }}
      - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.rabbitmq }}
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
        name: rabbit-mq
@@ -104,11 +94,7 @@ spec:
      volumes:
      - name: fcaps-log
        emptyDir: {}
-     - name: fcaps-data-filebeat
-       emptyDir: {}
-     - name: filebeat-conf
-       configMap:
-         name: multicloud-filebeat-configmap
+     {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 5 }}
      - name: fcaps-logconfig
        configMap:
          name: {{ include "common.fullname" . }}-log-configmap
index 39ddbae..b664498 100644 (file)
@@ -95,3 +95,8 @@ serviceAccount:
   nameOverride: multicloud-fcaps
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index d12e663..ebebaac 100644 (file)
@@ -60,7 +60,7 @@ spec:
          value: "{{ .Values.config.ssl_enabled }}"
        name: {{ include "common.name" . }}
        volumeMounts:
-       - mountPath: /var/log/onap
+       - mountPath: "{{ .Values.log.path }}"
          name: pike-log
        - mountPath: /opt/pike/pike/pub/config/log.yml
          name: pike-logconfig
@@ -88,26 +88,12 @@ spec:
          failureThreshold: {{ .Values.liveness.failureThreshold }}
        {{ end }}
      # side car containers
-     - image: {{ include "repositoryGenerator.image.logging" . }}
-       imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-       name: filebeat-onap
-       volumeMounts:
-       - mountPath: /usr/share/filebeat/filebeat.yml
-         name: filebeat-conf
-         subPath: filebeat.yml
-       - mountPath: /var/log/onap
-         name: pike-log
-       - mountPath: /usr/share/filebeat/data
-         name: pike-data-filebeat
+     {{ include "common.log.sidecar" . | nindent 5 }}
      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
      volumes:
      - name: pike-log
        emptyDir: {}
-     - name: pike-data-filebeat
-       emptyDir: {}
-     - name: filebeat-conf
-       configMap:
-         name: multicloud-filebeat-configmap
+     {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix"  (tpl .Values.logConfigMapNamePrefix .)) | nindent 5 }}
      - name: pike-logconfig
        configMap:
          name: {{ include "common.fullname" . }}-log-configmap
index 5ef87f4..45c7309 100644 (file)
@@ -92,3 +92,8 @@ serviceAccount:
   nameOverride: multicloud-pike
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 7c39bb7..c9209a0 100644 (file)
@@ -60,7 +60,7 @@ spec:
           value: "{{ .Values.config.ssl_enabled }}"
         name: {{ include "common.name" . }}
         volumeMounts:
-        - mountPath: /var/log/onap
+        - mountPath: "{{ .Values.log.path }}"
           name: starlingx-log
         - mountPath: /opt/starlingx/starlingx/pub/config/log.yml
           name: starlingx-logconfig
@@ -87,17 +87,7 @@ spec:
           failureThreshold: {{ .Values.liveness.failureThreshold }}
         {{ end }}
       # side car containers
-      - image: {{ include "repositoryGenerator.image.logging" . }}
-        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-        name: filebeat-onap
-        volumeMounts:
-        - mountPath: /usr/share/filebeat/filebeat.yml
-          name: filebeat-conf
-          subPath: filebeat.yml
-        - mountPath: /var/log/onap
-          name: starlingx-log
-        - mountPath: /usr/share/filebeat/data
-          name: starlingx-data-filebeat
+      {{ include "common.log.sidecar" . | nindent 7 }}
       - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.artifactImage }}
         name: framework-artifactbroker
         command: ["/opt/app/distribution/bin/artifact-dist.sh"]
@@ -115,11 +105,7 @@ spec:
       volumes:
       - name: starlingx-log
         emptyDir: {}
-      - name: starlingx-data-filebeat
-        emptyDir: {}
-      - name: filebeat-conf
-        configMap:
-          name: multicloud-filebeat-configmap
+      {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 7 }}
       - name: starlingx-logconfig
         configMap:
           name: {{ include "common.fullname" . }}-log-configmap
index 69e4d94..f18a090 100644 (file)
@@ -94,3 +94,8 @@ serviceAccount:
   nameOverride: multicloud-starlingx
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 5548359..1d27d6e 100644 (file)
@@ -57,7 +57,7 @@ spec:
          value: "{{ .Values.config.aai.password }}"
        name: {{ include "common.name" . }}
        volumeMounts:
-       - mountPath: /var/log/onap
+       - mountPath: "{{ .Values.log.path }}"
          name: vio-log
        - mountPath: /opt/vio/vio/pub/config/log.yml
          name: vio-logconfig
@@ -83,26 +83,12 @@ spec:
          failureThreshold: {{ .Values.liveness.failureThreshold }}
        {{ end -}}
        # side car containers
-     - image: {{ include "repositoryGenerator.image.logging" . }}
-       imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-       name: filebeat-onap
-       volumeMounts:
-       - mountPath: /usr/share/filebeat/filebeat.yml
-         name: filebeat-conf
-         subPath: filebeat.yml
-       - mountPath: /var/log/onap
-         name: vio-log
-       - mountPath: /usr/share/filebeat/data
-         name: vio-data-filebeat
+     {{ include "common.log.sidecar" . | nindent 5 }}
      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
      volumes:
      - name: vio-log
        emptyDir: {}
-     - name: vio-data-filebeat
-       emptyDir: {}
-     - name: filebeat-conf
-       configMap:
-         name: multicloud-filebeat-configmap
+     {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 5 }}
      - name: vio-logconfig
        configMap:
          name: {{ include "common.fullname" . }}-log-configmap
index 5b218f1..17643ba 100644 (file)
@@ -91,3 +91,8 @@ serviceAccount:
   nameOverride: multicloud-vio
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index f46e450..dfb4bbc 100644 (file)
@@ -69,7 +69,7 @@ spec:
           value: "{{ .Values.config.ssl_enabled }}"
         name: {{ include "common.name" . }}
         volumeMounts:
-        - mountPath: /var/log/onap
+        - mountPath: "{{ .Values.log.path }}"
           name: windriver-log
         - mountPath: /opt/windriver/titanium_cloud/pub/config/log.yml
           name: windriver-logconfig
@@ -96,17 +96,7 @@ spec:
           failureThreshold: {{ .Values.liveness.failureThreshold }}
         {{ end }}
       # side car containers
-      - image: {{ include "repositoryGenerator.image.logging" . }}
-        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-        name: filebeat-onap
-        volumeMounts:
-        - mountPath: /usr/share/filebeat/filebeat.yml
-          name: filebeat-conf
-          subPath: filebeat.yml
-        - mountPath: /var/log/onap
-          name: windriver-log
-        - mountPath: /usr/share/filebeat/data
-          name: windriver-data-filebeat
+      {{ include "common.log.sidecar" . | nindent 7 }}
       - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.artifactImage }}
         name: framework-artifactbroker
         command: ["/opt/app/distribution/bin/artifact-dist.sh"]
@@ -124,11 +114,7 @@ spec:
       volumes:
       - name: windriver-log
         emptyDir: {}
-      - name: windriver-data-filebeat
-        emptyDir: {}
-      - name: filebeat-conf
-        configMap:
-          name: multicloud-filebeat-configmap
+      {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 7 }}
       - name: windriver-logconfig
         configMap:
           name: {{ include "common.fullname" . }}-log-configmap
index d520a78..802659f 100644 (file)
@@ -103,3 +103,8 @@ serviceAccount:
   nameOverride: multicloud-windriver
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 0800fbe..c76f531 100644 (file)
 # limitations under the License.
 */}}
 
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: multicloud-filebeat-configmap
-  namespace: {{ include "common.namespace" . }}
-  labels:
-    app: {{ include "common.name" . }}
-    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
-    release: {{ include "common.release" . }}
-    heritage: {{ .Release.Service }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }}
+{{ include "common.log.configMap" . }}
 ---
 apiVersion: v1
 kind: ConfigMap
index 34fe622..53716e5 100644 (file)
@@ -63,7 +63,7 @@ spec:
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
        name: {{ include "common.name" . }}
        volumeMounts:
-       - mountPath: /var/log/onap
+       - mountPath: "{{ .Values.log.path }}"
          name: framework-log
        - mountPath: /opt/multivimbroker/multivimbroker/pub/config/log.yml
          name: framework-logconfig
@@ -89,17 +89,7 @@ spec:
        {{ end -}}
 
       # side car containers
-     - image: {{ include "repositoryGenerator.image.logging" . }}
-       imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-       name: filebeat-onap
-       volumeMounts:
-       - mountPath: /usr/share/filebeat/filebeat.yml
-         name: filebeat-conf
-         subPath: filebeat.yml
-       - mountPath: /var/log/onap
-         name: framework-log
-       - mountPath: /usr/share/filebeat/data
-         name: framework-data-filebeat
+     {{ include "common.log.sidecar" . | nindent 5 }}
      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
      volumes:
      - name: framework-log
@@ -107,11 +97,7 @@ spec:
      - name: provider-plugin
        configMap:
          name: {{ include "common.fullname" . }}-provider-plugin-configmap
-     - name: framework-data-filebeat
-       emptyDir: {}
-     - name: filebeat-conf
-       configMap:
-         name: multicloud-filebeat-configmap
+     {{ include "common.log.volumes" . | nindent 5 }}
      - name: framework-logconfig
        configMap:
          name: {{ include "common.fullname" . }}-log-configmap
index 90e72be..4f946a7 100644 (file)
@@ -22,6 +22,7 @@ global:
   prometheus:
     enabled: false
   persistence: {}
+  centralizedLoggingEnabled: true
 
 #################################################################
 # Application configuration defaults.
@@ -35,18 +36,23 @@ istioSidecar: true
 
 multicloud-fcaps:
   enabled: true
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-multicloud'
 multicloud-k8s:
   enabled: true
 multicloud-pike:
   enabled: true
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-multicloud'
 multicloud-prometheus:
   enabled: false
 multicloud-starlingx:
   enabled: false
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-multicloud'
 multicloud-vio:
   enabled: false
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-multicloud'
 multicloud-windriver:
   enabled: false
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-multicloud'
 
 # application configuration
 config:
@@ -114,3 +120,7 @@ serviceAccount:
   nameOverride: multicloud
   roles:
     - read
+
+#Log configuration
+log:
+  path: /var/log/onap
index b1bd0ed..8f00ac7 100644 (file)
@@ -153,9 +153,13 @@ PCI:
     ml_enabled: false
 
 nxi_termination:
-    query_templates:
-        nsi: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','e2eserviceprofile-service')"
-        nsi_with_profile: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','e2eserviceprofile-service')('service-instance-id','{{ printf "{{profile_id}}" }}')"
-        nssi: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','nsi')"
-        nssi_with_nsi: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','nsi')('service-instance-id','{{ printf "{{nsi_id}}" }}')"
-
+        query_templates:
+                nsi: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','e2eserviceprofile-service')"
+                nsi_with_profile: "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}') > service-instance*('service-role','e2eserviceprofile-service')('service-instance-id','{{ printf "{{profile_id}}" }}')"
+                nssi:
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'CN') > service-instance*('service-role','nsi')"
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'TN_BH') > service-instance*('service-role','nsi')"
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'AN') > service-instance*('service-role','nsi')"
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'AN_NF') > service-instance*('workload-context','AN')"
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'TN_MH') > service-instance*('workload-context','AN')"
+                    - "service-instance*('service-instance-id','{{ printf "{{instance_id}}" }}')('workload-context', 'AN_NF') > service-instance*('workload-context','AN')"
index 8a6c60e..16d4113 100644 (file)
@@ -25,7 +25,7 @@ participant:
     port: 6969
     userName: ${API_USER}
     password: ${API_PASSWORD}
-    https: true
+    useHttps: true
     allowSelfSignedCerts: true
   policyPapParameters:
     clientName: pap
@@ -33,7 +33,7 @@ participant:
     port: 6969
     userName: ${PAP_USER}
     password: ${PAP_PASSWORD}
-    https: true
+    useHttps: true
     allowSelfSignedCerts: true
   intermediaryParameters:
     reportingTimeIntervalMs: 120000
index 39393ef..db4454d 100644 (file)
@@ -158,7 +158,7 @@ spec:
         - name: properties-onapportal
           mountPath: "{{ .Values.global.env.tomcatDir }}/temp"
         - name: var-log-onap
-          mountPath: /var/log/onap
+          mountPath: "{{ .Values.log.path }}"
         resources:
 {{ include "common.resources" . }}
       {{- if .Values.nodeSelector }}
@@ -169,17 +169,7 @@ spec:
       affinity:
 {{ toYaml .Values.affinity | indent 10 }}
       {{- end }}
-      - name: filebeat-onap
-        image: {{ include "repositoryGenerator.image.logging" . }}
-        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-        volumeMounts:
-        - mountPath: /usr/share/filebeat/filebeat.yml
-          name: filebeat-conf
-          subPath: filebeat.yml
-        - name: portal-data-filebeat
-          mountPath: /usr/share/filebeat/data
-        - name: var-log-onap
-          mountPath: /var/log/onap
+      {{ include "common.log.sidecar" . | nindent 6 }}
       volumes:
 {{ include "common.certInitializer.volumes" . | indent 8 }}
         - name: localtime
@@ -192,13 +182,9 @@ spec:
           configMap:
             name: {{ include "common.fullname" . }}-onapportal
             defaultMode: 0755
-        - name: filebeat-conf
-          configMap:
-            name: portal-filebeat
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
         - name: var-log-onap
           emptyDir: {}
-        - name: portal-data-filebeat
-          emptyDir: {}
         - name: portal-tomcat-logs
           emptyDir: {}
       imagePullSecrets:
index b46876c..6cf2513 100644 (file)
@@ -166,3 +166,8 @@ resources:
       cpu: 2
       memory: 8Gi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 95247b3..abc5daa 100644 (file)
@@ -149,7 +149,7 @@ spec:
         - name: portal-tomcat-logs
           mountPath: "{{ .Values.global.env.tomcatDir }}/logs"
         - name: var-log-onap
-          mountPath: /var/log/onap
+          mountPath: "{{ .Values.log.path }}"
         resources:
 {{ include "common.resources" . }}
       {{- if .Values.nodeSelector }}
@@ -160,17 +160,7 @@ spec:
       affinity:
 {{ toYaml .Values.affinity | indent 10 }}
       {{- end }}
-      - name: filebeat-onap
-        image: {{ include "repositoryGenerator.image.logging" . }}
-        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-        volumeMounts:
-        - mountPath: /usr/share/filebeat/filebeat.yml
-          name: filebeat-conf
-          subPath: filebeat.yml
-        - name: portal-data-filebeat
-          mountPath: /usr/share/filebeat/data
-        - name: var-log-onap
-          mountPath: /var/log/onap
+      {{ include "common.log.sidecar" . | nindent 6 }}
       volumes:
         - name: localtime
           hostPath:
@@ -182,13 +172,9 @@ spec:
           configMap:
             name: {{ include "common.fullname" . }}-onapportalsdk
             defaultMode: 0755
-        - name: filebeat-conf
-          configMap:
-            name: portal-filebeat
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix .)) | nindent 8 }}
         - name: var-log-onap
           emptyDir: {}
-        - name: portal-data-filebeat
-          emptyDir: {}
         - name: portal-tomcat-logs
           emptyDir: {}
 {{ include "common.certInitializer.volumes" . | indent 8 }}
index 7631c3a..f0c3954 100644 (file)
@@ -161,3 +161,8 @@ resources:
       cpu: 4
       memory: 10Gi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index a474a6c..681f24e 100644 (file)
 # limitations under the License.
 */}}
 
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: portal-filebeat
-  namespace: {{ include "common.namespace" . }}
-  labels:
-    app: {{ include "common.name" . }}
-    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
-    release: {{ include "common.release" . }}
-    heritage: {{ .Release.Service }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/filebeat/filebeat.yml").AsConfig . | indent 2 }}
-
+{{ include "common.log.configMap" . }}
index 0d4b023..0e6c9d6 100644 (file)
@@ -22,6 +22,8 @@ global:
   # application's front end hostname.  Must be resolvable on the client side environment
   portalHostName: "portal.api.simpledemo.onap.org"
 
+  centralizedLoggingEnabled: true
+
 #################################################################
 # Secrets metaconfig
 #################################################################
@@ -72,6 +74,7 @@ portal-app:
   cassandra:
     config:
       cassandraExternalSecret: *dbSecretName
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-portal'
 portal-sdk:
   mariadb:
     config:
@@ -79,6 +82,7 @@ portal-sdk:
   cassandra:
     config:
       cassandraExternalSecret: *dbSecretName
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-portal'
 messageRouter:
   service:
     name: message-router
index eec1988..0449648 100644 (file)
@@ -35,8 +35,8 @@ global:
 # Application configuration defaults.
 #################################################################
 # application image
-image: onap/sdc-backend-all-plugins:1.9.4
-backendInitImage: onap/sdc-backend-init:1.9.4
+image: onap/sdc-backend-all-plugins:1.9.5
+backendInitImage: onap/sdc-backend-init:1.9.5
 
 pullPolicy: Always
 
index a36fdb5..e00475a 100644 (file)
@@ -38,8 +38,8 @@ global:
 #################################################################
 # application image
 repository: nexus3.onap.org:10001
-image: onap/sdc-cassandra:1.9.4
-cassandraInitImage: onap/sdc-cassandra-init:1.9.4
+image: onap/sdc-cassandra:1.9.5
+cassandraInitImage: onap/sdc-cassandra-init:1.9.5
 pullPolicy: Always
 
 config:
index bb68dd3..a208226 100644 (file)
@@ -47,7 +47,7 @@ certInitializer:
 # Application configuration defaults.
 #################################################################
 # application image
-image: onap/sdc-frontend:1.9.4
+image: onap/sdc-frontend:1.9.5
 pullPolicy: Always
 
 config:
index ae6de7f..d8cc670 100644 (file)
@@ -59,8 +59,8 @@ certInitializer:
 # Application configuration defaults.
 #################################################################
 # application image
-image: onap/sdc-onboard-backend:1.9.4
-onboardingInitImage: onap/sdc-onboard-cassandra-init:1.9.4
+image: onap/sdc-onboard-backend:1.9.5
+onboardingInitImage: onap/sdc-onboard-cassandra-init:1.9.5
 pullPolicy: Always
 
 # flag to enable debugging - application support required
index 06b8649..f53c41c 100644 (file)
@@ -121,7 +121,6 @@ spec:
           value: "{{ .Values.config.sdnr.oauth.odluxRbac.enabled | default "true" }}"
         {{ end }}
 
-
         volumeMounts:
         - mountPath: /config-input
           name: config-input
@@ -130,11 +129,11 @@ spec:
         image: {{ include "repositoryGenerator.image.envsubst" . }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-update-config
-      {{ if .Values.dgbuilder.enabled -}}
+      {{ if or .Values.dgbuilder.enabled .Values.config.sdnr.enabled -}}
       - command:
         - /app/ready.py
         args:
-        {{ if or .Values.dgbuilder.enabled .Values.config.sdnr.enabled -}}
+        {{ if .Values.dgbuilder.enabled -}}
         - --container-name
         - {{ include "common.mariadbService" . }}
         - --job-name
@@ -200,8 +199,10 @@ spec:
             initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
             periodSeconds: {{ .Values.readiness.periodSeconds }}
           env:
+          {{ if and .Values.config.sdnr.enabled .Values.config.sdnr.sdnronly -}}
           - name: MYSQL_ROOT_PASSWORD
             {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "db-root-password" "key" "password") | indent 12 }}
+          {{ end -}}
           - name: ODL_ADMIN_USERNAME
             {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "odl-creds" "key" "login") | indent 12 }}
           - name: ODL_USER
@@ -309,6 +310,27 @@ spec:
             value: "{{ .Values.config.sdnr.oauth.enabled | default "false" }}"
           - name: SDNR_NETCONF_CALLHOME_ENABLED
             value: "{{ .Values.config.sdnr.netconfCallHome.enabled | default "false" }}"
+          - name: SDNR_VES_COLLECTOR_ENABLED
+            value: "{{ .Values.config.sdnr.vesCollector.enabled }}"
+          - name: SDNR_VES_COLLECTOR_TLS_ENABLED
+            value: "{{ .Values.config.sdnr.vesCollector.tls.enabled }}"
+          - name: SDNR_VES_COLLECTOR_TRUST_ALL_CERTS
+            value: "{{ .Values.config.sdnr.vesCollector.trustAllCertificates }}"
+          - name: SDNR_VES_COLLECTOR_IP
+            value: "{{ .Values.config.sdnr.vesCollector.address }}"
+          - name: SDNR_VES_COLLECTOR_PORT
+            value: "{{ .Values.config.sdnr.vesCollector.port }}"
+          - name: SDNR_VES_COLLECTOR_VERSION
+            value: "{{ .Values.config.sdnr.vesCollector.version | default "v7" }}"
+          - name: SDNR_VES_COLLECTOR_REPORTING_ENTITY_NAME
+            value: "{{ .Values.config.sdnr.vesCollector.reportingEntityName | default "ONAP SDN-R" }}"
+          - name: SDNR_VES_COLLECTOR_EVENTLOG_MSG_DETAIL
+            value: "{{ .Values.config.sdnr.vesCollector.eventLogMsgDetail | default "SHORT" }}"
+          - name: SDNR_VES_COLLECTOR_USERNAME
+            {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "ves-collector-secret" "key" "login") | indent 12 }}
+          - name: SDNR_VES_COLLECTOR_PASSWORD
+            {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "ves-collector-secret" "key" "password") | indent 12 }}
+
           volumeMounts:
 {{ include "common.certInitializer.volumeMount" . | indent 10 }}
 {{- if .Values.global.cmpv2Enabled }}
index 15a8045..cbf5678 100644 (file)
@@ -181,7 +181,10 @@ secrets:
     externalSecret: '{{ ternary (tpl (default "" .Values.config.sdnr.oauth.providersSecrets.keycloakExternalSecret) .) "oauth-disabled" .Values.config.sdnr.oauth.enabled }}'
     password: '{{ .Values.config.sdnr.oauth.providersSecrets.keycloak }}'
     passwordPolicy: required
-
+  - uid: ves-collector-secret
+    type: basicAuth
+    login: '{{ .Values.config.sdnr.vesCollector.username }}'
+    password: '{{ .Values.config.sdnr.vesCollector.password }}'
 #################################################################
 # Certificates
 #################################################################
@@ -261,6 +264,7 @@ config:
   ansibleUser: sdnc
   ansiblePassword: sdnc
   # ansibleCredsExternalSecret: some secret
+
   dbSdnctlDatabase: &sdncDbName sdnctl
   enableClustering: true
   sdncHome: /opt/onap/sdnc
@@ -354,6 +358,18 @@ config:
         title: ONAP Keycloak Provider
         roleMapping:
           mykeycloak: admin
+    vesCollector:
+      enabled: false
+      tls:
+        enabled: true
+      trustAllCertificates: false
+      username: sample1
+      password: sample1
+      address: dcae-ves-collector.onap
+      port: 8443
+      version: v7
+      reportingEntityName: ONAP SDN-R
+      eventLogMsgDetail: SHORT
 
 # dependency / sub-chart configuration
 certInitializer:
@@ -501,6 +517,7 @@ elasticsearch:
     dedicatednode: "no"
     nameOverride: *elasticSearchName
     cluster_name: sdnrdb-cluster
+
 # enable
 sdnc-web:
   enabled: true
diff --git a/kubernetes/uui/components/uui-nlp/Chart.yaml b/kubernetes/uui/components/uui-nlp/Chart.yaml
new file mode 100644 (file)
index 0000000..3f09b48
--- /dev/null
@@ -0,0 +1,22 @@
+#============LICENSE_START========================================================
+# ================================================================================
+# Copyright (c) 2021 AT&T. All rights reserved.
+# Modifications Copyright Â© 2021 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.
+# ============LICENSE_END=========================================================
+
+apiVersion: v1
+description: ONAP UUI NLP
+name: uui-nlp
+version: 9.0.0
diff --git a/kubernetes/uui/components/uui-nlp/requirements.yaml b/kubernetes/uui/components/uui-nlp/requirements.yaml
new file mode 100644 (file)
index 0000000..52fd1da
--- /dev/null
@@ -0,0 +1,27 @@
+#============LICENSE_START========================================================
+# Copyright (c) 2021 AT&T. All rights reserved.
+# Modifications Copyright Â© 2021 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.
+# ============LICENSE_END=========================================================
+
+dependencies:
+  - name: common
+    version: ~9.x-0
+    repository: '@local'
+  - name: repositoryGenerator
+    version: ~9.x-0
+    repository: '@local'
+  - name: serviceAccount
+    version: ~9.x-0
+    repository: '@local'
diff --git a/kubernetes/uui/components/uui-nlp/templates/deployment.yaml b/kubernetes/uui/components/uui-nlp/templates/deployment.yaml
new file mode 100644 (file)
index 0000000..e72ee44
--- /dev/null
@@ -0,0 +1,62 @@
+{{/*
+#============LICENSE_START========================================================
+# ================================================================================
+# Copyright (c) 2021 AT&T. All rights reserved.
+# ================================================================================
+# 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.
+# ============LICENSE_END=========================================================
+*/}}
+
+apiVersion: apps/v1
+kind: Deployment
+metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
+spec:
+  replicas: 1
+  selector: {{- include "common.selectors" . | nindent 4 }}
+  template:
+    metadata: {{- include "common.templateMetadata" . | nindent 6 }}
+    spec:
+      {{ include "common.podSecurityContext" . | indent 6 | trim}}
+      containers:
+        - name: {{ include "common.name" . }}
+          image:  {{  include "repositoryGenerator.repository" . }}/{{ .Values.image }}
+          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+          resources: {{ include "common.resources" . | nindent 12 }}
+          ports: {{ include "common.containerPorts" . | nindent 12 }}
+          {{- if eq .Values.liveness.enabled true }}
+          livenessProbe:
+            tcpSocket:
+              port: {{ .Values.service.internalPort }}
+            initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
+            periodSeconds: {{ .Values.liveness.periodSeconds }}
+          {{ end }}
+          readinessProbe:
+            tcpSocket:
+              port: {{ .Values.service.internalPort }}
+            initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
+            periodSeconds: {{ .Values.readiness.periodSeconds }}
+          volumeMounts:
+          - mountPath: /home/run/bert-master/upload
+            name: uui-server-v
+      serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
+      volumes:
+      - name: uui-server-v
+      {{- if .Values.persistence.enabled }}
+        persistentVolumeClaim:
+          claimName: {{ include "common.fullname" . }}
+      {{- else }}
+        emptyDir: {}
+      {{- end }}
+
+      imagePullSecrets:
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"
diff --git a/kubernetes/uui/components/uui-nlp/templates/ingress.yaml b/kubernetes/uui/components/uui-nlp/templates/ingress.yaml
new file mode 100644 (file)
index 0000000..8f87c68
--- /dev/null
@@ -0,0 +1 @@
+{{ include "common.ingress" . }}
diff --git a/kubernetes/uui/components/uui-nlp/templates/pv.yaml b/kubernetes/uui/components/uui-nlp/templates/pv.yaml
new file mode 100644 (file)
index 0000000..a05ebfb
--- /dev/null
@@ -0,0 +1,20 @@
+{{/*
+#============LICENSE_START========================================================
+# ================================================================================
+# Copyright (c) 2021 AT&T Intellectual Property. All rights reserved.
+# ================================================================================
+# 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.
+# ============LICENSE_END=========================================================
+*/}}
+
+{{ include "common.PV" . }}
\ No newline at end of file
diff --git a/kubernetes/uui/components/uui-nlp/templates/pvc.yaml b/kubernetes/uui/components/uui-nlp/templates/pvc.yaml
new file mode 100644 (file)
index 0000000..2bd21dd
--- /dev/null
@@ -0,0 +1,19 @@
+{{/*
+################################################################################
+#   Copyright (c) 2021 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.                                             #
+################################################################################
+*/}}
+
+{{ include "common.PVC" . }}
\ No newline at end of file
diff --git a/kubernetes/uui/components/uui-nlp/templates/service.yaml b/kubernetes/uui/components/uui-nlp/templates/service.yaml
new file mode 100644 (file)
index 0000000..40aaa73
--- /dev/null
@@ -0,0 +1,20 @@
+{{/*
+#============LICENSE_START========================================================
+# ================================================================================
+# Copyright (c) 2021 AT&T. All rights reserved.
+# ================================================================================
+# 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.
+# ============LICENSE_END=========================================================
+*/}}
+
+{{ include "common.service" . }}
diff --git a/kubernetes/uui/components/uui-nlp/values.yaml b/kubernetes/uui/components/uui-nlp/values.yaml
new file mode 100644 (file)
index 0000000..3fb70fe
--- /dev/null
@@ -0,0 +1,96 @@
+#============LICENSE_START========================================================
+#=================================================================================
+# Copyright (c) 2021 AT&T. All rights reserved.
+# ================================================================================
+# 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.
+# ============LICENSE_END=========================================================
+
+# Global values
+global:
+  pullPolicy: Always
+  persistence: {}
+image: onap/usecase-ui-nlp:1.0.2
+
+uui-nlp:
+  enabled: true
+
+flavor: large
+
+onLinePort: &online_port 33011
+offLinePort: &offline_port 33012
+uploadPort: &upload_port 33013
+
+# service configuration
+service:
+  internalPort: 33013
+  type: ClusterIP
+  name: uui-nlp
+  ports:
+    - name: http-online
+      port: *online_port
+    - name: http-offline
+      port: *offline_port
+    - name: http-upload
+      port: *upload_port
+
+
+liveness:
+  initialDelaySeconds: 300
+  periodSeconds: 30
+  enabled: true
+
+readiness:
+  initialDelaySeconds: 300
+  periodSeconds: 10
+
+# Below parameter should match setting in all clients
+# including contrib\tools\registry-initialize.sh
+# which does preload
+#registryCred:
+#  username: onapinitializer
+#  password: demo123456!
+
+# Parameters for persistent storage
+persistence:
+  enabled: true
+  accessMode: ReadWriteOnce
+  size: 4Gi
+  mountPath: /dockerdata-nfs
+  mountSubPath: uui-nlp
+  volumeReclaimPolicy: Retain
+
+serviceAccount:
+  nameOverride: uui-nlp
+  roles:
+    - read
+
+securityContext:
+  user_id: 1000
+  group_id: 1000
+
+resources:
+  small:
+    limits:
+      cpu: 1
+      memory: 1Gi
+    requests:
+      cpu: 0.5
+      memory: 512Mi
+  large:
+    limits:
+      cpu: 2
+      memory: 2Gi
+    requests:
+      cpu: 1
+      memory: 1Gi
+  unlimited: {}
index 05d649f..d60dc43 100644 (file)
@@ -29,3 +29,7 @@ dependencies:
   - name: uui-server
     version: ~9.x-0
     repository: 'file://components/uui-server'
+  - name: uui-nlp
+    version: ~9.x-0
+    repository: 'file://components/uui-nlp'
+    condition: uui-nlp.enabled
index c910f47..d5a043d 100644 (file)
@@ -69,7 +69,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: "{{ .Values.log.path }}"
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/vfc/gvnfmdriver/config/log.yml
             subPath: log.yml
@@ -85,18 +85,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -106,11 +95,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index dcdcef8..d92989d 100644 (file)
@@ -85,3 +85,8 @@ resources:
       cpu: 200m
       memory: 500Mi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 4f74d1d..dd763b4 100644 (file)
@@ -72,7 +72,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: {{ .Values.log.path }}
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/vfc/hwvnfmdriver/config/log4j.properties
             subPath: log4j.properties
@@ -88,18 +88,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -109,11 +98,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 548cab8..596a1cf 100644 (file)
@@ -86,4 +86,9 @@ resources:
     requests:
       cpu: 200m
       memory: 2000Mi
-  unlimited: {}
\ No newline at end of file
+  unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 17d8cc2..13c1705 100644 (file)
@@ -115,18 +115,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -136,11 +125,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index be78200..21ff189 100644 (file)
@@ -104,3 +104,8 @@ resources:
       cpu: 200m
       memory: 500Mi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 75968b2..69de15c 100644 (file)
@@ -99,7 +99,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: {{ .Values.log.path }}
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/vfc/gvnfm-vnflcm/config/log.yml
             subPath: log.yml
@@ -115,18 +115,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -136,11 +125,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 9098b44..e4ae447 100644 (file)
@@ -104,3 +104,8 @@ resources:
       cpu: 200m
       memory: 500Mi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index f9a8ba7..0ee0b93 100644 (file)
@@ -99,7 +99,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: {{ .Values.log.path }}
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/vfc/gvnfm-vnfmgr/config/log.yml
             subPath: log.yml
@@ -115,18 +115,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -137,10 +126,6 @@ spec:
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
 
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index f8a5b28..cc2becc 100644 (file)
@@ -103,3 +103,8 @@ resources:
       cpu: 200m
       memory: 500Mi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 06258a0..a017815 100644 (file)
@@ -115,18 +115,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -136,11 +125,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 74e5b21..68d66a6 100644 (file)
@@ -104,3 +104,8 @@ resources:
       cpu: 200m
       memory: 500Mi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 8c24dd6..9dcba3b 100644 (file)
@@ -69,7 +69,7 @@ spec:
             mountPath: /etc/localtime
             readOnly: true
           - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
+            mountPath: {{ .Values.log.path }}
           - name: {{ include "common.fullname" . }}-logconfig
             mountPath: /opt/vfc/ztevnfmdriver/config/log.yml
             subPath: log.yml
@@ -85,18 +85,7 @@ spec:
         {{- end }}
 
         # side car containers
-        - name: {{ include "common.name" . }}-filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - name: {{ include "common.fullname" . }}-filebeat-conf
-            mountPath: /usr/share/filebeat/filebeat.yml
-            subPath: filebeat.yml
-          - name: {{ include "common.fullname" . }}-logs
-            mountPath: /var/log/onap
-          - name: {{ include "common.fullname" . }}-data-filebeat
-            mountPath: /usr/share/filebeat/data
-
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes:
         - name: {{ include "common.fullname" . }}-localtime
           hostPath:
@@ -106,11 +95,6 @@ spec:
         - name: {{ include "common.fullname" . }}-logconfig
           configMap:
             name : {{ include "common.fullname" . }}-logging-configmap
-
-        - name: {{ include "common.fullname" . }}-filebeat-conf
-          configMap:
-            name: {{ include "common.release" . }}-vfc-filebeat-configmap
-        - name: {{ include "common.fullname" . }}-data-filebeat
-          emptyDir: {}
+        {{ include "common.log.volumes" (dict "dot" . "configMapNamePrefix" (tpl .Values.logConfigMapNamePrefix . )) | nindent 8 }}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
index 643c3fb..c6db92a 100644 (file)
@@ -84,4 +84,9 @@ resources:
     requests:
       cpu: 100m
       memory: 500Mi
-  unlimited: {}
\ No newline at end of file
+  unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap
+logConfigMapNamePrefix: '{{ include "common.fullname" . }}'
index 88fda22..e890b8d 100644 (file)
 # limitations under the License.
 */}}
 
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: {{ include "common.release" . }}-vfc-filebeat-configmap
-  namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/logging/filebeat/*").AsConfig . | indent 2 }}
\ No newline at end of file
+{{ include "common.log.configMap" . }}
index 64bd029..01d9eef 100644 (file)
@@ -35,6 +35,7 @@ global:
     service: mariadb-galera
     internalPort: 3306
     nameOverride: mariadb-galera
+  centralizedLoggingEnabled: true
 
 #################################################################
 # Secrets metaconfig
@@ -69,13 +70,16 @@ mariadb-galera: &localMariadb
 
 vfc-generic-vnfm-driver:
   enabled: true
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 vfc-huawei-vnfm-driver:
   enabled: true
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 vfc-nslcm:
   enabled: true
   mariadb-galera: *localMariadb
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 vfc-redis:
   enabled: true
@@ -83,14 +87,17 @@ vfc-redis:
 vfc-vnflcm:
   enabled: true
   mariadb-galera: *localMariadb
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 vfc-vnfmgr:
   enabled: true
   mariadb-galera: *localMariadb
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 vfc-vnfres:
   enabled: true
   mariadb-galera: *localMariadb
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
 
 # sub-chart configuration
 vfc-workflow:
@@ -103,3 +110,4 @@ vfc-workflow-engine:
 
 vfc-zte-vnfm-driver:
   enabled: true
+  logConfigMapNamePrefix: '{{ include "common.release" . }}-vfc'
index 0ba466d..5c423e6 100644 (file)
@@ -27,18 +27,7 @@ metadata:
 data:
 {{ tpl (.Files.Glob "resources/config/log/vid/*").AsConfig . | indent 2 }}
 ---
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: {{ include "common.fullname" . }}-filebeat-configmap
-  namespace: {{ include "common.namespace" . }}
-  labels:
-    app: {{ include "common.name" . }}
-    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
-    release: {{ include "common.release" . }}
-    heritage: {{ .Release.Service }}
-data:
-{{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }}
+{{ include "common.log.configMap" . }}
 ---
 apiVersion: v1
 kind: ConfigMap
index 478b442..116a7cd 100644 (file)
@@ -136,7 +136,7 @@ spec:
           - mountPath: /etc/localtime
             name: localtime
             readOnly: true
-          - mountPath: /var/log/onap
+          - mountPath: "{{ .Values.log.path }}"
             name: vid-logs
           - mountPath: /tmp/logback.xml
             name: vid-logback
@@ -154,30 +154,16 @@ spec:
 {{ toYaml .Values.affinity | indent 10 }}
         {{- end }}
       # side car containers
-        - name: filebeat-onap
-          image: {{ include "repositoryGenerator.image.logging" . }}
-          imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
-          volumeMounts:
-          - mountPath: /usr/share/filebeat/filebeat.yml
-            name: filebeat-conf
-            subPath: filebeat.yml
-          - mountPath: /var/log/onap
-            name: vid-logs
-          - mountPath: /usr/share/filebeat/data
-            name: vid-data-filebeat
+        {{ include "common.log.sidecar" . | nindent 8 }}
       volumes: {{ include "common.certInitializer.volumes" . | nindent 8 }}
         - name: localtime
           hostPath:
             path: /etc/localtime
-        - name: filebeat-conf
-          configMap:
-            name: {{ include "common.fullname" . }}-filebeat-configmap
+        {{ include "common.log.volumes" . | nindent 8 }}
         - name: vid-cache
           emptyDir: {}
         - name: vid-logs
           emptyDir: {}
-        - name: vid-data-filebeat
-          emptyDir: {}
         - name: vid-logback
           configMap:
             name: {{ include "common.fullname" . }}-log-configmap
index 91132e2..aba010e 100644 (file)
@@ -25,6 +25,7 @@ global:
     service: mariadb-galera
     internalPort: 3306
     nameOverride: mariadb-galera
+  centralizedLoggingEnabled: true
 
 #################################################################
 # Secrets metaconfig
@@ -194,3 +195,7 @@ resources:
       cpu: 200m
       memory: 2Gi
   unlimited: {}
+
+# Log configuration
+log:
+  path: /var/log/onap