aboutsummaryrefslogtreecommitdiffstats
path: root/kubernetes/holmes
diff options
context:
space:
mode:
authorAndreas Geissler <andreas-geissler@telekom.de>2024-08-13 09:59:22 +0200
committerAndreas Geissler <andreas-geissler@telekom.de>2024-08-13 13:22:12 +0200
commit8c66f85d7348b09de54b7479757878d96f1c1cd0 (patch)
treeb4d27de208bbc49ba82a33a2404cc525ca1a2059 /kubernetes/holmes
parent2ce0437988709fd8af46c8f922f1d22d312e49f9 (diff)
[COMMON] Cleanup charts
- archive charts, which are not maintained anymore - archive subcharts in SDNC, MSB, DCAEGEN2-SERVICES - Cleanup environment and override files Issue-ID: OOM-3309 Issue-ID: ONAPARC-805 Change-Id: If19a807fefa574ceb9b90ac1eb84d9642729323d Signed-off-by: Andreas Geissler <andreas-geissler@telekom.de>
Diffstat (limited to 'kubernetes/holmes')
-rw-r--r--kubernetes/holmes/.helmignore21
-rw-r--r--kubernetes/holmes/Chart.yaml43
-rw-r--r--kubernetes/holmes/Makefile58
-rw-r--r--kubernetes/holmes/components/Makefile58
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/.helmignore22
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/Chart.yaml35
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/resources/config/application.yaml18
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/resources/config/cfy.json19
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/resources/config/engine-d.yml72
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/resources/config/onap-holmes_engine-createobj.sql50
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/templates/configmap.yaml21
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/templates/deployment.yaml145
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/templates/secret.yaml17
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/templates/service.yaml20
-rw-r--r--kubernetes/holmes/components/holmes-engine-mgmt/values.yaml137
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/.helmignore22
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/Chart.yaml35
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/resources/config/application.yaml18
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/resources/config/onap-holmes_rulemgt-createobj.sql57
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/resources/config/rulemgt.yml66
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b.drl88
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/index.json6
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/templates/configmap.yaml28
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/templates/deployment.yaml140
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/templates/ingress.yaml17
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/templates/secret.yaml17
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/templates/service.yaml20
-rw-r--r--kubernetes/holmes/components/holmes-rule-mgmt/values.yaml149
-rw-r--r--kubernetes/holmes/templates/secrets.yaml17
-rw-r--r--kubernetes/holmes/values.yaml112
30 files changed, 0 insertions, 1528 deletions
diff --git a/kubernetes/holmes/.helmignore b/kubernetes/holmes/.helmignore
deleted file mode 100644
index f0c1319444..0000000000
--- a/kubernetes/holmes/.helmignore
+++ /dev/null
@@ -1,21 +0,0 @@
-# Patterns to ignore when building packages.
-# This supports shell glob matching, relative path matching, and
-# negation (prefixed with !). Only one pattern per line.
-.DS_Store
-# Common VCS dirs
-.git/
-.gitignore
-.bzr/
-.bzrignore
-.hg/
-.hgignore
-.svn/
-# Common backup files
-*.swp
-*.bak
-*.tmp
-*~
-# Various IDEs
-.project
-.idea/
-*.tmproj
diff --git a/kubernetes/holmes/Chart.yaml b/kubernetes/holmes/Chart.yaml
deleted file mode 100644
index 7a8a23a42f..0000000000
--- a/kubernetes/holmes/Chart.yaml
+++ /dev/null
@@ -1,43 +0,0 @@
-# Copyright © 2017 Amdocs, Bell Canada
-# Modifications Copyright © 2021 ZTE
-# Modifications Copyright © 2021 Orange
-# Modifications Copyright © 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.
-
-apiVersion: v2
-description: ONAP DCAE HOLMES
-name: holmes
-version: 13.0.0
-
-dependencies:
- - name: common
- version: ~13.x-0
- repository: '@local'
- - name: repositoryGenerator
- version: ~13.x-0
- repository: '@local'
- - name: postgres
- version: ~13.x-0
- repository: '@local'
- condition: global.postgres.localCluster
- - name: postgres-init
- version: ~13.x-0
- repository: '@local'
- condition: global.postgres.globalCluster
- - name: holmes-rule-mgmt
- version: ~13.x-0
- repository: 'file://components/holmes-rule-mgmt'
- - name: holmes-engine-mgmt
- version: ~13.x-0
- repository: 'file://components/holmes-engine-mgmt'
diff --git a/kubernetes/holmes/Makefile b/kubernetes/holmes/Makefile
deleted file mode 100644
index 08ed7cb9da..0000000000
--- a/kubernetes/holmes/Makefile
+++ /dev/null
@@ -1,58 +0,0 @@
-# Copyright © 2020 Samsung Electronics
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
-OUTPUT_DIR := $(ROOT_DIR)/../dist
-PACKAGE_DIR := $(OUTPUT_DIR)/packages
-SECRET_DIR := $(OUTPUT_DIR)/secrets
-
-EXCLUDES := dist resources templates charts docker
-HELM_BIN := helm
-ifneq ($(SKIP_LINT),TRUE)
- HELM_LINT_CMD := $(HELM_BIN) lint
-else
- HELM_LINT_CMD := echo "Skipping linting of"
-endif
-
-HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.))))
-
-.PHONY: $(EXCLUDES) $(HELM_CHARTS)
-
-all: $(HELM_CHARTS)
-
-$(HELM_CHARTS):
- @echo "\n[$@]"
- @make package-$@
-
-make-%:
- @if [ -f $*/Makefile ]; then make -C $*; fi
-
-dep-%: make-%
- @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) dep up $*; fi
-
-lint-%: dep-%
- @if [ -f $*/Chart.yaml ]; then $(HELM_LINT_CMD) $*; fi
-
-package-%: lint-%
- @mkdir -p $(PACKAGE_DIR)
- @if [ -f $*/Chart.yaml ]; then PACKAGE_NAME=$$($(HELM_BIN) package -d $(PACKAGE_DIR) $* | cut -d":" -f2) && $(HELM_BIN) cm-push -f $$PACKAGE_NAME local; fi
- @sleep 3
- #@$(HELM_BIN) repo index $(PACKAGE_DIR)
-
-clean:
- @rm -f */Chart.lock
- @rm -f *tgz */charts/*tgz
- @rm -rf $(PACKAGE_DIR)
-%:
- @:
diff --git a/kubernetes/holmes/components/Makefile b/kubernetes/holmes/components/Makefile
deleted file mode 100644
index 9544d70f33..0000000000
--- a/kubernetes/holmes/components/Makefile
+++ /dev/null
@@ -1,58 +0,0 @@
-# Copyright © 2020 Samsung Electronics
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
-OUTPUT_DIR := $(ROOT_DIR)/../../dist
-PACKAGE_DIR := $(OUTPUT_DIR)/packages
-SECRET_DIR := $(OUTPUT_DIR)/secrets
-
-EXCLUDES :=
-HELM_BIN := helm
-ifneq ($(SKIP_LINT),TRUE)
- HELM_LINT_CMD := $(HELM_BIN) lint
-else
- HELM_LINT_CMD := echo "Skipping linting of"
-endif
-
-HELM_CHARTS := $(filter-out $(EXCLUDES), $(sort $(patsubst %/.,%,$(wildcard */.))))
-
-.PHONY: $(EXCLUDES) $(HELM_CHARTS)
-
-all: $(HELM_CHARTS)
-
-$(HELM_CHARTS):
- @echo "\n[$@]"
- @make package-$@
-
-make-%:
- @if [ -f $*/Makefile ]; then make -C $*; fi
-
-dep-%: make-%
- @if [ -f $*/Chart.yaml ]; then $(HELM_BIN) dep up $*; fi
-
-lint-%: dep-%
- @if [ -f $*/Chart.yaml ]; then $(HELM_LINT_CMD) $*; fi
-
-package-%: lint-%
- @mkdir -p $(PACKAGE_DIR)
- @if [ -f $*/Chart.yaml ]; then PACKAGE_NAME=$$($(HELM_BIN) package -d $(PACKAGE_DIR) $* | cut -d":" -f2) && $(HELM_BIN) cm-push -f $$PACKAGE_NAME local; fi
- @sleep 3
- #@$(HELM_BIN) repo index $(PACKAGE_DIR)
-
-clean:
- @rm -f */Chart.lock
- @rm -f *tgz */charts/*tgz
- @rm -rf $(PACKAGE_DIR)
-%:
- @:
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/.helmignore b/kubernetes/holmes/components/holmes-engine-mgmt/.helmignore
deleted file mode 100644
index 50af031725..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/.helmignore
+++ /dev/null
@@ -1,22 +0,0 @@
-# Patterns to ignore when building packages.
-# This supports shell glob matching, relative path matching, and
-# negation (prefixed with !). Only one pattern per line.
-.DS_Store
-# Common VCS dirs
-.git/
-.gitignore
-.bzr/
-.bzrignore
-.hg/
-.hgignore
-.svn/
-# Common backup files
-*.swp
-*.bak
-*.tmp
-*~
-# Various IDEs
-.project
-.idea/
-*.tmproj
-.vscode/
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/Chart.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/Chart.yaml
deleted file mode 100644
index df7f2c0c72..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/Chart.yaml
+++ /dev/null
@@ -1,35 +0,0 @@
-# Modifications Copyright © 2021 ZTE
-# Modifications Copyright © 2021 Orange
-# Modifications Copyright © 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.
-
-apiVersion: v2
-appVersion: "2.0"
-description: Holmes Engine Management
-name: holmes-engine-mgmt
-version: 13.0.0
-
-dependencies:
- - name: common
- version: ~13.x-0
- repository: '@local'
- - name: repositoryGenerator
- version: ~13.x-0
- repository: '@local'
- - name: readinessCheck
- version: ~13.x-0
- repository: '@local'
- - name: serviceAccount
- version: ~13.x-0
- repository: '@local' \ No newline at end of file
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/application.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/application.yaml
deleted file mode 100644
index 34c4024059..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/application.yaml
+++ /dev/null
@@ -1,18 +0,0 @@
-server:
- port: 9102
- servlet:
- context-path: /api/holmes-engine-mgmt/v1
-
-logging:
- config: classpath:logback-spring.xml
-
-spring:
- application:
- name: Holmes Engine Management
- datasource:
- dirver-class-name: org.postgresql.Driver
- url: jdbc:postgresql://${URL_JDBC}:${DB_PORT}/${DB_NAME}
- username: ${JDBC_USERNAME}
- password: ${JDBC_PASSWORD}
- mvc:
- throw-exception-if-no-handler-found: true \ No newline at end of file
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/cfy.json b/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/cfy.json
deleted file mode 100644
index dfa58b098f..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/cfy.json
+++ /dev/null
@@ -1,19 +0,0 @@
-{
- "services_calls": {},
- "streams_publishes": {
- "dcae_cl_out": {
- "dmaap_info": {
- "topic_url": "http://message-router.onap:3904/events/unauthenticated.DCAE_CL_OUTPUT"
- },
- "type": "message_router"
- }
- },
- "streams_subscribes": {
- "ves_fault": {
- "dmaap_info": {
- "topic_url": "http://message-router.onap:3904/events/unauthenticated.SEC_FAULT_OUTPUT"
- },
- "type": "message_router"
- }
- }
-}
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/engine-d.yml b/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/engine-d.yml
deleted file mode 100644
index 9a16390856..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/engine-d.yml
+++ /dev/null
@@ -1,72 +0,0 @@
-#
-# Copyright 2017 ZTE Corporation.
-#
-# 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.
-#
-server:
- type: simple
- rootPath: '/api/holmes-engine-mgmt/v1/*'
- applicationContextPath: /
- adminContextPath: /admin
- connector:
- type: http
- port: 9102
- validateCerts: false
- validatePeers: false
-
-
-# Logging settings.
-logging:
-
- # The default level of all loggers. Can be OFF, ERROR, WARN, INFO, DEBUG, TRACE, or ALL.
- level: INFO
-
- # Logger-specific levels.
- loggers:
-
- # Sets the level for 'com.example.app' to DEBUG.
- org.onap.holmes.engine: ALL
-
- appenders:
- - type: console
- threshold: INFO
- timeZone: UTC
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- - type: file
- threshold: ERROR
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- currentLogFilename: /var/log/ONAP/holmes/engine-d-error.log
- archivedLogFilenamePattern: /var/log/ONAP/holmes/zip/engine-d-error-%d{yyyy-MM-dd}.log.gz
- archivedFileCount: 7
- - type: file
- threshold: INFO
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- currentLogFilename: /var/log/ONAP/holmes/engine-d-debug.log
- archivedLogFilenamePattern: /var/log/ONAP/holmes/zip/engine-d-debug-%d{yyyy-MM-dd}.log.gz
- archivedFileCount: 7
-
-
-database:
- driverClass: org.postgresql.Driver
- user: ${JDBC_USERNAME}
- password: ${JDBC_PASSWORD}
- url: jdbc:postgresql://${URL_JDBC}:${DB_PORT}/${DB_NAME}
- properties:
- charSet: UTF-8
- maxWaitForConnection: 1s
- validationQuery: "/* MyService Health Check */ SELECT 1"
- minSize: 8
- maxSize: 100
- checkConnectionWhileIdle: false
- evictionInterval: 10s
- minIdleTime: 1s
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/onap-holmes_engine-createobj.sql b/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/onap-holmes_engine-createobj.sql
deleted file mode 100644
index e5eecb1a5a..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/resources/config/onap-holmes_engine-createobj.sql
+++ /dev/null
@@ -1,50 +0,0 @@
---
--- Copyright 2017 ZTE Corporation.
---
--- 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.
---
-\c postgres
-
-/******************CREATE NEW DATABASE AND USER***************************/
-CREATE DATABASE ${DB_NAME};
-
-CREATE ROLE ${JDBC_USERNAME} with PASSWORD '${JDBC_PASSWORD}' LOGIN;
-
-\encoding UTF8;
-
-/******************CREATE NEW TABLE***************************/
-\c ${DB_NAME};
-
-CREATE TABLE IF NOT EXISTS ALARM_INFO (
- EVENTID VARCHAR(150) NOT NULL,
- EVENTNAME VARCHAR(150) NOT NULL,
- ALARMISCLEARED SMALLINT NOT NULL,
- ROOTFLAG SMALLINT NOT NULL,
- STARTEPOCHMICROSEC BIGINT NOT NULL,
- LASTEPOCHMICROSEC BIGINT NOT NULL,
- SOURCEID VARCHAR(150) NOT NULL,
- SOURCENAME VARCHAR(150) NOT NULL,
- SEQUENCE SMALLINT NOT NULL,
- PRIMARY KEY (EVENTID, SEQUENCE, SOURCENAME)
-);
-
-CREATE TABLE IF NOT EXISTS ENGINE_ENTITY (
- ID VARCHAR(150) NOT NULL,
- IP VARCHAR(128) NOT NULL,
- PORT SMALLINT NOT NULL,
- LASTMODIFIED BIGINT NOT NULL,
- PRIMARY KEY (ID)
-);
-
-GRANT ALL PRIVILEGES ON ALARM_INFO TO ${JDBC_USERNAME};
-GRANT ALL PRIVILEGES ON ENGINE_ENTITY TO ${JDBC_USERNAME};
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/templates/configmap.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/templates/configmap.yaml
deleted file mode 100644
index 76b339faea..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/templates/configmap.yaml
+++ /dev/null
@@ -1,21 +0,0 @@
-{{/*
-# Copyright © 2017 Amdocs, Bell Canada
-# Modifications Copyright © 2019 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.
-*/}}
-
-apiVersion: v1
-kind: ConfigMap
-metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
-data: {{ tpl (.Files.Glob "resources/config/*").AsConfig . | nindent 2 }}
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/templates/deployment.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/templates/deployment.yaml
deleted file mode 100644
index 641f032ce4..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/templates/deployment.yaml
+++ /dev/null
@@ -1,145 +0,0 @@
-{{/*
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2021 ZTE 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=========================================================
-*/}}
-
-apiVersion: apps/v1
-kind: Deployment
-metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
-{{- $sum := "" }}
-{{- range $path, $bytes := .Files.Glob "resources/config/*.json"}}
-{{- $sum = $.Files.Get $path | sha256sum | print $sum }}
-{{- end }}
- annotations:
- checksum/config: {{ $sum | sha256sum }}
-
-spec:
- replicas: 1
- selector: {{- include "common.selectors" . | nindent 4 }}
- template:
- metadata: {{- include "common.templateMetadata" . | nindent 6 }}
- spec:
- initContainers:
- {{- if .Values.global.postgres.localCluster }}
- {{ include "common.readinessCheck.waitFor" (dict "dot" . "wait_for" .Values.readinessCheck.wait_for_local ) | indent 6 | trim }}
- {{ else }}
- {{ include "common.readinessCheck.waitFor" (dict "dot" . "wait_for" .Values.readinessCheck.wait_for_global ) | indent 6 | trim }}
- {{- end }}
- - name: {{ include "common.name" . }}-env-config
- image: {{ include "repositoryGenerator.image.envsubst" . }}
- imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- command:
- - sh
- args:
- - -c
- - "cd /hemconfig && for PFILE in `find . -type f -not -name '*.json'`; do envsubst < ${PFILE} > /config/${PFILE##*/}; done"
- env:
- - name: JDBC_USERNAME
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "login") | indent 10 }}
- - name: JDBC_PASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: DB_NAME
- value: {{ .Values.config.pgConfig.dbName }}
- - name: URL_JDBC
- value: {{ .Values.config.pgConfig.dbHost }}
- - name: DB_PORT
- value: "{{ .Values.config.pgConfig.dbPort }}"
- - name: AAI_ADDR
- value: aai
- - name: AAI_PORT
- value: "{{ .Values.config.aai.aaiPort }}"
- - name: AAI_USERNAME
- value: {{ .Values.config.aai.username }}
- - name: AAI_PASSWORD
- value: {{ .Values.config.aai.password }}
- - name: NAMESPACE
- value: {{ include "common.namespace" . }}
- volumeMounts:
- - mountPath: /hemconfig
- name: {{ include "common.fullname" . }}-config
- - mountPath: /config
- name: {{ include "common.fullname" . }}-env-config
- containers:
- - name: {{ include "common.name" . }}
- image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
- imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- resources: {{ include "common.resources" . | nindent 10 }}
- ports: {{ include "common.containerPorts" . | nindent 10 }}
- volumeMounts:
- - name: {{ include "common.fullname" . }}-env-config
- mountPath: /opt/hemconfig
- - name: {{ include "common.fullname" . }}-config
- mountPath: /opt/hemtopics
- # disable liveness probe when breakpoints set in debugger
- # so K8s doesn't restart unresponsive container
- {{- if eq .Values.liveness.enabled true }}
- livenessProbe:
- httpGet:
- path: {{ .Values.liveness.path }}
- port: {{ .Values.liveness.port }}
- scheme: {{ .Values.liveness.scheme }}
- initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
- periodSeconds: {{ .Values.liveness.periodSeconds }}
- {{- end }}
- readinessProbe:
- httpGet:
- path: {{ .Values.readiness.path }}
- port: {{ .Values.readiness.port }}
- scheme: {{ .Values.readiness.scheme }}
- initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
- periodSeconds: {{ .Values.readiness.periodSeconds }}
- failureThreshold: 1
- successThreshold: 1
- timeoutSeconds: 1
- env:
- - name: CONSUL_HOST
- value: consul-server.{{ include "common.namespace" . }}
- - name: CONFIG_BINDING_SERVICE
- value: config-binding-service
- - name: MSB_IAG_SERVICE_PROTOCOL
- value: {{ .Values.global.msbProtocol }}
- - name: MSB_IAG_SERVICE_HOST
- value: {{ .Values.global.msbServiceName }}.{{ include "common.namespace" . }}
- - name: MSB_IAG_SERVICE_PORT
- value: {{ .Values.global.msbPort | quote }}
- - name: POD_IP
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: status.podIP
- - name: PGPASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: JDBC_USERNAME
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "login") | indent 10 }}
- - name: JDBC_PASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: DB_NAME
- value: {{ .Values.config.pgConfig.dbName }}
- - name: URL_JDBC
- value: {{ .Values.config.pgConfig.dbHost }}
- - name: DB_PORT
- value: "{{ .Values.config.pgConfig.dbPort }}"
- serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
- volumes:
- - name: {{ include "common.fullname" . }}-config
- configMap:
- defaultMode: 422
- name: {{ include "common.fullname" . }}
- - name: {{ include "common.fullname" . }}-env-config
- emptyDir:
- medium: Memory
- {{- include "common.imagePullSecrets" . | nindent 6 }}
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/templates/secret.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/templates/secret.yaml
deleted file mode 100644
index 34932b713d..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/templates/secret.yaml
+++ /dev/null
@@ -1,17 +0,0 @@
-{{/*
-# Copyright © 2020 Samsung Electronics
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-*/}}
-
-{{ include "common.secretFast" . }}
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/templates/service.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/templates/service.yaml
deleted file mode 100644
index 70abf763e0..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/templates/service.yaml
+++ /dev/null
@@ -1,20 +0,0 @@
-{{/*
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2019 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.service" . }}
diff --git a/kubernetes/holmes/components/holmes-engine-mgmt/values.yaml b/kubernetes/holmes/components/holmes-engine-mgmt/values.yaml
deleted file mode 100644
index bd06bcd1ee..0000000000
--- a/kubernetes/holmes/components/holmes-engine-mgmt/values.yaml
+++ /dev/null
@@ -1,137 +0,0 @@
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2021 ZTE Corporation 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=========================================================
-
-#################################################################
-# Global configuration defaults.
-#################################################################
-global:
- nodePortPrefixExt: 302
- msbProtocol: http
- msbServiceName: msb-iag
- msbPort: 80
- postgres:
- localCluster: false
-
-#################################################################
-# Application configuration defaults.
-#################################################################
-# application image
-image: onap/holmes/engine-management:12.0.1
-consulLoaderImage: onap/org.onap.dcaegen2.deployments.consul-loader-container:1.0.0
-
-#################################################################
-# Secrets metaconfig
-#################################################################
-secrets:
-- uid: pg-user-creds
- type: basicAuth
- externalSecret: '{{ tpl (default "" .Values.config.pgConfig.dbUserCredsExternalSecret) . }}'
- login: '{{ .Values.config.pgConfig.dbUser }}'
- password: '{{ .Values.config.pgConfig.dbUserPassword }}'
-
-# application configuration
-config:
- logstashServiceName: log-ls
- logstashPort: 5044
- # Addresses of other ONAP entities
- address:
- consul:
- host: consul-server
- port: 8500
- pgConfig:
- dbName: defaultName
- dbHost: defaultHost
- dbPort: 1234
- dbUser: admin
- dbUserPassword: admin
- # dbUserCredsExternalSecret
- msb:
- serviceName: msb-iag
- port: 80
- aai:
- aaiPort: 80
- username: AAI
- password: AAI
-
-service:
- type: ClusterIP
- name: holmes-engine-mgmt
- ports:
- - name: http-rest
- port: &svc_port 9102
- annotations:
- msb.onap.org/service-info: |
- {{ if .Values.global.msbEnabled -}}[
- {
- "serviceName": "holmes-engine-mgmt",
- "version": "v1",
- "url": "/api/holmes-engine-mgmt/v1",
- "path":"/api/holmes-engine-mgmt/v1",
- "protocol": "REST",
- "visualRange":"0|1",
- "port": "9102",
- "enable_ssl": false
- }
- ]{{ end }}
-
-# probe configuration parameters
-liveness:
- initialDelaySeconds: 10
- periodSeconds: 10
- path: /api/holmes-engine-mgmt/v1/healthcheck
- scheme: HTTP
- port: *svc_port
- enabled: true
-
-readiness:
- initialDelaySeconds: 30
- periodSeconds: 30
- path: /api/holmes-engine-mgmt/v1/healthcheck
- scheme: HTTP
- port: *svc_port
-
-# Segregation for Different environment (Small and Large)
-resources:
- small:
- limits:
- cpu: "1"
- memory: "1Gi"
- requests:
- cpu: "0.5"
- memory: "1Gi"
- large:
- limits:
- cpu: "2"
- memory: "2Gi"
- requests:
- cpu: "1"
- memory: "2Gi"
- unlimited: {}
-
-readinessCheck:
- wait_for_global:
- jobs:
- - '{{ include "common.release" . }}-holmes-postgres-init-config-job'
- wait_for_local:
- services:
- - '{{ .Values.global.postgres.service.name2 }}'
-
-#Pods Service Account
-serviceAccount:
- nameOverride: holmes-engine-mgmt
- roles:
- - read
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/.helmignore b/kubernetes/holmes/components/holmes-rule-mgmt/.helmignore
deleted file mode 100644
index 50af031725..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/.helmignore
+++ /dev/null
@@ -1,22 +0,0 @@
-# Patterns to ignore when building packages.
-# This supports shell glob matching, relative path matching, and
-# negation (prefixed with !). Only one pattern per line.
-.DS_Store
-# Common VCS dirs
-.git/
-.gitignore
-.bzr/
-.bzrignore
-.hg/
-.hgignore
-.svn/
-# Common backup files
-*.swp
-*.bak
-*.tmp
-*~
-# Various IDEs
-.project
-.idea/
-*.tmproj
-.vscode/
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/Chart.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/Chart.yaml
deleted file mode 100644
index 4263913b25..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/Chart.yaml
+++ /dev/null
@@ -1,35 +0,0 @@
-# Modifications Copyright © 2021 ZTE
-# Modifications Copyright © 2021 Orange
-# Modifications Copyright © 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.
-
-apiVersion: v2
-appVersion: "2.0"
-description: Holmes Rule Management
-name: holmes-rule-mgmt
-version: 13.0.0
-
-dependencies:
- - name: common
- version: ~13.x-0
- repository: '@local'
- - name: repositoryGenerator
- version: ~13.x-0
- repository: '@local'
- - name: readinessCheck
- version: ~13.x-0
- repository: '@local'
- - name: serviceAccount
- version: ~13.x-0
- repository: '@local'
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/application.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/application.yaml
deleted file mode 100644
index 2ff0fa6d52..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/application.yaml
+++ /dev/null
@@ -1,18 +0,0 @@
-server:
- port: 9101
- servlet:
- context-path: /api/holmes-rule-mgmt/v1
-
-logging:
- config: classpath:logback-spring.xml
-
-spring:
- application:
- name: Holmes Rule Management
- datasource:
- dirver-class-name: org.postgresql.Driver
- url: jdbc:postgresql://${URL_JDBC}:${DB_PORT}/${DB_NAME}
- username: ${JDBC_USERNAME}
- password: ${JDBC_PASSWORD}
- mvc:
- throw-exception-if-no-handler-found: true \ No newline at end of file
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/onap-holmes_rulemgt-createobj.sql b/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/onap-holmes_rulemgt-createobj.sql
deleted file mode 100644
index 0464a5f8fd..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/onap-holmes_rulemgt-createobj.sql
+++ /dev/null
@@ -1,57 +0,0 @@
---
--- Copyright 2017 ZTE Corporation.
---
--- 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.
---
-\c postgres
-
-/******************CREATE NEW DATABASE AND USER***************************/
-CREATE DATABASE ${DB_NAME};
-
-CREATE ROLE ${JDBC_USERNAME} with PASSWORD '${JDBC_PASSWORD}' LOGIN;
-
-\encoding UTF8;
-
-/******************DELETE OLD TABLE AND CREATE NEW***************************/
-\c ${DB_NAME};
-
-CREATE TABLE IF NOT EXISTS APLUS_RULE (
- RID VARCHAR(30) NOT NULL,
- NAME VARCHAR(150) NOT NULL,
- CTRLLOOP VARCHAR(150) NOT NULL,
- DESCRIPTION VARCHAR(4000) NULL,
- ENABLE SMALLINT NOT NULL,
- TEMPLATEID BIGINT NOT NULL,
- ENGINEID VARCHAR(20) NOT NULL,
- ENGINETYPE VARCHAR(20) NOT NULL,
- CREATOR VARCHAR(20) NOT NULL,
- CREATETIME TIMESTAMP NOT NULL,
- UPDATOR VARCHAR(20) NULL,
- UPDATETIME TIMESTAMP NULL,
- PARAMS VARCHAR(4000) NULL,
- CONTENT VARCHAR(20000) NOT NULL,
- VENDOR VARCHAR(100) NOT NULL,
- ENGINEINSTANCE VARCHAR(100) NOT NULL,
- PACKAGE VARCHAR(255) NULL,
- PRIMARY KEY (RID),
- UNIQUE (NAME)
-);
-
-CREATE INDEX IDX_APLUS_RULE_NAME ON APLUS_RULE (NAME);
-CREATE INDEX IDX_APLUS_RULE_CTRLLOOP ON APLUS_RULE (CTRLLOOP);
-CREATE INDEX IDX_APLUS_RULE_ENABLE ON APLUS_RULE (ENABLE);
-CREATE INDEX IDX_APLUS_RULE_TEMPLATEID ON APLUS_RULE (TEMPLATEID);
-CREATE INDEX IDX_APLUS_RULE_ENGINEID ON APLUS_RULE (ENGINEID);
-CREATE INDEX IDX_APLUS_RULE_ENGINETYPE ON APLUS_RULE (ENGINETYPE);
-
-GRANT ALL PRIVILEGES ON APLUS_RULE TO ${JDBC_USERNAME};
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/rulemgt.yml b/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/rulemgt.yml
deleted file mode 100644
index 3b7218855a..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/resources/config/rulemgt.yml
+++ /dev/null
@@ -1,66 +0,0 @@
-apidescription: ZTE Holmes rule Management rest API
-
-# use the simple server factory if you only want to run on a single port
-#server:
-# type: simple
-# connector:
-# type: http
-# port: 12003
-
-server:
- type: simple
- rootPath: '/api/holmes-rule-mgmt/v1/*'
- applicationContextPath: /
- adminContextPath: /admin
- connector:
- type: http
- port: 9101
- validateCerts: false
- validatePeers: false
-
-# Logging settings.
-logging:
-
- # The default level of all loggers. Can be OFF, ERROR, WARN, INFO, DEBUG, TRACE, or ALL.
- level: INFO
-
- # Logger-specific levels.
- loggers:
-
- # Sets the level for 'com.example.app' to DEBUG.
- org.onap.holmes.rulemgt: ALL
-
- appenders:
- - type: console
- threshold: INFO
- timeZone: UTC
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- - type: file
- threshold: ERROR
- #logFormat: "%nopexception%logger\n|%date{yyyy-MM-dd'T'HH:mm:ss.SSSXXX,UTC}\n|%level\n|%message\n|%X{InvocationID}\n|%rootException\n|%marker\n|%thread\n|%n \r\n"
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- currentLogFilename: /var/log/ONAP/holmes/rulemgt-relation-error.log
- archivedLogFilenamePattern: /var/log/ONAP/holmes/zip/rulemgt-relation-error-%d{yyyy-MM-dd}.log.gz
- archivedFileCount: 7
- - type: file
- threshold: INFO
- logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] invocationID:{InvocationID} - %m%n"
- currentLogFilename: /var/log/ONAP/holmes/rulemgt-relation-debug.log
- archivedLogFilenamePattern: /var/log/ONAP/holmes/zip/rulemgt-relation-debug-%d{yyyy-MM-dd}.log.gz
- archivedFileCount: 7
-
-#database
-database:
- driverClass: org.postgresql.Driver
- user: ${JDBC_USERNAME}
- password: ${JDBC_PASSWORD}
- url: jdbc:postgresql://${URL_JDBC}:${DB_PORT}/${DB_NAME}
- properties:
- charSet: UTF-8
- maxWaitForConnection: 1s
- validationQuery: "/* MyService Health Check */ SELECT 1"
- minSize: 8
- maxSize: 100
- checkConnectionWhileIdle: false
- evictionInterval: 10s
- minIdleTime: 1s
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b.drl b/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b.drl
deleted file mode 100644
index 814aeedf03..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b.drl
+++ /dev/null
@@ -1,88 +0,0 @@
-package org.onap.holmes.droolsRule;
-
-import org.onap.holmes.common.dmaap.DmaapService;
-import org.onap.holmes.common.api.stat.VesAlarm;
-import org.onap.holmes.common.aai.CorrelationUtil;
-import org.onap.holmes.common.dmaap.entity.PolicyMsg;
-import org.onap.holmes.common.utils.SpringContextUtil;
-import org.onap.holmes.common.utils.DroolsLog;
-
-rule "Relation_analysis_Rule"
-salience 200
-no-loop true
- when
- $root : VesAlarm(alarmIsCleared == 0,
- $sourceId: sourceId, sourceId != null && !sourceId.equals(""),
- $sourceName: sourceName, sourceName != null && !sourceName.equals(""),
- $startEpochMicrosec: startEpochMicrosec,
- eventName in ("Fault_MultiCloud_VMFailure"),
- $eventId: eventId)
- $child : VesAlarm( eventId != $eventId, parentId == null,
- CorrelationUtil.getInstance().isTopologicallyRelated(sourceId, $sourceId, $sourceName),
- eventName in ("Fault_MME_eNodeB out of service alarm"),
- startEpochMicrosec < $startEpochMicrosec + 60000 && startEpochMicrosec > $startEpochMicrosec - 60000)
- then
- DroolsLog.printInfo("===========================================================");
- DroolsLog.printInfo("Relation_analysis_Rule: rootId=" + $root.getEventId() + ", childId=" + $child.getEventId());
- $child.setParentId($root.getEventId());
- update($child);
-end
-
-rule "root_has_child_handle_Rule"
-salience 150
-no-loop true
- when
- $root : VesAlarm(alarmIsCleared == 0, rootFlag == 0, $eventId: eventId)
- $child : VesAlarm(eventId != $eventId, parentId == $eventId)
- then
- DroolsLog.printInfo("===========================================================");
- DroolsLog.printInfo("root_has_child_handle_Rule: rootId=" + $root.getEventId() + ", childId=" + $child.getEventId());
- DmaapService dmaapService = SpringContextUtil.getBean(DmaapService.class);
- PolicyMsg policyMsg = dmaapService.getPolicyMsg($root, $child, "org.onap.holmes.droolsRule");
- dmaapService.publishPolicyMsg(policyMsg, "dcae_cl_out");
- $root.setRootFlag(1);
- update($root);
-end
-
-rule "root_no_child_handle_Rule"
-salience 100
-no-loop true
- when
- $root : VesAlarm(alarmIsCleared == 0, rootFlag == 0,
- sourceId != null && !sourceId.equals(""),
- sourceName != null && !sourceName.equals(""),
- eventName in ("Fault_MultiCloud_VMFailure"))
- then
- DroolsLog.printInfo("===========================================================");
- DroolsLog.printInfo("root_no_child_handle_Rule: rootId=" + $root.getEventId());
- DmaapService dmaapService = SpringContextUtil.getBean(DmaapService.class);
- PolicyMsg policyMsg = dmaapService.getPolicyMsg($root, null, "org.onap.holmes.droolsRule");
- dmaapService.publishPolicyMsg(policyMsg, "dcae_cl_out");
- $root.setRootFlag(1);
- update($root);
-end
-
-rule "root_cleared_handle_Rule"
-salience 100
-no-loop true
- when
- $root : VesAlarm(alarmIsCleared == 1, rootFlag == 1)
- then
- DroolsLog.printInfo("===========================================================");
- DroolsLog.printInfo("root_cleared_handle_Rule: rootId=" + $root.getEventId());
- DmaapService dmaapService = SpringContextUtil.getBean(DmaapService.class);
- PolicyMsg policyMsg = dmaapService.getPolicyMsg($root, null, "org.onap.holmes.droolsRule");
- dmaapService.publishPolicyMsg(policyMsg, "dcae_cl_out");
- retract($root);
-end
-
-rule "child_handle_Rule"
-salience 100
-no-loop true
- when
- $child : VesAlarm(alarmIsCleared == 1, rootFlag == 0)
- then
- DroolsLog.printInfo("===========================================================");
- DroolsLog.printInfo("child_handle_Rule: childId=" + $child.getEventId());
- retract($child);
-end \ No newline at end of file
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/index.json b/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/index.json
deleted file mode 100644
index 70f9dd09db..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/resources/rules/index.json
+++ /dev/null
@@ -1,6 +0,0 @@
-[
- {
- "closedControlLoopName": "ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b",
- "file": "ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b.drl"
- }
-]
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/templates/configmap.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/templates/configmap.yaml
deleted file mode 100644
index 3d54264723..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/templates/configmap.yaml
+++ /dev/null
@@ -1,28 +0,0 @@
-{{/*
-# Copyright © 2017 Amdocs, Bell Canada
-# Modifications Copyright © 2019 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.
-*/}}
-
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: {{ include "common.fullname" . }}-general-config
-data: {{ tpl (.Files.Glob "resources/config/*").AsConfig . | nindent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: {{ include "common.fullname" . }}-rule-config
-data: {{ tpl (.Files.Glob "resources/rules/*").AsConfig . | nindent 2 }}
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/templates/deployment.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/templates/deployment.yaml
deleted file mode 100644
index e71187c557..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/templates/deployment.yaml
+++ /dev/null
@@ -1,140 +0,0 @@
-{{/*
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2021 ZTE 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=========================================================
-*/}}
-
-apiVersion: apps/v1
-kind: Deployment
-metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
-{{- $sum := "" }}
-{{- range $path, $bytes := .Files.Glob "resources/rules/*"}}
-{{- $sum = $.Files.Get $path | sha256sum | print $sum }}
-{{- end }}
- annotations:
- checksum/rules: {{ $sum | sha256sum }}
-spec:
- replicas: 1
- selector: {{- include "common.selectors" . | nindent 4 }}
- template:
- metadata: {{- include "common.templateMetadata" . | nindent 6 }}
- spec:
- initContainers:
- {{- if .Values.global.postgres.localCluster }}
- {{ include "common.readinessCheck.waitFor" (dict "dot" . "wait_for" .Values.readinessCheck.wait_for_local ) | indent 6 | trim }}
- {{ else }}
- {{ include "common.readinessCheck.waitFor" (dict "dot" . "wait_for" .Values.readinessCheck.wait_for_global ) | indent 6 | trim }}
- {{- end }}
- - name: {{ include "common.name" . }}-env-config
- image: {{ include "repositoryGenerator.image.envsubst" . }}
- imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- command:
- - sh
- args:
- - -c
- - "cd /hrmconfig && for PFILE in `find . -type f -not -name '*.json'`; do envsubst < ${PFILE} > /config/${PFILE##*/}; done"
- env:
- - name: JDBC_USERNAME
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "login") | indent 10 }}
- - name: JDBC_PASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: DB_NAME
- value: {{ .Values.config.pgConfig.dbName }}
- - name: URL_JDBC
- value: {{ .Values.config.pgConfig.dbHost }}
- - name: DB_PORT
- value: "{{ .Values.config.pgConfig.dbPort }}"
- - name: NAMESPACE
- value: {{ include "common.namespace" . }}
- volumeMounts:
- - mountPath: /hrmconfig
- name: {{ include "common.fullname" . }}-general-config
- - mountPath: /config
- name: {{ include "common.fullname" . }}-env-config
- containers:
- - name: {{ include "common.name" . }}
- image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
- imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
- resources: {{ include "common.resources" . | nindent 10 }}
- ports: {{ include "common.containerPorts" . | nindent 8 }}
- volumeMounts:
- - name: {{ include "common.fullname" . }}-env-config
- mountPath: /opt/hrmconfig
- - name: {{ include "common.fullname" . }}-rule-config
- mountPath: /opt/hrmrules
- # disable liveness probe when breakpoints set in debugger
- # so K8s doesn't restart unresponsive container
- {{- if eq .Values.liveness.enabled true }}
- livenessProbe:
- httpGet:
- path: {{ .Values.liveness.path }}
- port: {{ .Values.liveness.port }}
- scheme: {{ .Values.liveness.scheme }}
- initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
- periodSeconds: {{ .Values.liveness.periodSeconds }}
- {{- end }}
- readinessProbe:
- httpGet:
- path: {{ .Values.readiness.path }}
- port: {{ .Values.readiness.port }}
- scheme: {{ .Values.readiness.scheme }}
- initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
- periodSeconds: {{ .Values.readiness.periodSeconds }}
- failureThreshold: 1
- successThreshold: 1
- timeoutSeconds: 1
- env:
- - name: CONSUL_HOST
- value: consul-server.{{ include "common.namespace" . }}
- - name: CONFIG_BINDING_SERVICE
- value: config-binding-service
- - name: MSB_IAG_SERVICE_PROTOCOL
- value: {{ .Values.global.msbProtocol }}
- - name: MSB_IAG_SERVICE_HOST
- value: {{ .Values.global.msbServiceName }}.{{ include "common.namespace" . }}
- - name: MSB_IAG_SERVICE_PORT
- value: {{ .Values.global.msbPort | quote}}
- - name: POD_IP
- valueFrom:
- fieldRef:
- apiVersion: v1
- fieldPath: status.podIP
- - name: PGPASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: JDBC_USERNAME
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "login") | indent 10 }}
- - name: JDBC_PASSWORD
- {{- include "common.secret.envFromSecretFast" (dict "global" . "uid" "pg-user-creds" "key" "password") | indent 10 }}
- - name: DB_NAME
- value: {{ .Values.config.pgConfig.dbName }}
- - name: URL_JDBC
- value: {{ .Values.config.pgConfig.dbHost }}
- - name: DB_PORT
- value: "{{ .Values.config.pgConfig.dbPort }}"
- serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
- volumes:
- - name: {{ include "common.fullname" . }}-general-config
- configMap:
- defaultMode: 422
- name: {{ include "common.fullname" . }}-general-config
- - name: {{ include "common.fullname" . }}-rule-config
- configMap:
- defaultMode: 422
- name: {{ include "common.fullname" . }}-rule-config
- - name: {{ include "common.fullname" . }}-env-config
- emptyDir:
- medium: Memory
- {{- include "common.imagePullSecrets" . | nindent 6 }}
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/templates/ingress.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/templates/ingress.yaml
deleted file mode 100644
index bcc60a0953..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/templates/ingress.yaml
+++ /dev/null
@@ -1,17 +0,0 @@
-{{/*
-# Copyright © 2023 Deutsche Telekom
-#
-# 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.ingress" . }}
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/templates/secret.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/templates/secret.yaml
deleted file mode 100644
index 34932b713d..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/templates/secret.yaml
+++ /dev/null
@@ -1,17 +0,0 @@
-{{/*
-# Copyright © 2020 Samsung Electronics
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-*/}}
-
-{{ include "common.secretFast" . }}
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/templates/service.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/templates/service.yaml
deleted file mode 100644
index 70abf763e0..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/templates/service.yaml
+++ /dev/null
@@ -1,20 +0,0 @@
-{{/*
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2019 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.service" . }}
diff --git a/kubernetes/holmes/components/holmes-rule-mgmt/values.yaml b/kubernetes/holmes/components/holmes-rule-mgmt/values.yaml
deleted file mode 100644
index a7e0e25a17..0000000000
--- a/kubernetes/holmes/components/holmes-rule-mgmt/values.yaml
+++ /dev/null
@@ -1,149 +0,0 @@
-#============LICENSE_START========================================================
-# ================================================================================
-# Copyright (c) 2021 ZTE Corporation Intellectual Property. All rights reserved.
-# Modifications 2023 Deutsche Telekom
-# ================================================================================
-# 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.
-#################################################################
-global:
- nodePortPrefixExt: 302
- msbProtocol: http
- msbServiceName: msb-iag
- msbPort: 80
- postgres:
- localCluster: false
-
-#################################################################
-# Application configuration defaults.
-#################################################################
-# application image
-image: onap/holmes/rule-management:12.0.0
-consulLoaderImage: onap/org.onap.dcaegen2.deployments.consul-loader-container:1.0.0
-
-#################################################################
-# Secrets metaconfig
-#################################################################
-secrets:
-- uid: pg-user-creds
- type: basicAuth
- externalSecret: '{{ tpl (default "" .Values.config.pgConfig.dbUserCredsExternalSecret) . }}'
- login: '{{ .Values.config.pgConfig.dbUser }}'
- password: '{{ .Values.config.pgConfig.dbUserPassword }}'
-
-# application configuration
-config:
- logstashServiceName: log-ls
- logstashPort: 5044
- # Addresses of other ONAP entities
- address:
- consul:
- host: consul-server
- port: 8500
- pgConfig:
- dbName: defaultName
- dbHost: defaultHost
- dbPort: 1234
- dbUser: admin
- dbUserPassword: admin
- # dbUserCredsExternalSecret
-
-service:
- type: NodePort
- name: holmes-rule-mgmt
- ports:
- - name: http-rest
- port: &svc_port 9101
- nodePort: 92
- - name: http-ui
- port: &ui_port 9104
- nodePort: 93
- annotations:
- msb.onap.org/service-info: |
- {{ if .Values.global.msbEnabled -}}[
- {
- "serviceName": "holmes-rule-mgmt",
- "version": "v1",
- "url": "/api/holmes-rule-mgmt/v1",
- "path":"/api/holmes-rule-mgmt/v1",
- "protocol": "REST",
- "visualRange":"0|1",
- "port": "9101",
- "enable_ssl": false
- }
- ]{{ end }}
-
-ingress:
- enabled: false
- service:
- - baseaddr: "holmes-rule-mgmt"
- name: "holmes-rule-mgmt"
- path: "/api/holmes-rule-mgmt/v1"
- port: *svc_port
- - baseaddr: "holmes-rule-mgmt-ui"
- name: "holmes-rule-mgmt"
- path: "/iui/holmes"
- port: *ui_port
- config:
- ssl: "redirect"
-
-# probe configuration parameters
-liveness:
- initialDelaySeconds: 10
- port: *svc_port
- periodSeconds: 10
- path: /api/holmes-rule-mgmt/v1/healthcheck
- enabled: true
- scheme: HTTP
-
-readiness:
- initialDelaySeconds: 30
- port: *svc_port
- periodSeconds: 30
- path: /api/holmes-rule-mgmt/v1/healthcheck
- scheme: HTTP
-
-# Segregation for Different environment (Small and Large)
-resources:
- small:
- limits:
- cpu: "1"
- memory: "1Gi"
- requests:
- cpu: "0.5"
- memory: "1Gi"
- large:
- limits:
- cpu: "2"
- memory: "2Gi"
- requests:
- cpu: "1"
- memory: "1Gi"
- unlimited: {}
-
-readinessCheck:
- wait_for_global:
- jobs:
- - '{{ include "common.release" . }}-holmes-postgres-init-config-job'
- wait_for_local:
- services:
- - '{{ .Values.global.postgres.service.name2 }}'
-
-#Pods Service Account
-serviceAccount:
- nameOverride: holmes-rule-mgmt
- roles:
- - read
diff --git a/kubernetes/holmes/templates/secrets.yaml b/kubernetes/holmes/templates/secrets.yaml
deleted file mode 100644
index 34932b713d..0000000000
--- a/kubernetes/holmes/templates/secrets.yaml
+++ /dev/null
@@ -1,17 +0,0 @@
-{{/*
-# Copyright © 2020 Samsung Electronics
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-*/}}
-
-{{ include "common.secretFast" . }}
diff --git a/kubernetes/holmes/values.yaml b/kubernetes/holmes/values.yaml
deleted file mode 100644
index 4ede9a15fd..0000000000
--- a/kubernetes/holmes/values.yaml
+++ /dev/null
@@ -1,112 +0,0 @@
-# Copyright © 2017 Amdocs, Bell Canada
-# Modifications Copyright © 2021 ZTE
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-#################################################################
-# Global configuration defaults.
-#################################################################
-global:
- nodePortPrefix: 302
- consulLoaderImage: onap/org.onap.dcaegen2.deployments.consul-loader-container:1.0.0
- #Service Names of the postgres db to connect to.
- #Override it to dbc-pg if localCluster is enabled.
- postgres:
- #This flag allows SO to instantiate its own mariadb-galera cluster
- #When changing it to "true", also set "globalCluster: false"
- #as the dependency check will not work otherwise (Chart.yaml)
- localCluster: false
- globalCluster: true
- service:
- name: pgset
- name2: &postgres tcp-pgset-primary
- name3: tcp-pgset-replica
- container:
- name: postgres
-secrets:
-- uid: pg-root-pass
- name: &pgRootPassSecretName '{{ include "common.release" . }}-holmes-pg-root-pass'
- type: password
- externalSecret: '{{ ternary "" (tpl (default "" .Values.postgres.config.pgRootPasswordExternalSecret) .) (hasSuffix "holmes-pg-root-pass" .Values.postgres.config.pgRootPasswordExternalSecret) }}'
- password: '{{ .Values.postgres.config.pgRootPassword }}'
-- uid: pg-user-creds
- name: &pgUserCredsSecretName '{{ include "common.release" . }}-holmes-pg-user-creds'
- type: basicAuth
- externalSecret: '{{ ternary "" (tpl (default "" .Values.postgres.config.pgUserExternalSecret) .) (hasSuffix "holmes-pg-user-creds" .Values.postgres.config.pgUserExternalSecret) }}'
- login: '{{ .Values.postgres.config.pgUserName }}'
- password: '{{ .Values.postgres.config.pgUserPassword }}'
- passwordPolicy: generate
-
-#################################################################
-# Application configuration defaults.
-#################################################################
-pullPolicy: IfNotPresent
-
-config:
- logstashServiceName: log-ls
- logstashPort: 5044
-
-# application configuration override for postgres
-postgres:
- nameOverride: holmes-pg
- service:
- name: holmes-postgres
- name2: &dbHost holmes-postgres-primary
- name3: holmes-postgres-replica
- container:
- name:
- primary: holmes-postgres-primary
- replica: holmes-postgres-replica
- config:
- pgUserName: holmes
- pgDatabase: &dbName holmes
- pgUserExternalSecret: *pgUserCredsSecretName
- pgRootPasswordExternalSecret: *pgRootPassSecretName
- pgPort: &dbPort "5432"
- persistence:
- mountSubPath: holmes/data
- mountInitPath: holmes
-
-postgres-init:
- nameOverride: holmes-postgres-init
- config:
- pgUserName: holmes
- pgDatabase: *dbName
- pgDataPath: data
- pgUserExternalSecret: *pgUserCredsSecretName
- # pgPrimaryPassword: password
- # pgUserPassword: password
- # pgRootPassword: password
- serviceAccount:
- nameOverride: holmes-postgres-init
-
-holmes-engine-mgmt:
- config:
- pgConfig:
- dbName: *dbName
- # dbHost: *dbHost
- dbHost: *postgres
- dbPort: *dbPort
- dbUserCredsExternalSecret: *pgUserCredsSecretName
-
-holmes-rule-mgmt:
- config:
- pgConfig:
- dbName: *dbName
- # dbHost: *dbHost
- dbHost: *postgres
- dbPort: *dbPort
- dbUserCredsExternalSecret: *pgUserCredsSecretName
-
-# Resource Limit flavor -By Default using small
-flavor: small