Merge "[POLICY] Update docker images to latest versions"
[oom.git] / kubernetes / policy / values.yaml
1 # Copyright © 2017 Amdocs, Bell Canada
2 # Modifications Copyright © 2018-2020 AT&T Intellectual Property
3 # Modifications Copyright (C) 2021-2023 Nordix Foundation.
4 #
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
8 #
9 #       http://www.apache.org/licenses/LICENSE-2.0
10 #
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16
17 #################################################################
18 # Global configuration defaults.
19 #################################################################
20 global:
21   mariadb:
22     localCluster: true
23     # '&mariadbConfig' means we "store" the values for  later use in the file
24     # with '*mariadbConfig' pointer.
25     config: &mariadbConfig
26       mysqlDatabase: policyadmin
27     service: &mariadbService
28       name: &policy-mariadb policy-mariadb
29       internalPort: 3306
30   prometheusEnabled: false
31   postgres:
32     localCluster: false
33     service:
34       name: pgset
35       name2: tcp-pgset-primary
36       name3: tcp-pgset-replica
37     container:
38       name: postgres
39   #Strimzi Kafka properties
40   useStrimziKafka: true
41   # Temporary flag to disable strimzi for pf components - will be removed after native kafka support is added for drools and xacml
42   useStrimziKafkaPf: false
43   kafkaBootstrap: strimzi-kafka-bootstrap
44   policyKafkaUser: policy-kafka-user
45   kafkaTopics:
46     acRuntimeTopic:
47       name: policy.clamp-runtime-acm
48
49 #################################################################
50 # Secrets metaconfig
51 #################################################################
52 secrets:
53   - uid: db-root-password
54     name: &dbRootPassSecretName '{{ include "common.release" . }}-policy-db-root-password'
55     type: password
56     externalSecret: '{{ ternary "" (tpl (default "" (index .Values "mariadb-galera" "rootUser" "externalSecret")) .) (hasSuffix "policy-db-root-password" (index .Values "mariadb-galera" "rootUser" "externalSecret"))}}'
57     password: '{{ (index .Values "mariadb-galera" "rootUser" "password") }}'
58     policy: generate
59   - uid: db-secret
60     name: &dbSecretName '{{ include "common.release" . }}-policy-db-secret'
61     type: basicAuth
62     externalSecret: '{{ ternary "" (tpl (default "" (index .Values "mariadb-galera" "db" "externalSecret")) .) (hasSuffix "policy-db-secret" (index .Values "mariadb-galera" "db" "externalSecret"))}}'
63     login: '{{ index .Values "mariadb-galera" "db" "user" }}'
64     password: '{{ index .Values "mariadb-galera" "db" "password" }}'
65     passwordPolicy: generate
66   - uid: policy-app-user-creds
67     name: &policyAppCredsSecret '{{ include "common.release" . }}-policy-app-user-creds'
68     type: basicAuth
69     externalSecret: '{{ tpl (default "" .Values.config.policyAppUserExternalSecret) . }}'
70     login: '{{ .Values.config.policyAppUserName }}'
71     password: '{{ .Values.config.policyAppUserPassword }}'
72     passwordPolicy: generate
73   - uid: policy-pap-user-creds
74     name: &policyPapCredsSecret '{{ include "common.release" . }}-policy-pap-user-creds'
75     type: basicAuth
76     externalSecret: '{{ tpl (default "" .Values.restServer.policyPapUserExternalSecret) . }}'
77     login: '{{ .Values.restServer.policyPapUserName }}'
78     password: '{{ .Values.restServer.policyPapUserPassword }}'
79     passwordPolicy: required
80   - uid: policy-api-user-creds
81     name: &policyApiCredsSecret '{{ include "common.release" . }}-policy-api-user-creds'
82     type: basicAuth
83     externalSecret: '{{ tpl (default "" .Values.restServer.policyApiUserExternalSecret) . }}'
84     login: '{{ .Values.restServer.policyApiUserName }}'
85     password: '{{ .Values.restServer.policyApiUserPassword }}'
86     passwordPolicy: required
87
88 db: &dbSecretsHook
89   credsExternalSecret: *dbSecretName
90
91 policy-api:
92   enabled: true
93   db: *dbSecretsHook
94   restServer:
95     apiUserExternalSecret: *policyApiCredsSecret
96   config:
97     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
98 policy-pap:
99   enabled: true
100   db: *dbSecretsHook
101   restServer:
102     papUserExternalSecret: *policyPapCredsSecret
103     apiUserExternalSecret: *policyApiCredsSecret
104   config:
105     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
106 policy-xacml-pdp:
107   enabled: true
108   db: *dbSecretsHook
109   config:
110     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
111 policy-apex-pdp:
112   enabled: true
113   db: *dbSecretsHook
114   config:
115     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
116 policy-drools-pdp:
117   enabled: true
118   db: *dbSecretsHook
119   config:
120     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
121 policy-distribution:
122   enabled: true
123   db: *dbSecretsHook
124 policy-clamp-ac-k8s-ppnt:
125   enabled: true
126 policy-clamp-ac-pf-ppnt:
127   enabled: true
128   restServer:
129     apiUserExternalSecret: *policyApiCredsSecret
130     papUserExternalSecret: *policyPapCredsSecret
131 policy-clamp-ac-http-ppnt:
132   enabled: true
133 policy-clamp-ac-a1pms-ppnt:
134   enabled: true
135 policy-clamp-ac-kserve-ppnt:
136   enabled: true
137 policy-clamp-runtime-acm:
138   enabled: true
139   db: *dbSecretsHook
140   config:
141     appUserExternalSecret: *policyAppCredsSecret
142 policy-nexus:
143   enabled: false
144   config:
145     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
146 policy-gui:
147   enabled: false
148   config:
149     jaasConfExternalSecret: '{{ include "common.release" . }}-{{ .Values.global.policyKafkaUser }}'
150
151 #################################################################
152 # DB configuration defaults.
153 #################################################################
154
155 dbmigrator:
156   image: onap/policy-db-migrator:2.6.2
157   schema: policyadmin
158   policy_home: "/opt/app/policy"
159
160 subChartsOnly:
161   enabled: true
162
163 # flag to enable debugging - application support required
164 debugEnabled: false
165
166 # default number of instances
167 replicaCount: 1
168
169 nodeSelector: {}
170
171 affinity: {}
172
173 # probe configuration parameters
174 liveness:
175   initialDelaySeconds: 10
176   periodSeconds: 10
177   # necessary to disable liveness probe when setting breakpoints
178   # in debugger so K8s doesn't restart unresponsive container
179   enabled: true
180
181 readiness:
182   initialDelaySeconds: 10
183   periodSeconds: 10
184
185
186 config:
187   policyAppUserName: runtimeUser
188   useStrimziKafka: true
189   policyPdpPapTopic:
190     name: policy-pdp-pap
191     partitions: 10
192     retentionMs: 7200000
193     segmentBytes: 1073741824
194     consumer:
195       groupId: policy-group
196   policyHeartbeatTopic:
197     name: policy-heartbeat
198     partitions: 10
199     retentionMs: 7200000
200     segmentBytes: 1073741824
201     consumer:
202       groupId: policy-group
203   policyNotificationTopic:
204     name: policy-notification
205     partitions: 10
206     retentionMs: 7200000
207     segmentBytes: 1073741824
208     consumer:
209       groupId: policy-group
210   someConfig: blah
211
212 mariadb-galera:
213   # mariadb-galera.config and global.mariadb.config must be equals
214   db:
215     user: policy_user
216     # password:
217     externalSecret: *dbSecretName
218     name: &mysqlDbName policyadmin
219   rootUser:
220     externalSecret: *dbRootPassSecretName
221   nameOverride: *policy-mariadb
222   # mariadb-galera.service and global.mariadb.service must be equals
223   service: *mariadbService
224   replicaCount: 1
225   persistence:
226     enabled: true
227     mountSubPath: policy/maria/data
228   serviceAccount:
229     nameOverride: *policy-mariadb
230
231 postgresImage: library/postgres:latest
232 # application configuration override for postgres
233 postgres:
234   nameOverride: &postgresName policy-postgres
235   service:
236     name: *postgresName
237     name2: policy-pg-primary
238     name3: policy-pg-replica
239   container:
240     name:
241       primary: policy-pg-primary
242       replica: policy-pg-replica
243   persistence:
244     mountSubPath: policy/postgres/data
245     mountInitPath: policy
246   config:
247     pgUserName: policy_user
248     pgDatabase: policyadmin
249     pgUserExternalSecret: *dbSecretName
250     pgRootPasswordExternalSecret: *dbRootPassSecretName
251
252 readinessCheck:
253   wait_for:
254     - '{{ ternary .Values.postgres.service.name "postgres" .Values.global.postgres.localCluster }}'
255
256 restServer:
257   policyPapUserName: policyadmin
258   policyPapUserPassword: zb!XztG34
259   policyApiUserName: policyadmin
260   policyApiUserPassword: zb!XztG34
261
262 # Resource Limit flavor -By Default using small
263 # Segregation for Different environment (small, large, or unlimited)
264 flavor: small
265 resources:
266   small:
267     limits:
268       cpu: 1
269       memory: 4Gi
270     requests:
271       cpu: 100m
272       memory: 1Gi
273   large:
274     limits:
275       cpu: 2
276       memory: 8Gi
277     requests:
278       cpu: 200m
279       memory: 2Gi
280   unlimited: {}
281
282 #Pods Service Account
283 serviceAccount:
284   nameOverride: policy
285   roles:
286     - read