27d5e84b191f0bfb9c9507f5230d7278e939678c
[oom.git] / kubernetes / cds / values.yaml
1 # Copyright © 2020 Samsung Electronics
2 # Copyright © 2019 Orange, Bell Canada
3 # Copyright © 2017 Amdocs, Bell Canada
4 # Modification Copyright © 2022-2023 Nordix Foundation
5 #
6 # Licensed under the Apache License, Version 2.0 (the "License");
7 # you may not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
9 #
10 #       http://www.apache.org/licenses/LICENSE-2.0
11 #
12 # Unless required by applicable law or agreed to in writing, software
13 # distributed under the License is distributed on an "AS IS" BASIS,
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 # See the License for the specific language governing permissions and
16 # limitations under the License.
17
18 #################################################################
19 # Global configuration defaults.
20 #################################################################
21 global:
22   nodePortPrefix: 302
23   nodePortPrefixExt: 304
24   persistence:
25     mountPath: /dockerdata-nfs
26
27 #################################################################
28 # Secrets metaconfig
29 #################################################################
30 secrets:
31   - name: &dbUserSecretName '{{ include "common.release" . }}-cds-db-secret'
32     uid: 'cds-db-secret'
33     type: basicAuth
34     externalSecret: '{{ ternary "" (tpl (default "" (index .Values "mariadb-galera" "db" "externalSecret")) .) (hasSuffix "cds-db-secret" (index .Values "mariadb-galera" "db" "externalSecret"))}}'
35     login: '{{ index .Values "mariadb-galera" "db" "user" }}'
36     password: '{{ index .Values "mariadb-galera" "db" "password" }}'
37
38 #################################################################
39 # Application configuration defaults.
40 #################################################################
41 # application images
42 pullPolicy: Always
43
44 subChartsOnly:
45   enabled: true
46
47 # flag to enable debugging - application support required
48 debugEnabled: false
49
50 # default number of instances
51 replicaCount: 1
52
53 nodeSelector: {}
54
55 affinity: {}
56
57 # probe configuration parameters
58 liveness:
59   initialDelaySeconds: 20
60   periodSeconds: 20
61   timeoutSeconds: 20
62   # necessary to disable liveness probe when setting breakpoints
63   # in debugger so K8s doesn't restart unresponsive container
64   enabled: true
65
66 readiness:
67   initialDelaySeconds: 10
68   periodSeconds: 10
69
70 ingress:
71   enabled: false
72
73 mariadb-galera:
74   db:
75     user: sdnctl
76     # password:
77     externalSecret: *dbUserSecretName
78     name: &mysqlDbName sdnctl
79   nameOverride: &dbServer cds-db
80   replicaCount: 1
81   persistence:
82     enabled: true
83     mountSubPath: cds/data
84   serviceAccount:
85     nameOverride: *dbServer
86
87   mariadbConfiguration: |-
88     [client]
89     port=3306
90     socket=/opt/bitnami/mariadb/tmp/mysql.sock
91     plugin_dir=/opt/bitnami/mariadb/plugin
92
93     [mysqld]
94     lower_case_table_names = 1
95     default_storage_engine=InnoDB
96     basedir=/opt/bitnami/mariadb
97     datadir=/bitnami/mariadb/data
98     plugin_dir=/opt/bitnami/mariadb/plugin
99     tmpdir=/opt/bitnami/mariadb/tmp
100     socket=/opt/bitnami/mariadb/tmp/mysql.sock
101     pid_file=/opt/bitnami/mariadb/tmp/mysqld.pid
102     bind_address=0.0.0.0
103
104     ## Character set
105     collation_server=utf8_unicode_ci
106     init_connect='SET NAMES utf8'
107     character_set_server=utf8
108
109     ## MyISAM
110     key_buffer_size=32M
111     myisam_recover_options=FORCE,BACKUP
112
113     ## Safety
114     skip_host_cache
115     skip_name_resolve
116     max_allowed_packet=16M
117     max_connect_errors=1000000
118     sql_mode=STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_AUTO_VALUE_ON_ZERO,NO_ENGINE_SUBSTITUTION,NO_ZERO_DATE,NO_ZERO_IN_DATE,ONLY_FULL_GROUP_BY
119     sysdate_is_now=1
120
121     ## Binary Logging
122     log_bin=mysql-bin
123     expire_logs_days=14
124     # Disabling for performance per http://severalnines.com/blog/9-tips-going-production-galera-cluster-mysql
125     sync_binlog=0
126     # Required for Galera
127     binlog_format=row
128
129     ## Caches and Limits
130     tmp_table_size=32M
131     max_heap_table_size=32M
132     # Re-enabling as now works with Maria 10.1.2
133     query_cache_type=1
134     query_cache_limit=4M
135     query_cache_size=256M
136     max_connections=500
137     thread_cache_size=50
138     open_files_limit=65535
139     table_definition_cache=4096
140     table_open_cache=4096
141
142     ## InnoDB
143     innodb=FORCE
144     innodb_strict_mode=1
145     # Mandatory per https://github.com/codership/documentation/issues/25
146     innodb_autoinc_lock_mode=2
147     # Per https://www.percona.com/blog/2006/08/04/innodb-double-write/
148     innodb_doublewrite=1
149     innodb_flush_method=O_DIRECT
150     innodb_log_files_in_group=2
151     innodb_log_file_size=128M
152     innodb_flush_log_at_trx_commit=1
153     innodb_file_per_table=1
154     # 80% Memory is default reco.
155     # Need to re-evaluate when DB size grows
156     innodb_buffer_pool_size=2G
157     innodb_file_format=Barracuda
158
159     ## Logging
160     log_error=/opt/bitnami/mariadb/logs/mysqld.log
161     slow_query_log_file=/opt/bitnami/mariadb/logs/mysqld.log
162     log_queries_not_using_indexes=1
163     slow_query_log=1
164
165     ## SSL
166     ## Use extraVolumes and extraVolumeMounts to mount /certs filesystem
167     # ssl_ca=/certs/ca.pem
168     # ssl_cert=/certs/server-cert.pem
169     # ssl_key=/certs/server-key.pem
170
171     [galera]
172     wsrep_on=ON
173     wsrep_provider=/opt/bitnami/mariadb/lib/libgalera_smm.so
174     wsrep_sst_method=mariabackup
175     wsrep_slave_threads=4
176     wsrep_cluster_address=gcomm://
177     wsrep_cluster_name=galera
178     wsrep_sst_auth="root:"
179     # Enabled for performance per https://mariadb.com/kb/en/innodb-system-variables/#innodb_flush_log_at_trx_commit
180     innodb_flush_log_at_trx_commit=2
181     # MYISAM REPLICATION SUPPORT #
182     wsrep_replicate_myisam=ON
183
184     [mariadb]
185     plugin_load_add=auth_pam
186
187     ## Data-at-Rest Encryption
188     ## Use extraVolumes and extraVolumeMounts to mount /encryption filesystem
189     # plugin_load_add=file_key_management
190     # file_key_management_filename=/encryption/keyfile.enc
191     # file_key_management_filekey=FILE:/encryption/keyfile.key
192     # file_key_management_encryption_algorithm=AES_CTR
193     # encrypt_binlog=ON
194     # encrypt_tmp_files=ON
195
196     ## InnoDB/XtraDB Encryption
197     # innodb_encrypt_tables=ON
198     # innodb_encrypt_temporary_tables=ON
199     # innodb_encrypt_log=ON
200     # innodb_encryption_threads=4
201     # innodb_encryption_rotate_key_age=1
202
203     ## Aria Encryption
204     # aria_encrypt_tables=ON
205     # encrypt_tmp_disk_tables=ON
206
207 cds-blueprints-processor:
208   enabled: true
209   config:
210     cdsDB:
211       dbServer: *dbServer
212       dbPort: 3306
213       dbName: *mysqlDbName
214       dbCredsExternalSecret: *dbUserSecretName
215
216 cds-command-executor:
217   enabled: true
218
219 cds-py-executor:
220   enabled: true
221
222 cds-sdc-listener:
223   enabled: true
224
225 cds-ui:
226   enabled: true
227
228 #Resource Limit flavor -By Default using small
229 flavor: small
230 #segregation for different environment (Small and Large)
231 resources:
232   small:
233     limits:
234       cpu: 2
235       memory: 4Gi
236     requests:
237       cpu: 1
238       memory: 2Gi
239   large:
240     limits:
241       cpu: 4
242       memory: 8Gi
243     requests:
244       cpu: 2
245       memory: 4Gi
246   unlimited: {}