puthuparambil.aditya | 7625e52 | 2021-01-22 22:01:50 +0100 | [diff] [blame] | 1 | # Copyright (C) 2021 Pantheon.tech, Orange |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | |
| 15 | ################################################################# |
| 16 | # Secrets. |
| 17 | ################################################################# |
| 18 | secrets: |
| 19 | - uid: pg-root-pass |
| 20 | name: &pgRootPassSecretName '{{ include "common.release" . }}-cps-pg-root-pass' |
| 21 | type: password |
| 22 | externalSecret: '{{ ternary "" (tpl (default "" .Values.postgres.config.pgRootPasswordExternalSecret) .) (hasSuffix "cps-pg-root-pass" .Values.postgres.config.pgRootPasswordExternalSecret) }}' |
| 23 | password: '{{ .Values.postgres.config.pgRootpassword }}' |
| 24 | policy: generate |
| 25 | - uid: pg-user-creds |
| 26 | name: &pgUserCredsSecretName '{{ include "common.release" . }}-cps-pg-user-creds' |
| 27 | type: basicAuth |
| 28 | externalSecret: '{{ ternary "" (tpl (default "" .Values.postgres.config.pgUserExternalSecret) .) (hasSuffix "cps-pg-user-creds" .Values.postgres.config.pgUserExternalSecret) }}' |
| 29 | login: '{{ .Values.postgres.config.pgUserName }}' |
| 30 | password: '{{ .Values.postgres.config.pgUserPassword }}' |
| 31 | passwordPolicy: generate |
| 32 | |
| 33 | ################################################################# |
| 34 | # Global configuration defaults. |
| 35 | ################################################################# |
| 36 | |
| 37 | # bitnami image doesn't support well single quote in password |
| 38 | passwordStrengthOverride: basic |
| 39 | global: |
| 40 | ingress: |
| 41 | virtualhost: |
| 42 | baseurl: "simpledemo.onap.org" |
| 43 | |
| 44 | image: onap/cps-and-nf-proxy:0.0.1 |
| 45 | containerPort: &svc_port 8080 |
| 46 | |
| 47 | service: |
| 48 | type: ClusterIP |
| 49 | name: cps |
| 50 | ports: |
| 51 | - name: &port http |
| 52 | port: *svc_port |
| 53 | |
| 54 | pullPolicy: Always |
| 55 | # flag to enable debugging - application support required |
| 56 | debugEnabled: false |
| 57 | nodeSelector: {} |
| 58 | affinity: {} |
| 59 | # Resource Limit flavor -By Default using small |
| 60 | flavor: small |
| 61 | # default number of instances |
| 62 | replicaCount: 1 |
| 63 | # Segregation for Different environment (Small and Large) |
| 64 | resources: |
| 65 | small: |
| 66 | limits: |
| 67 | cpu: 2 |
| 68 | memory: 2Gi |
| 69 | requests: |
| 70 | cpu: 1 |
| 71 | memory: 1Gi |
| 72 | large: |
| 73 | limits: |
| 74 | cpu: 4 |
| 75 | memory: 4Gi |
| 76 | requests: |
| 77 | cpu: 2 |
| 78 | memory: 2Gi |
| 79 | unlimited: {} |
| 80 | # probe configuration parameters |
| 81 | liveness: |
| 82 | initialDelaySeconds: 20 |
| 83 | periodSeconds: 20 |
| 84 | # necessary to disable liveness probe when setting breakpoints |
| 85 | # in debugger so K8s doesn't restart unresponsive container |
| 86 | enabled: true |
| 87 | path: /manage/health |
| 88 | port: *port |
| 89 | |
| 90 | readiness: |
| 91 | initialDelaySeconds: 15 |
| 92 | periodSeconds: 15 |
| 93 | path: /manage/health |
| 94 | port: *port |
| 95 | |
| 96 | ingress: |
| 97 | enabled: true |
| 98 | service: |
| 99 | - baseaddr: "cps" |
| 100 | path: "/" |
| 101 | name: "cps" |
| 102 | port: *svc_port |
| 103 | |
| 104 | serviceAccount: |
| 105 | nameOverride: cps |
| 106 | roles: |
| 107 | - read |
| 108 | |
| 109 | securityContext: |
| 110 | user_id: 100 |
| 111 | group_id: 655533 |
| 112 | |
| 113 | ################################################################# |
| 114 | # Application configuration defaults. |
| 115 | ################################################################# |
| 116 | logging: |
| 117 | level: INFO |
| 118 | path: /tmp |
| 119 | ################################################################# |
| 120 | # Postgres overriding defaults in the postgres |
| 121 | ################################################################# |
| 122 | postgres: |
| 123 | nameOverride: &postgresName cps-postgres |
| 124 | service: |
| 125 | name: *postgresName |
| 126 | name2: cps-pg-primary |
| 127 | name3: cps-pg-replica |
| 128 | container: |
| 129 | name: |
| 130 | primary: cps-pg-primary |
| 131 | replica: cps-pg-replica |
| 132 | persistence: |
| 133 | mountSubPath: cps/data |
| 134 | mountInitPath: cps |
| 135 | config: |
| 136 | pgUserName: cps |
| 137 | pgDatabase: cpsdb |
| 138 | pgUserExternalSecret: *pgUserCredsSecretName |
| 139 | pgRootPasswordExternalSecret: *pgRootPassSecretName |
| 140 | |
| 141 | readinessCheck: |
| 142 | wait_for: |
| 143 | - cps-postgres |