Skip to content

Commit

Permalink
restore old helm
Browse files Browse the repository at this point in the history
  • Loading branch information
pasqualespica committed Mar 4, 2024
1 parent 98bfe97 commit a08236c
Show file tree
Hide file tree
Showing 4 changed files with 418 additions and 133 deletions.
103 changes: 36 additions & 67 deletions helm/values-prod.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
microservice-chart: &microservice-chart
microservice-chart:
namespace: "apiconfig"
nameOverride: ""
fullnameOverride: ""
Expand All @@ -7,27 +7,9 @@ microservice-chart: &microservice-chart
rollingUpdate:
maxUnavailable: 0
maxSurge: 1
canaryDelivery:
create: false
ingress:
canary:
type: header
headerName: X-Canary
headerValue: canary
weightPercent: 0
service:
create: true
deployment:
create: true
image:
repository: ghcr.io/pagopa/pagopa-api-config-selfcare-integration
tag: 1.8.6-11-export-iban
pullPolicy: Always
envConfig: {}
envSecret: {}
image:
repository: ghcr.io/pagopa/pagopa-api-config-selfcare-integration
tag: "1.10.0-4-PAGOPA-1561-from-oracle-2-pgflex"
tag: "1.10.0"
pullPolicy: Always
livenessProbe:
httpGet:
Expand Down Expand Up @@ -59,9 +41,10 @@ microservice-chart: &microservice-chart
type: ClusterIP
ports:
- 8080
ingress: &ingress
ingress:
create: true
host: "weuprod.apiconfig.internal.platform.pagopa.it"
path: /pagopa-api-config-selfcare-integration/(.*)
servicePort: 8080
serviceAccount:
create: false
Expand Down Expand Up @@ -96,22 +79,30 @@ microservice-chart: &microservice-chart
# Required
type: Utilization # Allowed types are 'Utilization' or 'AverageValue'
value: "75"
envConfig: &envConfig
envConfig:
WEBSITE_SITE_NAME: 'pagopaapiconfigselfcareintegration' # required to show cloud role name in application insights
APPLICATIONINSIGHTS_ROLE_NAME: "pagopa-api-config-selfcare-integration"
ENV: 'azure-prod'
CORS_CONFIGURATION: '{"origins": ["*"], "methods": ["*"]}'
APP_LOGGING_LEVEL: 'DEBUG'
APP_LOGGING_LEVEL: 'INFO'
DEFAULT_LOGGING_LEVEL: 'INFO'
CORS_CONFIGURATION: '{"origins": ["*"], "methods": ["*"]}'
SPRING_DATASOURCE_USERNAME: 'NODO4_CFG'
SPRING_DATASOURCE_URL: "jdbc:oracle:thin:@(DESCRIPTION=(ENABLE=BROKEN)(ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=db-nodo-pagamenti.p.db-nodo-pagamenti.com))(CONNECT_DATA=(SERVICE_NAME=NDPSPCP_NODO4_CFG))(SO_KEEPALIVE=true)(TCP_KEEPIDLE=60)(TCP_KEEPINTVL=30)(TCP_KEEPCNT=15))"
SPRING_DATASOURCE_DRIVER: 'oracle.jdbc.OracleDriver'
DB_CONFIG_DRIVER: 'oracle.jdbc.OracleDriver'
DATABASE_SCHEMA: 'NODO4_CFG'
SPRING_JPA_DB_PLATFORM: 'org.hibernate.dialect.Oracle12cDialect'
OTEL_SERVICE_NAME: "pagopa-api-config-selfcare-integration"
OTEL_RESOURCE_ATTRIBUTES: "deployment.environment=azure-prod"
OTEL_EXPORTER_OTLP_ENDPOINT: "http://otel-collector.elastic-system.svc:4317"
OTEL_LOGS_EXPORTER: none
OTEL_TRACES_SAMPLER: "always_on"
envFieldRef: &envFieldRef
envFieldRef:
APP_NAME: "metadata.labels['app.kubernetes.io/instance']"
APP_VERSION: "metadata.labels['app.kubernetes.io/version']"
envSecret: &envSecret
# required
envSecret:
APPLICATIONINSIGHTS_CONNECTION_STRING: 'ai-p-connection-string'
SPRING_DATASOURCE_PASSWORD: 'oracle-db-cfg-password'
OTEL_EXPORTER_OTLP_HEADERS: elastic-apm-secret-token
keyvault:
name: "pagopa-p-apiconfig-kv"
Expand All @@ -136,43 +127,21 @@ microservice-chart: &microservice-chart
app.kubernetes.io/instance: apiconfig-selfcare-integration
namespaces: ["apiconfig"]
topologyKey: topology.kubernetes.io/zone
# Configuration used to update image tag (stable or canary) by pipeline
microservice-chart:
!!merge <<: *microservice-chart
# Configuration for PostgreSQL
postgresql:
!!merge <<: *microservice-chart
ingress:
!!merge <<: *ingress
path: /pagopa-api-config-selfcare-integration/p/(.*)
envConfig:
!!merge <<: *envConfig
WEBSITE_SITE_NAME: 'pagopaapiconfigselfcareintegration' # required to show cloud role name in application insights
APPLICATIONINSIGHTS_ROLE_NAME: "pagopa-api-config-selfcare-integration"
SPRING_DATASOURCE_URL: 'jdbc:postgresql://pagopa-p-weu-nodo-flexible-postgresql.postgres.database.azure.com:6432/nodo?sslmode=require&prepareThreshold=0&currentSchema=cfg'
SPRING_DATASOURCE_USERNAME: 'cfg'
SPRING_DATASOURCE_DRIVER: 'org.postgresql.Driver'
SPRING_JPA_DB_PLATFORM: 'org.hibernate.dialect.PostgreSQLDialect'
DATABASE_SCHEMA: 'cfg'
HEALTHCHECK_QUERY: "select 1"
envSecret:
!!merge <<: *envSecret
SPRING_DATASOURCE_PASSWORD: 'postgresql-db-cfg-password'
# Configuration for Oracle
oracle:
!!merge <<: *microservice-chart
ingress:
!!merge <<: *ingress
path: /pagopa-api-config-selfcare-integration/o/(.*)
envConfig:
!!merge <<: *envConfig
WEBSITE_SITE_NAME: 'pagopaapiconfigselfcareintegration' # required to show cloud role name in application insights
APPLICATIONINSIGHTS_ROLE_NAME: "pagopa-api-config-selfcare-integration"
SPRING_DATASOURCE_URL: "jdbc:oracle:thin:@(DESCRIPTION=(ENABLE=BROKEN)(ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=db-nodo-pagamenti.p.db-nodo-pagamenti.com))(CONNECT_DATA=(SERVICE_NAME=NDPSPCP_NODO4_CFG))(SO_KEEPALIVE=true)(TCP_KEEPIDLE=60)(TCP_KEEPINTVL=30)(TCP_KEEPCNT=15))"
SPRING_DATASOURCE_USERNAME: 'NODO4_CFG'
SPRING_DATASOURCE_DRIVER: 'oracle.jdbc.OracleDriver'
SPRING_JPA_DB_PLATFORM: 'org.hibernate.dialect.Oracle12cDialect'
DATABASE_SCHEMA: 'NODO4_CFG'
envSecret:
!!merge <<: *envSecret
SPRING_DATASOURCE_PASSWORD: 'oracle-db-cfg-password'
canaryDelivery:
create: false
ingress:
canary:
type: header
headerName: X-Canary
headerValue: canary
weightPercent: 0
service:
create: true
deployment:
create: true
image:
repository: ghcr.io/pagopa/pagopa-api-config-selfcare-integration
tag: 1.8.6-11-export-iban
pullPolicy: Always
envConfig: {}
envSecret: {}
178 changes: 178 additions & 0 deletions helm/values-prod.yaml.MULTI_INSTANCES
Original file line number Diff line number Diff line change
@@ -0,0 +1,178 @@
microservice-chart: &microservice-chart
namespace: "apiconfig"
nameOverride: ""
fullnameOverride: ""
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 0
maxSurge: 1
canaryDelivery:
create: false
ingress:
canary:
type: header
headerName: X-Canary
headerValue: canary
weightPercent: 0
service:
create: true
deployment:
create: true
image:
repository: ghcr.io/pagopa/pagopa-api-config-selfcare-integration
tag: 1.8.6-11-export-iban
pullPolicy: Always
envConfig: {}
envSecret: {}
image:
repository: ghcr.io/pagopa/pagopa-api-config-selfcare-integration
tag: "1.10.0-4-PAGOPA-1561-from-oracle-2-pgflex"
pullPolicy: Always
livenessProbe:
httpGet:
path: /actuator/health/liveness
port: 8080
initialDelaySeconds: 90
failureThreshold: 6
periodSeconds: 10
readinessProbe:
httpGet:
path: /actuator/health/readiness
port: 8080
initialDelaySeconds: 90
failureThreshold: 6
periodSeconds: 10
deployment:
create: true
serviceMonitor:
create: true
endpoints:
- interval: 10s #jmx-exporter
targetPort: 12345
path: /metrics
ports:
- 80 #http
- 12345 #jmx-exporter
service:
create: true
type: ClusterIP
ports:
- 8080
ingress: &ingress
create: true
host: "weuprod.apiconfig.internal.platform.pagopa.it"
servicePort: 8080
serviceAccount:
create: false
annotations: {}
name: ""
podAnnotations: {}
podSecurityContext:
seccompProfile:
type: RuntimeDefault
securityContext:
readOnlyRootFilesystem: false
allowPrivilegeEscalation: false
capabilities:
drop:
- all
resources:
requests:
memory: "512Mi"
cpu: "0.4"
limits:
memory: "768Mi"
cpu: "0.5"
autoscaling:
enable: true
minReplica: 1
maxReplica: 5
pollingInterval: 10 # seconds
cooldownPeriod: 50 # seconds
triggers:
- type: cpu
metadata:
# Required
type: Utilization # Allowed types are 'Utilization' or 'AverageValue'
value: "75"
envConfig: &envConfig
ENV: 'azure-prod'
CORS_CONFIGURATION: '{"origins": ["*"], "methods": ["*"]}'
APP_LOGGING_LEVEL: 'DEBUG'
DEFAULT_LOGGING_LEVEL: 'INFO'
OTEL_SERVICE_NAME: "pagopa-api-config-selfcare-integration"
OTEL_RESOURCE_ATTRIBUTES: "deployment.environment=azure-prod"
OTEL_EXPORTER_OTLP_ENDPOINT: "http://otel-collector.elastic-system.svc:4317"
OTEL_LOGS_EXPORTER: none
OTEL_TRACES_SAMPLER: "always_on"
envFieldRef: &envFieldRef
APP_NAME: "metadata.labels['app.kubernetes.io/instance']"
APP_VERSION: "metadata.labels['app.kubernetes.io/version']"
envSecret: &envSecret
# required
APPLICATIONINSIGHTS_CONNECTION_STRING: 'ai-p-connection-string'
OTEL_EXPORTER_OTLP_HEADERS: elastic-apm-secret-token
keyvault:
name: "pagopa-p-apiconfig-kv"
tenantId: "7788edaf-0346-4068-9d79-c868aed15b3d"
nodeSelector: {}
tolerations: []
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node_type
operator: In
values:
- user
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
labelSelector:
matchLabels:
app.kubernetes.io/instance: apiconfig-selfcare-integration
namespaces: ["apiconfig"]
topologyKey: topology.kubernetes.io/zone
# Configuration used to update image tag (stable or canary) by pipeline
microservice-chart:
!!merge <<: *microservice-chart
# Configuration for PostgreSQL
postgresql:
!!merge <<: *microservice-chart
ingress:
!!merge <<: *ingress
path: /pagopa-api-config-selfcare-integration/p/(.*)
envConfig:
!!merge <<: *envConfig
WEBSITE_SITE_NAME: 'pagopaapiconfigselfcareintegration' # required to show cloud role name in application insights
APPLICATIONINSIGHTS_ROLE_NAME: "pagopa-api-config-selfcare-integration"
SPRING_DATASOURCE_URL: 'jdbc:postgresql://pagopa-p-weu-nodo-flexible-postgresql.postgres.database.azure.com:6432/nodo?sslmode=require&prepareThreshold=0&currentSchema=cfg'
SPRING_DATASOURCE_USERNAME: 'cfg'
SPRING_DATASOURCE_DRIVER: 'org.postgresql.Driver'
SPRING_JPA_DB_PLATFORM: 'org.hibernate.dialect.PostgreSQLDialect'
DATABASE_SCHEMA: 'cfg'
HEALTHCHECK_QUERY: "select 1"
envSecret:
!!merge <<: *envSecret
SPRING_DATASOURCE_PASSWORD: 'postgresql-db-cfg-password'
# Configuration for Oracle
oracle:
!!merge <<: *microservice-chart
ingress:
!!merge <<: *ingress
path: /pagopa-api-config-selfcare-integration/o/(.*)
envConfig:
!!merge <<: *envConfig
WEBSITE_SITE_NAME: 'pagopaapiconfigselfcareintegration' # required to show cloud role name in application insights
APPLICATIONINSIGHTS_ROLE_NAME: "pagopa-api-config-selfcare-integration"
SPRING_DATASOURCE_URL: "jdbc:oracle:thin:@(DESCRIPTION=(ENABLE=BROKEN)(ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=db-nodo-pagamenti.p.db-nodo-pagamenti.com))(CONNECT_DATA=(SERVICE_NAME=NDPSPCP_NODO4_CFG))(SO_KEEPALIVE=true)(TCP_KEEPIDLE=60)(TCP_KEEPINTVL=30)(TCP_KEEPCNT=15))"
SPRING_DATASOURCE_USERNAME: 'NODO4_CFG'
SPRING_DATASOURCE_DRIVER: 'oracle.jdbc.OracleDriver'
SPRING_JPA_DB_PLATFORM: 'org.hibernate.dialect.Oracle12cDialect'
DATABASE_SCHEMA: 'NODO4_CFG'
envSecret:
!!merge <<: *envSecret
SPRING_DATASOURCE_PASSWORD: 'oracle-db-cfg-password'
Loading

0 comments on commit a08236c

Please sign in to comment.