aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kubernetes/common/common/templates/_dmaapProvisioning.tpl186
-rw-r--r--kubernetes/common/repositoryGenerator/templates/_repository.tpl7
-rw-r--r--kubernetes/common/repositoryGenerator/values.yaml3
-rw-r--r--kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_configmap.tpl61
-rw-r--r--kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl7
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/Chart.yaml22
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/requirements.yaml33
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/certificates.yaml21
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/configmap.yaml19
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/deployment.yaml19
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/service.yaml19
-rw-r--r--kubernetes/dcaegen2-services/components/dcae-datafile-collector/values.yaml180
-rw-r--r--kubernetes/dcaegen2-services/requirements.yaml12
-rw-r--r--kubernetes/dcaegen2-services/values.yaml6
14 files changed, 587 insertions, 8 deletions
diff --git a/kubernetes/common/common/templates/_dmaapProvisioning.tpl b/kubernetes/common/common/templates/_dmaapProvisioning.tpl
new file mode 100644
index 0000000000..704bd06a49
--- /dev/null
+++ b/kubernetes/common/common/templates/_dmaapProvisioning.tpl
@@ -0,0 +1,186 @@
+{{/*
+################################################################################
+# Copyright (C) 2021 Nordix Foundation. #
+# #
+# 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. #
+################################################################################
+*/}}
+
+{{/*
+ This template generates a Kubernetes init containers common template to enable applications to provision
+ DMaaP topics (on Message Router) and feeds (on Data Router), with associated authorization (on AAF).
+ DMaap Bus Controller endpoints are used to provision:
+ - Authorized topic on MR, and to create and grant permission for publishers and subscribers.
+ - Feed on DR, with associated user authentication.
+
+ common.dmaap.provisioning.initContainer:
+ This template make use of Dmaap Bus Controller docker image to create resources on Dmaap Data Router
+ microservice, with the help of dbc-client.sh script it makes use of Bus Controller API to create Feed, Topics.
+ If the resource creation is successful via script response is logged back at particular location with
+ appropriate naming convention.
+
+ More details can be found at :
+ (https://wiki.onap.org/pages/viewpage.action?pageId=103417564)
+
+ The template directly references data in .Values, and indirectly (through its
+ use of templates from the ONAP "common" collection) references data in .Release.
+
+ Parameter for _dmaapProvisioning to be defined in values.yaml
+ # DataRouter Feed Configuration
+ drFeedConfig:
+ - feedName: bulk_pm_feed
+ owner: dcaecm
+ feedVersion: 0.0
+ asprClassification: unclassified
+ feedDescription: DFC Feed Creation
+
+ # DataRouter Publisher Configuration
+ drPubConfig:
+ - feedName: bulk_pm_feed
+ dcaeLocationName: loc00
+
+ # DataRouter Subscriber Configuration
+ drSubConfig:
+ - feedName: bulk_pm_feed
+ decompress: True
+ dcaeLocationName: loc00
+ privilegedSubscriber: True
+ deliveryURL: https://dcae-pm-mapper:8443/delivery
+
+ # MessageRouter Topic, Publisher Configuration
+ mrTopicsConfig:
+ - topicName: PERFORMANCE_MEASUREMENTS
+ topicDescription: Description about Topic
+ owner: dcaecm
+ tnxEnabled: false
+ clients:
+ - dcaeLocationName: san-francisco
+ clientRole: org.onap.dcae.pmPublisher
+ action:
+ - pub
+ - view
+
+ # ConfigMap Configuration for DR Feed, Dr_Publisher, Dr_Subscriber, MR Topics
+ volumes:
+ - name: feeds-config
+ path: /opt/app/config/feeds
+ - name: drpub-config
+ path: /opt/app/config/dr_pubs
+ - name: drsub-config
+ path: /opt/app/config/dr_subs
+ - name: topics-config
+ path: /opt/app/config/topics
+
+ In deployments/jobs/stateful include:
+ initContainers:
+ {{- include "common.dmaap.provisioning.initContainer" . | nindent XX }}
+ volumes:
+ {{- include "common.dmaap.provisioning._volumes" . | nindent XX -}}
+*/}}
+
+{{- define "common.dmaap.provisioning._volumeMounts" -}}
+{{- $dot := default . .dot -}}
+- mountPath: /opt/app/config/cache
+ name: dbc-response-cache
+{{- range $name, $volume := $dot.Values.volumes }}
+- name: {{ $volume.name }}
+ mountPath: {{ $volume.path }}
+{{- end }}
+{{- end -}}
+
+{{- define "common.dmaap.provisioning._volumes" -}}
+{{- $dot := default . .dot -}}
+- name: dbc-response-cache
+ emptyDir: {}
+{{- range $name, $volume := $dot.Values.volumes }}
+- name: {{ $volume.name }}
+ configMap:
+ defaultMode: 420
+ name: {{ include "common.fullname" $dot }}-{{ printf "%s" $volume.name }}
+{{- end }}
+{{- end -}}
+
+{{- define "common.dmaap.provisioning.initContainer" -}}
+{{- $dot := default . .dot -}}
+{{- $drFeedConfig := default $dot.Values.drFeedConfig .drFeedConfig -}}
+{{- $mrTopicsConfig := default $dot.Values.mrTopicsConfig .mrTopicsConfig -}}
+{{- if or $drFeedConfig $mrTopicsConfig -}}
+- name: {{ include "common.name" $dot }}-init-dmaap-provisioning
+ image: {{ include "repositoryGenerator.image.dbcClient" $dot }}
+ imagePullPolicy: {{ $dot.Values.global.pullPolicy | default $dot.Values.pullPolicy }}
+ env:
+ - name: RESP_CACHE
+ value: /opt/app/config/cache
+ - name: REQUESTID
+ value: "{{ include "common.name" $dot }}-dmaap-provisioning"
+ {{- range $cred := $dot.Values.credentials }}
+ - name: {{ $cred.name }}
+ {{- include "common.secret.envFromSecretFast" (dict "global" $dot "uid" $cred.uid "key" $cred.key) | nindent 4 }}
+ {{- end }}
+ volumeMounts:
+ {{- include "common.dmaap.provisioning._volumeMounts" $dot | trim | nindent 2 }}
+ resources: {{ include "common.resources" $dot | nindent 1 }}
+- name: {{ include "common.name" $dot }}-init-merge-config
+ image: {{ include "repositoryGenerator.image.envsubst" $dot }}
+ imagePullPolicy: {{ $dot.Values.global.pullPolicy | default $dot.Values.pullPolicy }}
+ command:
+ - /bin/sh
+ args:
+ - -c
+ - |
+ if [ -d /opt/app/config/cache ]; then
+ cd /opt/app/config/cache
+ for file in $(ls feed*); do
+ NUM=$(echo "$file" | sed 's/feedConfig-\([0-9]\+\)-resp.json/\1/')
+ export DR_LOG_URL_"$NUM"="$(grep -o '"logURL":"[^"]*' "$file" | cut -d '"' -f4)"
+ export DR_FILES_PUBLISHER_URL_"$NUM"="$(grep -o '"publishURL":"[^"]*' "$file" | cut -d '"' -f4)"
+ done
+ for file in $(ls drpub*); do
+ NUM=$(echo "$file" | sed 's/drpubConfig-\([0-9]\+\)-resp.json/\1/')
+ export DR_USERNAME_"$NUM"="$(grep -o '"username":"[^"]*' "$file" | cut -d '"' -f4)"
+ export DR_PASSWORD_"$NUM"="$(grep -o '"userpwd":"[^"]*' "$file" | cut -d '"' -f4)"
+ export DR_FILES_PUBLISHER_ID_"$NUM"="$(grep -o '"pubId":"[^"]*' "$file" | cut -d '"' -f4)"
+ done
+ for file in $(ls drsub*); do
+ NUM=$(echo "$file" | sed 's/drsubConfig-\([0-9]\+\)-resp.json/\1/')
+ export DR_FILES_SUBSCRIBER_ID_"$NUM"="$(grep -o '"subId":"[^"]*' "$file" | cut -d '"' -f4)"
+ done
+ for file in $(ls topics*); do
+ NUM=$(echo "$file" | sed 's/topicsConfig-\([0-9]\+\)-resp.json/\1/')
+ export MR_FILES_PUBLISHER_CLIENT_ID_"$NUM"="$(grep -o '"mrClientId":"[^"]*' "$file" | cut -d '"' -f4)"
+ done
+ else
+ echo "No Response logged for Dmaap BusController Http POST Request..!"
+ fi
+ cd /config-input && for PFILE in `ls -1`; do envsubst <${PFILE} >/config/${PFILE}; done
+ env:
+ {{- range $cred := $dot.Values.credentials }}
+ - name: {{ $cred.name }}
+ {{- include "common.secret.envFromSecretFast" (dict "global" $dot "uid" $cred.uid "key" $cred.key) | nindent 4 }}
+ {{- end }}
+ volumeMounts:
+ - mountPath: /opt/app/config/cache
+ name: dbc-response-cache
+ - mountPath: /config-input
+ name: app-config-input
+ - mountPath: /config
+ name: app-config
+ resources:
+ limits:
+ cpu: 200m
+ memory: 250Mi
+ requests:
+ cpu: 100m
+ memory: 200Mi
+{{- end -}}
+{{- end -}} \ No newline at end of file
diff --git a/kubernetes/common/repositoryGenerator/templates/_repository.tpl b/kubernetes/common/repositoryGenerator/templates/_repository.tpl
index 211cf1c599..1662985d0a 100644
--- a/kubernetes/common/repositoryGenerator/templates/_repository.tpl
+++ b/kubernetes/common/repositoryGenerator/templates/_repository.tpl
@@ -1,6 +1,7 @@
{{/*
# Copyright © 2017 Amdocs, Bell Canada
-# Copyright © 2021 AT&T
+# Copyright © 2021 AT&T
+# Modifications Copyright (C) 2021 Nordix Foundation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -132,6 +133,10 @@
{{- include "repositoryGenerator.image._helper" (merge (dict "image" "readinessImage") .) }}
{{- end -}}
+{{- define "repositoryGenerator.image.dbcClient" -}}
+ {{- include "repositoryGenerator.image._helper" (merge (dict "image" "dbcClientImage") .) }}
+{{- end -}}
+
{{/*
Resolve the image repository secret token.
The value for .Values.global.repositoryCred is used if provided:
diff --git a/kubernetes/common/repositoryGenerator/values.yaml b/kubernetes/common/repositoryGenerator/values.yaml
index 2a01112ce6..f4104538f7 100644
--- a/kubernetes/common/repositoryGenerator/values.yaml
+++ b/kubernetes/common/repositoryGenerator/values.yaml
@@ -1,5 +1,6 @@
# Copyright © 2020 Orange
# Copyright © 2021 Nokia, AT&T
+# Modifications Copyright (C) 2021 Nordix Foundation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -35,6 +36,7 @@ global:
postgresImage: crunchydata/crunchy-postgres:centos8-13.2-4.6.1
readinessImage: onap/oom/readiness:3.0.1
dcaePolicySyncImage: onap/org.onap.dcaegen2.deployments.dcae-services-policy-sync:1.0.1
+ dbcClientImage: onap/dmaap/dbc-client:2.0.7
# Default credentials
# they're optional. If the target repository doesn't need them, comment them
@@ -66,3 +68,4 @@ imageRepoMapping:
postgresImage: dockerHubRepository
readinessImage: repository
dcaePolicySyncImage: repository
+ dbcClientImage: repository
diff --git a/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_configmap.tpl b/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_configmap.tpl
index 1dff4d0f77..5313b0782a 100644
--- a/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_configmap.tpl
+++ b/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_configmap.tpl
@@ -2,6 +2,7 @@
# Copyright © 2017 Amdocs, Bell Canada
# Modifications Copyright © 2019 AT&T
# Copyright (c) 2021 J. F. Lucas. All rights reserved.
+# Copyright (c) 2021 Nordix Foundation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -63,4 +64,64 @@ data:
filebeat.yml: |-
{{ include "dcaegen2-services-common.filebeatConfiguration" . | indent 4 }}
{{- end }}
+
+{{- if .Values.drFeedConfig }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ include "common.fullname" . }}-feeds-config
+ namespace: {{ include "common.namespace" . }}
+ labels: {{ include "common.labels" . | nindent 6 }}
+data:
+ {{- range $i, $feed := .Values.drFeedConfig }}
+ feedConfig-{{$i}}.json: |-
+ {{ $feed | toJson | indent 2 }}
+ {{- end }}
+{{- end }}
+
+{{- if .Values.drPubConfig }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ include "common.fullname" . }}-drpub-config
+ namespace: {{ include "common.namespace" . }}
+ labels: {{ include "common.labels" . | nindent 6 }}
+data:
+ {{- range $i, $drpub := .Values.drPubConfig }}
+ drpubConfig-{{$i}}.json: |-
+ {{ $drpub | toJson | indent 2 }}
+ {{- end }}
+{{- end }}
+
+{{- if .Values.drSubConfig }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ include "common.fullname" . }}-drsub-config
+ namespace: {{ include "common.namespace" . }}
+ labels: {{ include "common.labels" . | nindent 6 }}
+data:
+ {{- range $i, $drsub := .Values.drSubConfig }}
+ drsubConfig-{{$i}}.json: |-
+ {{ $drsub | toJson | indent 2 }}
+ {{- end }}
+{{- end }}
+
+{{- if .Values.mrTopicsConfig }}
+---
+apiVersion: v1
+kind: ConfigMap
+metadata:
+ name: {{ include "common.fullname" . }}-topics-config
+ namespace: {{ include "common.namespace" . }}
+ labels: {{ include "common.labels" . | nindent 6 }}
+data:
+ {{- range $i, $topics := .Values.mrTopicsConfig }}
+ topicsConfig-{{$i}}.json: |-
+ {{ $topics | toJson | indent 2 }}
+ {{- end }}
+{{- end }}
{{- end }} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl b/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl
index ffff46fab5..7c9073a537 100644
--- a/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl
+++ b/kubernetes/dcaegen2-services/common/dcaegen2-services-common/templates/_deployment.tpl
@@ -4,6 +4,7 @@
# Copyright (c) 2021 J. F. Lucas. All rights reserved.
# Copyright (c) 2021 AT&T Intellectual Property. All rights reserved.
# Copyright (c) 2021 Nokia. All rights reserved.
+# Copyright (c) 2021 Nordix Foundation.
# ================================================================================
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -214,6 +215,7 @@ list of policyID or filter
{{- $certDir := default "" .Values.certDirectory . -}}
{{- $tlsServer := default "" .Values.tlsServer -}}
{{- $policy := default "" .Values.policies -}}
+{{- $drFeedConfig := default "" .Values.drFeedConfig -}}
apiVersion: apps/v1
kind: Deployment
@@ -225,6 +227,7 @@ spec:
metadata: {{- include "common.templateMetadata" . | nindent 6 }}
spec:
initContainers:
+ {{- if not $drFeedConfig }}
- command:
- sh
args:
@@ -247,8 +250,9 @@ spec:
image: {{ include "repositoryGenerator.image.envsubst" . }}
imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
name: {{ include "common.name" . }}-update-config
-
+ {{- end }}
{{ include "common.readinessCheck.waitFor" . | indent 6 | trim }}
+ {{- include "common.dmaap.provisioning.initContainer" . | nindent 6 }}
- name: init-consul
image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.consulLoaderImage }}
imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
@@ -444,6 +448,7 @@ spec:
- name: policy-shared
emptyDir: {}
{{- end }}
+ {{- include "common.dmaap.provisioning._volumes" . | nindent 6 -}}
{{- include "dcaegen2-services-common._externalVolumes" . | nindent 6 }}
imagePullSecrets:
- name: "{{ include "common.namespace" . }}-docker-registry-key"
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/Chart.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/Chart.yaml
new file mode 100644
index 0000000000..e7cde04abf
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/Chart.yaml
@@ -0,0 +1,22 @@
+# ================================ LICENSE_START =============================
+# ============================================================================
+# Copyright (C) 2021 Nordix Foundation.
+# ============================================================================
+# 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
+appVersion: "Honolulu"
+description: DCAE DataFile Collector Helm charts
+name: dcae-datafile-collector
+version: 8.0.0 \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/requirements.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/requirements.yaml
new file mode 100644
index 0000000000..9f1600ead3
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/requirements.yaml
@@ -0,0 +1,33 @@
+# ================================ LICENSE_START =============================
+# ============================================================================
+# Copyright (C) 2021 Nordix Foundation.
+# ============================================================================
+# 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: ~8.x-0
+ repository: '@local'
+ - name: readinessCheck
+ version: ~8.x-0
+ repository: '@local'
+ - name: repositoryGenerator
+ version: ~8.x-0
+ repository: '@local'
+ - name: certManagerCertificate
+ version: ~8.x-0
+ repository: '@local'
+ - name: dcaegen2-services-common
+ version: ~8.x-0
+ repository: '@local' \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/certificates.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/certificates.yaml
new file mode 100644
index 0000000000..78ae858cec
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/certificates.yaml
@@ -0,0 +1,21 @@
+{{/*
+################################################################################
+# Copyright (C) 2021 Nordix Foundation. #
+# #
+# Licensed under the Apache License, Version 2.0 (the "License"); #
+# you may not use this file except in compliance with the License. #
+# You may obtain a copy of the License at #
+# #
+# http://www.apache.org/licenses/LICENSE-2.0 #
+# #
+# Unless required by applicable law or agreed to in writing, software #
+# distributed under the License is distributed on an "AS IS" BASIS, #
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
+# See the License for the specific language governing permissions and #
+# limitations under the License. #
+################################################################################
+*/}}
+
+{{- if (include "dcaegen2-services-common.shouldUseCmpv2Certificates" .) -}}
+{{ include "certManagerCertificate.certificate" . }}
+{{ end }} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/configmap.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/configmap.yaml
new file mode 100644
index 0000000000..a0cb9a66bd
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/configmap.yaml
@@ -0,0 +1,19 @@
+{{/*
+################################################################################
+# Copyright (C) 2021 Nordix Foundation. #
+# #
+# 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 "dcaegen2-services-common.configMap" . }} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/deployment.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/deployment.yaml
new file mode 100644
index 0000000000..d992d5c19c
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/deployment.yaml
@@ -0,0 +1,19 @@
+{{/*
+################################################################################
+# Copyright (C) 2021 Nordix Foundation. #
+# #
+# 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 "dcaegen2-services-common.microserviceDeployment" . }} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/service.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/service.yaml
new file mode 100644
index 0000000000..2de4a8fe0a
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/templates/service.yaml
@@ -0,0 +1,19 @@
+{{/*
+################################################################################
+# Copyright (C) 2021 Nordix Foundation. #
+# #
+# 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.service" . }} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/components/dcae-datafile-collector/values.yaml b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/values.yaml
new file mode 100644
index 0000000000..4bffb98e23
--- /dev/null
+++ b/kubernetes/dcaegen2-services/components/dcae-datafile-collector/values.yaml
@@ -0,0 +1,180 @@
+# ================================ LICENSE_START ==========================
+# =========================================================================
+# Copyright (C) 2021 Nordix Foundation.
+# =========================================================================
+# 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 Configuration Defaults.
+#################################################################
+global:
+ nodePortPrefix: 302
+ nodePortPrefixExt: 304
+
+#################################################################
+# Filebeat Configuration Defaults.
+#################################################################
+filebeatConfig:
+ logstashServiceName: log-ls
+ logstashPort: 5044
+
+#################################################################
+# InitContainer Images.
+#################################################################
+tlsImage: onap/org.onap.dcaegen2.deployments.tls-init-container:2.1.0
+consulLoaderImage: onap/org.onap.dcaegen2.deployments.consul-loader-container:1.1.0
+certPostProcessorImage: onap/org.onap.oom.platform.cert-service.oom-certservice-post-processor:2.3.3
+
+#################################################################
+# Application Configuration Defaults.
+#################################################################
+# Application Image
+image: onap/org.onap.dcaegen2.collectors.datafile.datafile-app-server:1.5.5
+pullPolicy: Always
+
+# Log directory where logging sidecar should look for log files
+# if absent, no sidecar will be deployed
+logDirectory: /var/log/ONAP
+
+# Directory where TLS certs should be stored
+# if absent, no certs will be retrieved and stored
+certDirectory: /opt/app/datafile/etc/cert
+
+# TLS role -- set to true if microservice acts as server
+# If true, an init container will retrieve a server cert
+# and key from AAF and mount them in certDirectory.
+tlsServer: true
+
+# CMPv2 certificate
+# It is used only when:
+# - certDirectory is set
+# - global cmpv2Enabled flag is set to true
+# - flag useCmpv2Certificates is set to true
+# Disabled by default
+useCmpv2Certificates: false
+certificates:
+ - mountPath: /opt/app/datafile/etc/cert/external
+ commonName: dcae-datafile-collector
+ dnsNames:
+ - dcae-datafile-collector
+ - datafile-collector
+ - datafile
+ keystore:
+ outputType:
+ - p12
+ passwordSecretRef:
+ name: datafile-collector-cmpv2-keystore-password
+ key: password
+ create: true
+
+# Dependencies
+readinessCheck:
+ wait_for:
+ containers:
+ - dcae-config-binding-service
+ - aaf-cm
+ - dmaap-bc
+ - dmaap-provisioning-job
+
+# Probe Configuration
+readiness:
+ initialDelaySeconds: 10
+ periodSeconds: 15
+ timeoutSeconds: 1
+ path: /heartbeat
+ scheme: HTTP
+ port: 8100
+
+# Service Configuration
+service:
+ type: ClusterIP
+ name: datafile-collector
+ ports:
+ - name: https
+ port: 8443
+ plain_port: 8100
+ port_protocol: http
+
+# Initial Application Configuration
+applicationConfig:
+ dmaap.certificateConfig.keyCert: /opt/app/datafile/etc/cert/cert.p12
+ dmaap.certificateConfig.keyPasswordPath: /opt/app/datafile/etc/cert/p12.pass
+ dmaap.certificateConfig.trustedCa: /opt/app/datafile/etc/cert/trust.jks
+ dmaap.certificateConfig.trustedCaPasswordPath: /opt/app/datafile/etc/cert/trust.pass
+ dmaap.dmaapConsumerConfiguration.consumerGroup: OpenDcae-c12
+ dmaap.dmaapConsumerConfiguration.consumerId: C12
+ dmaap.dmaapConsumerConfiguration.timeoutMs: -1
+ dmaap.security.enableDmaapCertAuth: true
+ dmaap.security.keyStorePasswordPath: /opt/app/datafile/etc/cert/jks.pass
+ dmaap.security.keyStorePath: /opt/app/datafile/etc/cert/cert.jks
+ dmaap.security.trustStorePasswordPath: /opt/app/datafile/etc/cert/trust.pass
+ dmaap.security.trustStorePath: /opt/app/datafile/etc/cert/trust.jks
+ service_calls: []
+ sftp.security.strictHostKeyChecking: true
+ streams_publishes:
+ PM_MEAS_FILES:
+ dmaap_info:
+ publisher_id: ${DR_FILES_PUBLISHER_ID_0}
+ location: loc00
+ log_url: ${DR_LOG_URL_0}
+ publish_url: ${DR_FILES_PUBLISHER_URL_0}
+ username: ${DR_USERNAME_0}
+ password: ${DR_PASSWORD_0}
+ type: data_router
+ streams_subscribes:
+ dmaap_subscriber:
+ dmaap_info:
+ topic_url: "https://message-router:3905/events/unauthenticated.VES_NOTIFICATION_OUTPUT"
+ type: message_router
+
+# DataRouter Feed Configuration
+drFeedConfig:
+ - feedName: bulk_pm_feed
+ owner: dcaecm
+ feedVersion: 0.0
+ asprClassification: unclassified
+ feedDescription: DFC Feed Creation
+
+# DataRouter Publisher Configuration
+drPubConfig:
+ - feedName: bulk_pm_feed
+ dcaeLocationName: loc00
+
+# ConfigMap Configuration for Feed, Dr_Publisher
+volumes:
+ - name: feeds-config
+ path: /opt/app/config/feeds
+ - name: drpub-config
+ path: /opt/app/config/dr_pubs
+
+# Resource Limit Flavor -By Default Using Small
+flavor: small
+
+# Segregation for Different Environment (Small and Large)
+resources:
+ small:
+ limits:
+ cpu: 1
+ memory: 1Gi
+ requests:
+ cpu: 500m
+ memory: 768Mi
+ large:
+ limits:
+ cpu: 2
+ memory: 2Gi
+ requests:
+ cpu: 1
+ memory: 1Gi
+ unlimited: {} \ No newline at end of file
diff --git a/kubernetes/dcaegen2-services/requirements.yaml b/kubernetes/dcaegen2-services/requirements.yaml
index d246c16237..63e65ea5eb 100644
--- a/kubernetes/dcaegen2-services/requirements.yaml
+++ b/kubernetes/dcaegen2-services/requirements.yaml
@@ -18,6 +18,10 @@ dependencies:
- name: common
version: ~8.x-0
repository: '@local'
+ - name: dcae-datafile-collector
+ version: ~8.x-0
+ repository: '@local'
+ condition: dcae-datafile-collector.enabled
- name: dcae-heartbeat
version: ~8.x-0
repository: '@local'
@@ -30,14 +34,14 @@ dependencies:
version: ~8.x-0
repository: '@local'
condition: dcae-kpi-ms.enabled
- - name: dcae-pm-mapper
- version: ~8.x-0
- repository: '@local'
- condition: dcae-pm-mapper.enabled
- name: dcae-ms-healthcheck
version: ~8.x-0
repository: '@local'
condition: dcae-ms-healthcheck.enabled
+ - name: dcae-pm-mapper
+ version: ~8.x-0
+ repository: '@local'
+ condition: dcae-pm-mapper.enabled
- name: dcae-pmsh
version: ~8.x-0
repository: '@local'
diff --git a/kubernetes/dcaegen2-services/values.yaml b/kubernetes/dcaegen2-services/values.yaml
index f38b9034bc..7f971fac4d 100644
--- a/kubernetes/dcaegen2-services/values.yaml
+++ b/kubernetes/dcaegen2-services/values.yaml
@@ -16,16 +16,18 @@
# Control deployment of DCAE microservices at ONAP installation time
+dcae-datafile-collector:
+ enabled: false
dcae-heartbeat:
enabled: false
dcae-hv-ves-collector:
enabled: true
-dcae-pm-mapper:
- enabled: false
dcae-kpi-ms:
enabled: false
dcae-ms-healthcheck:
enabled: true
+dcae-pm-mapper:
+ enabled: false
dcae-pmsh:
enabled: false
dcae-prh: