From 1e68f3fdbd45f6950006106d408c184b596f6626 Mon Sep 17 00:00:00 2001 From: DAMoskalev <33502773+DAMoskalev@users.noreply.github.com> Date: Thu, 27 Jun 2024 10:52:48 +0300 Subject: [PATCH] Release 1.25.0 (#461) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix pro-api/values.yaml doc (#432) * [tiles-api] Upgrade to 4.54.0 (#428) * Add missing default for enabled_modules->predictors in citylens-web configmap (#433) * navi-router 6.17.0.8 -> 6.17.1.2 (#434) * [PRO-5009] Changed helm/hooks. (#436) * pro-ui: New external style manager config (#426) * pro-ui: New external style manager config * GH Actions readme checker workflow (#438) * base wf * fix * update * update * update * update * update * update * clean * clean * minor documentation changes --------- Co-authored-by: Dmitrii Moskalev * Gh actions readme checker changing name (#440) * base wf * fix * update * update * update * update * update * update * clean * clean * minor documentation changes * changing name --------- Co-authored-by: Dmitrii Moskalev * PRO-UI 2.14.0 (#441) * PRO-UI fix hooks (#443) * [PRO-5181] Обновление pro-api до версии 1.22.0 и pro-ui до версии 2.15.1 (#435) * [PRO-5181] Обновление pro-api до версии 1.17 * [PRO-5181] Поправлены замечания по ревью * [PRO-5181] Поправлен url для catalog * [PRO-5181] обновил образ до 1.22.0 * [PRO-5181] Обновление pro-api до версии 1.17 * [PRO-5181] Поправлены замечания по ревью * [PRO-5181] Поправлен url для catalog * [PRO-5181] обновил образ до 1.22.0 * Add new version for PRO-UI * Fix readme * Citylens 1.9.0 & custom CA support (#439) * Added custom CA support * Update version to 1.9.0 * Fix customCA documentation * Update readme * Fix broken templating * Fix citylens-web configmap (#448) * Gis-platform. Мелкие правки по дефолтным параметрам (#450) * [license] Fixed issue with k8s ca automount (#444) * WAPI-23444 custom ca twins api (#437) * WAPI-23444 custom ca twins api * WAPI-23444 custom ca twins api * WAPI-23444 custom ca twins api * Bump citylens to 1.10.0 (#453) * Bump citylens to 1.10.0 * Complete renaming pro.url to pro.baseUrl * PRO-5559: upgrade key ui to latest (#449) * PRO-5559: upgrade key ui to latest * WAPI-23482 Add configuration for Public API sign (#429) * WAPI-23482 Add configuration for Public API sign * impr * disabled by default * optional signkey in secret * optional signkey in secret * upd image version * reset chart version --------- Co-authored-by: Kirill Salnikov * Правки в чартах mapgl-js-api и floors-api (#420) * Add ability to add extra env vars to citylens-web deployment (#455) * Add ability to add extra env vars to citylens-web deployment * Fix missing end tag * chart/generic-chart syncup (#452) * pro-api serviceAccountOverride support (#456) * changes * update * value description added * readme update * readme update --------- Co-authored-by: Dmitrii Moskalev * [chart/navi-back] 7.23.0.5 release (#451) * release 1.25.0 related changes --------- Co-authored-by: Igor Sheykin <49325415+Ashigo@users.noreply.github.com> Co-authored-by: FreakyGranny Co-authored-by: Петр Беклемишев Co-authored-by: i-bogomazov <106957509+i-bogomazov@users.noreply.github.com> Co-authored-by: Andrew Mikhailov Co-authored-by: Konstantin Lobov Co-authored-by: Dmitrii Moskalev Co-authored-by: Aveldin1 <164148461+Aveldin1@users.noreply.github.com> Co-authored-by: Денис Беляев Co-authored-by: Denis Belyaev <74010851+dbelyaev-nsk@users.noreply.github.com> Co-authored-by: v-loboda <111125664+v-loboda@users.noreply.github.com> Co-authored-by: Sergey Ordin <61708156+sergeLeLe@users.noreply.github.com> Co-authored-by: Voronkov Alexander Co-authored-by: Vladimir Popov Co-authored-by: Dmitriy Donov Co-authored-by: ostrovskiy2gis <108522609+ostrovskiy2gis@users.noreply.github.com> Co-authored-by: Kirill Salnikov Co-authored-by: Michel Beloshitsky Co-authored-by: Полозов Игорь Сергеевич Co-authored-by: uk-navi-ci <161344134+uk-navi-ci@users.noreply.github.com> --- .gitignore | 2 + CHANGELOG.md | 13 + charts/catalog-api/Chart.yaml | 2 +- charts/citylens/Chart.yaml | 2 +- charts/citylens/templates/web/deployment.yaml | 6 + charts/dgtt/Chart.yaml | 2 +- charts/floors-api/Chart.yaml | 2 +- charts/generic-chart/Chart.yaml | 2 +- charts/generic-chart/README.md | 69 +- charts/generic-chart/templates/_cronjob.yaml | 34 + .../generic-chart/templates/_deployment.yaml | 39 +- charts/generic-chart/templates/_helpers.tpl | 22 +- charts/generic-chart/templates/_job.yaml | 18 + charts/generic-chart/templates/_job_spec.yaml | 28 + charts/generic-chart/templates/_pod_spec.yaml | 43 ++ charts/generic-chart/values.yaml | 48 +- charts/gis-platform/Chart.yaml | 2 +- charts/keycloak/Chart.yaml | 2 +- charts/keys/Chart.yaml | 2 +- charts/license/Chart.yaml | 2 +- charts/mapgl-js-api/Chart.yaml | 2 +- charts/mapgl-js-api/values.yaml | 3 +- charts/navi-async-grpc-proxy/Chart.yaml | 2 +- charts/navi-async-matrix/Chart.yaml | 2 +- charts/navi-back/Chart.yaml | 8 +- charts/navi-back/README.md | 427 ++++++----- charts/navi-back/templates/NOTES.txt | 8 +- charts/navi-back/templates/_helpers.tpl | 130 +--- charts/navi-back/templates/configmap.yaml | 696 ++++++++++-------- charts/navi-back/templates/deployment.yaml | 128 ++-- charts/navi-back/templates/hpa.yaml | 40 +- charts/navi-back/templates/ingress.yaml | 4 +- charts/navi-back/templates/pdb.yaml | 22 +- charts/navi-back/templates/secret.yaml | 4 +- charts/navi-back/templates/service.yaml | 19 +- .../navi-back/templates/serviceaccount.yaml | 13 +- charts/navi-back/templates/vpa.yaml | 36 +- charts/navi-back/values.yaml | 390 ++++++---- charts/navi-castle/Chart.yaml | 2 +- charts/navi-front/Chart.yaml | 2 +- charts/navi-restrictions/Chart.yaml | 2 +- charts/navi-router/Chart.yaml | 2 +- charts/navi-splitter/Chart.yaml | 2 +- charts/platform/Chart.yaml | 2 +- charts/pro-api/Chart.yaml | 2 +- charts/pro-api/README.md | 23 +- charts/pro-api/templates/_helpers.tpl | 13 +- charts/pro-api/templates/service-account.yaml | 2 + charts/pro-api/values.yaml | 4 +- charts/pro-ui/Chart.yaml | 2 +- charts/search-api/Chart.yaml | 4 +- charts/search-api/README.md | 2 +- charts/search-api/values.yaml | 2 +- charts/stat-receiver/Chart.yaml | 2 +- charts/tiles-api/Chart.yaml | 2 +- charts/traffic-proxy/Chart.yaml | 2 +- charts/twins-api/Chart.yaml | 2 +- image_versions.txt | 5 +- 58 files changed, 1312 insertions(+), 1041 deletions(-) create mode 100644 charts/generic-chart/templates/_cronjob.yaml create mode 100644 charts/generic-chart/templates/_job.yaml create mode 100644 charts/generic-chart/templates/_job_spec.yaml create mode 100644 charts/generic-chart/templates/_pod_spec.yaml diff --git a/.gitignore b/.gitignore index 34b82a233..2b8f1bd3e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ .idea .DS_Store readme-generator-for-helm +Chart.lock +/charts/*/charts diff --git a/CHANGELOG.md b/CHANGELOG.md index ee94fe1d3..375cab641 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,18 @@ # 2GIS On-Premise Changelog +## [1.25.0] (2024-06-26) +#### Images +``` +navi-back + - frozen-data: + - navi-back:7.15.2.4 + + navi-back:7.23.0.5 +search-api + - search-api:7.76.1 + + search-api:7.77.2 + +``` + ## [1.24.0] (2024-06-19) #### [Breaking-Changes](Breaking-Changes.md#1240) #### Images diff --git a/charts/catalog-api/Chart.yaml b/charts/catalog-api/Chart.yaml index 6c454fc7c..c96b6239a 100644 --- a/charts/catalog-api/Chart.yaml +++ b/charts/catalog-api/Chart.yaml @@ -3,7 +3,7 @@ name: catalog-api type: application description: A Helm chart for Kubernetes to deploy Catalog APIs -version: 1.24.0 +version: 1.25.0 appVersion: 3.600.0 maintainers: diff --git a/charts/citylens/Chart.yaml b/charts/citylens/Chart.yaml index d2fa7aeeb..15044f251 100644 --- a/charts/citylens/Chart.yaml +++ b/charts/citylens/Chart.yaml @@ -3,7 +3,7 @@ name: citylens type: application description: A Helm chart for Kubernetes to deploy Citylens service -version: 1.24.0 +version: 1.25.0 appVersion: 1.10.0 maintainers: diff --git a/charts/citylens/templates/web/deployment.yaml b/charts/citylens/templates/web/deployment.yaml index 1da2129cf..5dcd06be0 100644 --- a/charts/citylens/templates/web/deployment.yaml +++ b/charts/citylens/templates/web/deployment.yaml @@ -67,6 +67,12 @@ spec: - name: SSL_CERT_DIR value: {{ include "citylens.customCA.mountPath" $ }} {{- end }} + {{- if .Values.web.extraEnvVars }} + {{- range $env_name, $env_value := .Values.web.extraEnvVars }} + - name: {{ $env_name }} + value: {{ $env_value | squote }} + {{- end }} + {{- end }} resources: {{- toYaml .Values.web.resources | nindent 12 }} volumeMounts: diff --git a/charts/dgtt/Chart.yaml b/charts/dgtt/Chart.yaml index e597bcc31..13ba30b8c 100644 --- a/charts/dgtt/Chart.yaml +++ b/charts/dgtt/Chart.yaml @@ -3,7 +3,7 @@ name: dgtt description: DGTT Helm chart for Kubernetes type: application -version: 1.24.0 +version: 1.25.0 appVersion: 0.2.27-b188673e09 maintainers: diff --git a/charts/floors-api/Chart.yaml b/charts/floors-api/Chart.yaml index 1f0e506f0..acfbc14b7 100644 --- a/charts/floors-api/Chart.yaml +++ b/charts/floors-api/Chart.yaml @@ -3,7 +3,7 @@ name: floors-api description: Helm for floors service type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.0.4 maintainers: diff --git a/charts/generic-chart/Chart.yaml b/charts/generic-chart/Chart.yaml index 068422b07..dbf9dd4f6 100644 --- a/charts/generic-chart/Chart.yaml +++ b/charts/generic-chart/Chart.yaml @@ -4,7 +4,7 @@ description: Generic library Helm chart for 2Gis type: library keywords: - library -version: 1.24.0 +version: 1.25.0 maintainers: - name: 2gis url: https://github.com/2gis diff --git a/charts/generic-chart/README.md b/charts/generic-chart/README.md index 5066e0cd5..61d9d78ab 100644 --- a/charts/generic-chart/README.md +++ b/charts/generic-chart/README.md @@ -38,6 +38,12 @@ For other templates re-use named definitions as follows: Below are supported parameters. +## Test chart + +Test chart based on generic-chart is located in resources. + +Chart is tested using [pipeline](https://gitlab.2gis.ru/traffic/cicd-pipelines/-/blob/master/pipelines/single-chart.yml). See `.gitlab-ci.yml`. + ### Values #### Common settings @@ -47,23 +53,25 @@ Below are supported parameters. | `nameOverride` | Base name to use in all the Kubernetes entities deployed by this chart. | `""` | | `fullnameOverride` | Base fullname to use in all the Kubernetes entities deployed by this chart. | `""` | -#### Deployment settings - -| Name | Description | Value | -| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | ----- | -| `labels` | Custom labels to set to Deployment resource | `{}` | -| `annotations` | Custom annotations to set to Deployment resource | `{}` | -| `replicaCount` | A replica count for the pod | `1` | -| `revisionHistoryLimit` | Number of replica sets to keep for deployment rollbacks | `1` | -| `strategy` | Deployment [strategy](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy). Undergoes template rendering | `{}` | -| `podAnnotations` | Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) | `{}` | -| `imagePullSecrets` | Kubernetes image pull secrets | `[]` | -| `podSecurityContext` | Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | `{}` | -| `priorityClassName` | Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name | `""` | -| `terminationGracePeriodSeconds` | Maximum time allowed for graceful shutdown | `60` | -| `nodeSelector` | Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) | `{}` | -| `affinity` | Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) | `{}` | -| `tolerations` | Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings | `[]` | +#### [Deployment](https://kubernetes.io/docs/tasks/run-application/run-stateless-application-deployment/) settings + +| Name | Description | Value | +| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | ------- | +| `labels` | Custom labels to set to Deployment resource | `{}` | +| `annotations` | Custom annotations to set to Deployment resource | `{}` | +| `replicaCount` | A replica count for the pod | `1` | +| `revisionHistoryLimit` | Number of replica sets to keep for deployment rollbacks | `1` | +| `strategy` | Deployment [strategy](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy). Undergoes template rendering | `{}` | +| `podAnnotations` | Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) | `{}` | +| `imagePullSecrets` | Kubernetes image pull secrets | `[]` | +| `podSecurityContext` | Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | `{}` | +| `priorityClassName` | Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name | `""` | +| `terminationGracePeriodSeconds` | Maximum time allowed for graceful shutdown | `60` | +| `nodeSelector` | Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) | `{}` | +| `affinity` | Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) | `{}` | +| `tolerations` | Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings | `[]` | +| `enableServiceLinks` | Services injection into containers environment | `false` | +| `restartPolicy` | Kubernetes pod [restart policy](https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy) | `""` | #### Kubernetes [Horizontal Pod Autoscaling](https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/) settings @@ -97,7 +105,7 @@ Below are supported parameters. | `pdb.minAvailable` | How many pods must be available after the eviction. | `""` | | `pdb.maxUnavailable` | How many pods can be unavailable after the eviction. | `1` | -#### Service settings +#### [Service](https://kubernetes.io/docs/concepts/services-networking/service/) settings | Name | Description | Value | | --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | @@ -107,10 +115,33 @@ Below are supported parameters. | `service.clusterIP` | Controls Service cluster IP allocation. Cannot be changed after resource creation. | `""` | | `service.port` | Service port. | `80` | -#### Service account settings +#### [Service account](https://kubernetes.io/docs/concepts/security/service-accounts/) settings | Name | Description | Value | | ---------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ------ | | `serviceAccount.create` | Specifies whether a service account should be created. | `true` | | `serviceAccount.annotations` | Annotations to add to the service account. | `{}` | | `serviceAccount.name` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template. | `""` | + +#### [CronJob](https://kubernetes.io/docs/concepts/workloads/controllers/cron-jobs/) settings + +| Name | Description | Value | +| ------------------------------------ | --------------------------------------------------------------- | ------- | +| `cronJob.suspend` | Suspend execution of Jobs. | `false` | +| `cronJob.schedule` | Schedule follows the Cron syntax. | `""` | +| `cronJob.startingDeadlineSeconds` | Defines a deadline (in whole seconds) for starting the Job. | `""` | +| `cronJob.concurrencyPolicy` | Concurrent executions of a Job that is created by this CronJob. | `""` | +| `cronJob.successfulJobsHistoryLimit` | How many completed Jobs should be kept. | `""` | +| `cronJob.failedJobsHistoryLimit` | How many failed Jobs should be kept. | `""` | + +#### [Job](https://kubernetes.io/docs/concepts/workloads/controllers/job/) settings + +| Name | Description | Value | +| -------------------------- | ----------------------------------------------------------------------------------------------------------------- | ----- | +| `job.backoffLimit` | Number of retries before considering a Job as failed. | `""` | +| `job.backoffLimitPerIndex` | Maximal number of pod failures per index. | `""` | +| `job.podFailurePolicy` | Pod failure policy. | `""` | +| `job.completions` | Number of successful pods for completion Job. | `""` | +| `job.completionMode` | Completion mode (NonIndexed or Indexed). | `""` | +| `job.parallelism` | Number of pods running at any instant. | `""` | +| `job.restartPolicy` | Kubernetes pod [restart policy](https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy) | `""` | diff --git a/charts/generic-chart/templates/_cronjob.yaml b/charts/generic-chart/templates/_cronjob.yaml new file mode 100644 index 000000000..e3cad0852 --- /dev/null +++ b/charts/generic-chart/templates/_cronjob.yaml @@ -0,0 +1,34 @@ +{{- define "generic-chart.cronjob.tpl" }} +{{ $ctx := .ctx }} +{{ $cronJob := .cronJob }} +apiVersion: {{ include "generic-chart.capabilities.cronjob.apiVersion" $ctx }} +kind: CronJob +metadata: + name: {{ include "generic-chart.fullname" $ctx }}{{ include "generic-chart.getSuffix" $cronJob }} + labels: + {{- include "generic-chart.labels" $ctx | nindent 4 }} + {{- with $ctx.labels }} + {{- toYaml . | nindent 4 }} + {{- end }}{{- /* labels */}} + {{- with $ctx.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }}{{- /* annotations */}} +spec: + schedule: {{ required "A valid cronJob.schedule entry required" $cronJob.schedule | quote }} + suspend: {{ ($cronJob).suspend }} + {{- if ($cronJob).startingDeadlineSeconds }} + startingDeadlineSeconds: {{ ($cronJob).startingDeadlineSeconds }} + {{- end }} + {{- if ($cronJob).concurrencyPolicy }} + concurrencyPolicy: {{ ($cronJob).concurrencyPolicy }} + {{- end }} + {{- if ($cronJob).successfulJobsHistoryLimit }} + successfulJobsHistoryLimit: {{ ($cronJob).successfulJobsHistoryLimit }} + {{- end }} + {{- if ($cronJob).failedJobsHistoryLimit }} + failedJobsHistoryLimit: {{ ($cronJob).failedJobsHistoryLimit }} + {{- end }} + jobTemplate: + {{- include "generic-chart.job_spec.tpl" . | nindent 4 }} +{{- end }} diff --git a/charts/generic-chart/templates/_deployment.yaml b/charts/generic-chart/templates/_deployment.yaml index 9cf972b56..6ed68956e 100644 --- a/charts/generic-chart/templates/_deployment.yaml +++ b/charts/generic-chart/templates/_deployment.yaml @@ -29,39 +29,8 @@ spec: matchLabels: {{- include "generic-chart.selectorLabels" . | nindent 6 }} template: - metadata: - {{- with .Values.podAnnotations }} - annotations: - {{- toYaml . | nindent 8 }} - {{- end }}{{- /* podAnnotations */}} - labels: - {{- include "generic-chart.selectorLabels" . | nindent 8 }} - spec: - {{- with .Values.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }}{{- /* imagePullSecrets */}} - serviceAccountName: {{ include "generic-chart.serviceAccountName" . }} - {{- with .Values.podSecurityContext }} - securityContext: - {{- toYaml . | nindent 8 }} - {{- end }}{{- /* podSecurityContext */}} - {{- with .Values.priorityClassName }} - priorityClassName: {{ . }} - {{- end }}{{- /* priorityClassName */}} - {{- with .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ . | default 60 }} - {{- end }}{{- /* terminationGracePeriodSeconds */}} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }}{{- /* nodeSelector */}} - {{- if .Values.affinity }} - affinity: - {{- include "tplvalues.render" ( dict "value" .Values.affinity "context" . ) | nindent 8 }} - {{- end }}{{- /* affinity */}} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }}{{- /* tolerations */}} + {{ include "generic-chart.pod_spec.tpl" . | nindent 4 }} + {{- with .Values.restartPolicy }} + restartPolicy: {{ . }} + {{- end }}{{- /* restartPolicy */}} {{- end }} {{- /* define */}} diff --git a/charts/generic-chart/templates/_helpers.tpl b/charts/generic-chart/templates/_helpers.tpl index 6049d0668..f7554aa78 100644 --- a/charts/generic-chart/templates/_helpers.tpl +++ b/charts/generic-chart/templates/_helpers.tpl @@ -82,7 +82,7 @@ Usage: "value" .Values.vpa.containerName "context" .) }} {{- else }} - {{- .Chart.Name }} + {{- .Chart.Name | replace "_" "-" }} {{- end }} {{- end -}} @@ -145,3 +145,23 @@ containerResource: container: {{ include "generic-chart.containerName" . }} {{- end -}} {{- end -}} + +{{/* +Return the appropriate apiVersion for cronjob. +*/}} +{{- define "generic-chart.capabilities.cronjob.apiVersion" -}} +{{- if semverCompare "<1.21-0" (include "generic-chart.capabilities.kubeVersion" .) -}} +{{- print "batch/v1beta1" -}} +{{- else -}} +{{- print "batch/v1" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the suffix from .suffix. +*/}} +{{- define "generic-chart.getSuffix" -}} +{{- if .suffix -}} +{{- printf "-%s" (toString .suffix) -}} +{{- end -}} +{{- end -}} diff --git a/charts/generic-chart/templates/_job.yaml b/charts/generic-chart/templates/_job.yaml new file mode 100644 index 000000000..72b725e7d --- /dev/null +++ b/charts/generic-chart/templates/_job.yaml @@ -0,0 +1,18 @@ +{{- define "generic-chart.job.tpl" -}} +{{ $ctx := .ctx }} +{{ $job := .job }} +apiVersion: batch/v1 +kind: Job +metadata: + name: {{ include "generic-chart.fullname" $ctx }}{{ include "generic-chart.getSuffix" $job }} + labels: + {{- include "generic-chart.labels" $ctx | nindent 4 }} + {{- with $ctx.labels }} + {{- toYaml . | nindent 4 }} + {{- end }}{{- /* labels */}} + {{- with $ctx.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }}{{- /* annotations */}} +{{ include "generic-chart.job_spec.tpl" . }} +{{- end }} diff --git a/charts/generic-chart/templates/_job_spec.yaml b/charts/generic-chart/templates/_job_spec.yaml new file mode 100644 index 000000000..b969f3166 --- /dev/null +++ b/charts/generic-chart/templates/_job_spec.yaml @@ -0,0 +1,28 @@ +{{- define "generic-chart.job_spec.tpl" -}} +{{ $ctx := .ctx }} +{{ $job := .job }} +spec: + {{- if ($job).backoffLimit }} + backoffLimit: {{ ($job).backoffLimit }} + {{- end }} + {{- if ($job).backoffLimitPerIndex }} + backoffLimitPerIndex: {{ ($job).backoffLimitPerIndex }} + {{- end }} + {{- if ($job).podFailurePolicy }} + podFailurePolicy: {{ ($job).podFailurePolicy }} + {{- end }} + {{- if ($job).completions }} + completions: {{ ($job).completions }} + {{- end }} + {{- if ($job).completionMode }} + completionMode: {{ ($job).completionMode }} + {{- end }} + {{- if ($job).parallelism }} + parallelism: {{ ($job).parallelism }} + {{- end }} + template: + {{- include "generic-chart.pod_spec.tpl" $ctx | nindent 4 }} + {{- with ($job).restartPolicy }} + restartPolicy: {{ . }} + {{- end }}{{- /* restartPolicy */}} +{{- end }} diff --git a/charts/generic-chart/templates/_pod_spec.yaml b/charts/generic-chart/templates/_pod_spec.yaml new file mode 100644 index 000000000..a9b07a7f3 --- /dev/null +++ b/charts/generic-chart/templates/_pod_spec.yaml @@ -0,0 +1,43 @@ +{{- define "generic-chart.pod_spec.tpl" -}} +{{- /* +apiVersion: v1 +kind: Pod +metadata: +*/ -}} +metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }}{{- /* podAnnotations */}} + labels: + {{- include "generic-chart.selectorLabels" . | nindent 8 }} +spec: + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }}{{- /* imagePullSecrets */}} + serviceAccountName: {{ include "generic-chart.serviceAccountName" . }} + {{- with .Values.podSecurityContext }} + securityContext: + {{- toYaml . | nindent 8 }} + {{- end }}{{- /* podSecurityContext */}} + {{- with .Values.priorityClassName }} + priorityClassName: {{ . }} + {{- end }}{{- /* priorityClassName */}} + {{- with .Values.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ . | default 60 }} + {{- end }}{{- /* terminationGracePeriodSeconds */}} + enableServiceLinks: {{ .Values.enableServiceLinks | default false }} + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }}{{- /* nodeSelector */}} + {{- if .Values.affinity }} + affinity: + {{- include "tplvalues.render" ( dict "value" .Values.affinity "context" . ) | nindent 8 }} + {{- end }}{{- /* affinity */}} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }}{{- /* tolerations */}} +{{- end }} {{- /* define */}} diff --git a/charts/generic-chart/values.yaml b/charts/generic-chart/values.yaml index 717c6a0a5..46541b202 100644 --- a/charts/generic-chart/values.yaml +++ b/charts/generic-chart/values.yaml @@ -7,7 +7,7 @@ nameOverride: '' fullnameOverride: '' -# @section Deployment settings +# @section [Deployment](https://kubernetes.io/docs/tasks/run-application/run-stateless-application-deployment/) settings # @param labels Custom labels to set to Deployment resource # @param annotations Custom annotations to set to Deployment resource @@ -22,6 +22,8 @@ fullnameOverride: '' # @param nodeSelector Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) # @param affinity Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) # @param tolerations Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings +# @param enableServiceLinks Services injection into containers environment +# @param restartPolicy Kubernetes pod [restart policy](https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy) labels: {} annotations: {} @@ -36,6 +38,8 @@ terminationGracePeriodSeconds: 60 nodeSelector: {} affinity: {} tolerations: [] +enableServiceLinks: false +restartPolicy: '' # @section Kubernetes [Horizontal Pod Autoscaling](https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/) settings @@ -86,7 +90,7 @@ pdb: maxUnavailable: 1 -# @section Service settings +# @section [Service](https://kubernetes.io/docs/concepts/services-networking/service/) settings # @param service.labels Kubernetes [service labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/). Undergoes template rendering # @param service.annotations Kubernetes [service annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/). Undergoes template rendering @@ -102,7 +106,7 @@ service: port: 80 -# @section Service account settings +# @section [Service account](https://kubernetes.io/docs/concepts/security/service-accounts/) settings # @param serviceAccount.create Specifies whether a service account should be created. # @param serviceAccount.annotations Annotations to add to the service account. @@ -112,3 +116,41 @@ serviceAccount: create: true annotations: {} name: '' + + +# @section [CronJob](https://kubernetes.io/docs/concepts/workloads/controllers/cron-jobs/) settings + +# @param cronJob.suspend Suspend execution of Jobs. +# @param cronJob.schedule Schedule follows the Cron syntax. +# @param cronJob.startingDeadlineSeconds Defines a deadline (in whole seconds) for starting the Job. +# @param cronJob.concurrencyPolicy Concurrent executions of a Job that is created by this CronJob. +# @param cronJob.successfulJobsHistoryLimit How many completed Jobs should be kept. +# @param cronJob.failedJobsHistoryLimit How many failed Jobs should be kept. + +cronJob: + suspend: false + schedule: '' + startingDeadlineSeconds: '' + concurrencyPolicy: '' + successfulJobsHistoryLimit: '' + failedJobsHistoryLimit: '' + + +# @section [Job](https://kubernetes.io/docs/concepts/workloads/controllers/job/) settings + +# @param job.backoffLimit Number of retries before considering a Job as failed. +# @param job.backoffLimitPerIndex Maximal number of pod failures per index. +# @param job.podFailurePolicy Pod failure policy. +# @param job.completions Number of successful pods for completion Job. +# @param job.completionMode Completion mode (NonIndexed or Indexed). +# @param job.parallelism Number of pods running at any instant. +# @param job.restartPolicy Kubernetes pod [restart policy](https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy) + +job: + backoffLimit: '' + backoffLimitPerIndex: '' + podFailurePolicy: '' + completions: '' + completionMode: '' + parallelism: '' + restartPolicy: '' diff --git a/charts/gis-platform/Chart.yaml b/charts/gis-platform/Chart.yaml index 3311c0790..c5677d0de 100644 --- a/charts/gis-platform/Chart.yaml +++ b/charts/gis-platform/Chart.yaml @@ -4,7 +4,7 @@ description: GIS Platform type: application -version: 1.24.0 +version: 1.25.0 appVersion: 2023.8.3-0 dependencies: diff --git a/charts/keycloak/Chart.yaml b/charts/keycloak/Chart.yaml index 16224dd43..0aade0761 100644 --- a/charts/keycloak/Chart.yaml +++ b/charts/keycloak/Chart.yaml @@ -5,7 +5,7 @@ description: Keycloak is a high performance Java-based identity and access manag solution. It lets developers add an authentication layer to their applications with minimum effort. -version: 1.24.0 +version: 1.25.0 appVersion: 21.1.1-debian-11-r4 maintainers: diff --git a/charts/keys/Chart.yaml b/charts/keys/Chart.yaml index c2b7676ed..98d2e3268 100644 --- a/charts/keys/Chart.yaml +++ b/charts/keys/Chart.yaml @@ -3,7 +3,7 @@ name: keys type: application description: A Helm chart for Kubernetes to deploy API Keys service -version: 1.24.0 +version: 1.25.0 appVersion: 1.85.2 maintainers: diff --git a/charts/license/Chart.yaml b/charts/license/Chart.yaml index e76efc388..0f46426af 100644 --- a/charts/license/Chart.yaml +++ b/charts/license/Chart.yaml @@ -3,7 +3,7 @@ name: license type: application description: A Helm chart for Kubernetes to deploy License service -version: 1.24.0 +version: 1.25.0 appVersion: 2.2.1 maintainers: diff --git a/charts/mapgl-js-api/Chart.yaml b/charts/mapgl-js-api/Chart.yaml index 079ade97e..78a7877ad 100644 --- a/charts/mapgl-js-api/Chart.yaml +++ b/charts/mapgl-js-api/Chart.yaml @@ -4,7 +4,7 @@ description: Basic WebGL map chart template for 2GIS On-Premise type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.47.1 maintainers: diff --git a/charts/mapgl-js-api/values.yaml b/charts/mapgl-js-api/values.yaml index d9ba882c5..de89d3f7f 100644 --- a/charts/mapgl-js-api/values.yaml +++ b/charts/mapgl-js-api/values.yaml @@ -65,8 +65,7 @@ env: MAPGL_KEYSERVER: https://keys-api.ingress.host/public/v1/keys/{keyID}/services/mapgl-js-api MAPGL_RTLPLUGIN: https://mapgl-api.ingress.host/api/js/plugins/rtl-v1.0.0.js MAPGL_RTLPLUGINHASH: sha512-YAPPEl+Atvsm/cMkrfWefmlQLAlKTGaqFjIkI6urAnDgam2uTVEVVnZZEhHCa91JjYYxa5yr4Ndb4Vl3NUovfA== - MAPGL_INVALID_KEY_MESSAGE: Your MapGL key is invalid. Please contact support to - get valid key. + MAPGL_INVALID_KEY_MESSAGE: Your MapGL key is invalid. Please contact support to get valid key. # @section Strategy settings diff --git a/charts/navi-async-grpc-proxy/Chart.yaml b/charts/navi-async-grpc-proxy/Chart.yaml index d75b52e85..b405dbf11 100644 --- a/charts/navi-async-grpc-proxy/Chart.yaml +++ b/charts/navi-async-grpc-proxy/Chart.yaml @@ -6,7 +6,7 @@ keywords: - navi - dm-async-matrix - async-grpc-proxy -version: 1.24.0 +version: 1.25.0 appVersion: 0.0.2 maintainers: - name: 2gis diff --git a/charts/navi-async-matrix/Chart.yaml b/charts/navi-async-matrix/Chart.yaml index c194066c1..abe6cba9a 100644 --- a/charts/navi-async-matrix/Chart.yaml +++ b/charts/navi-async-matrix/Chart.yaml @@ -4,7 +4,7 @@ description: Service implements asynchronous API over Distance Matrix type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.6.2 maintainers: diff --git a/charts/navi-back/Chart.yaml b/charts/navi-back/Chart.yaml index ecadf3af5..311088951 100644 --- a/charts/navi-back/Chart.yaml +++ b/charts/navi-back/Chart.yaml @@ -6,8 +6,12 @@ keywords: - navi - back - backend -version: 1.24.0 -appVersion: 7.15.2.4 +version: 1.25.0 +appVersion: 7.23.0.5 +dependencies: +- name: generic-chart + version: '*' + repository: file://../generic-chart maintainers: - name: 2gis url: https://github.com/2gis diff --git a/charts/navi-back/README.md b/charts/navi-back/README.md index 9da6418b3..5f12e302e 100644 --- a/charts/navi-back/README.md +++ b/charts/navi-back/README.md @@ -22,231 +22,277 @@ See the [documentation](https://docs.2gis.com/en/on-premise/navigation) to learn ### Docker Registry settings -| Name | Description | Value | -| --------------------- | --------------------------------------------------------------------------------------- | ----- | -| `dgctlDockerRegistry` | Docker Registry endpoint where On-Premise services' images reside. Format: `host:port`. | `""` | +| Name | Description | Value | +| --------------------- | -------------------------------------------------------------------------------------- | ----- | +| `dgctlDockerRegistry` | Docker Registry endpoint where On-Premise services' images reside. Format: `host:port` | `""` | ### Common settings -| Name | Description | Value | -| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | ----- | -| `replicaCount` | A replica count for the pod. | `1` | -| `revisionHistoryLimit` | Number of replica sets to keep for deployment rollbacks | `1` | -| `imagePullSecrets` | Kubernetes image pull secrets. | `[]` | -| `nameOverride` | Base name to use in all the Kubernetes entities deployed by this chart. | `""` | -| `fullnameOverride` | Base fullname to use in all the Kubernetes entities deployed by this chart. | `""` | -| `podAnnotations` | Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/). | `{}` | -| `podSecurityContext` | Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/). | `{}` | -| `securityContext` | Kubernetes [security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/). | `{}` | -| `nodeSelector` | Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector). | `{}` | -| `tolerations` | Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings. | `[]` | -| `affinity` | Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity). | `{}` | -| `labels` | Custom labels to set to Deployment resource. | `{}` | -| `priorityClassName` | Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name. | `""` | -| `preStopDelay` | Delay in seconds before terminating container. | `5` | -| `terminationGracePeriodSeconds` | Maximum time allowed for graceful shutdown. | `60` | - -### Deployment settings +| Name | Description | Value | +| ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------ | ------ | +| `replicaCount` | A replica count for the pod | `1` | +| `revisionHistoryLimit` | Number of replica sets to keep for deployment rollbacks | `1` | +| `imagePullSecrets` | Kubernetes image pull secrets | `[]` | +| `nameOverride` | Base name to use in all the Kubernetes entities deployed by this chart | `""` | +| `fullnameOverride` | Base fullname to use in all the Kubernetes entities deployed by this chart | `""` | +| `podAnnotations` | Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) | `{}` | +| `podSecurityContext` | Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | `{}` | +| `securityContext` | Kubernetes [security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) | `{}` | +| `nodeSelector` | Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) | `{}` | +| `tolerations` | Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings | `[]` | +| `affinity` | Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) | `{}` | +| `labels` | Custom labels to set to Deployment resource | `{}` | +| `priorityClassName` | Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name | `""` | +| `preStopDelay` | Delay in seconds before terminating container | `5` | +| `terminationGracePeriodSeconds` | Maximum time allowed for graceful shutdown | `60` | +| `extraVolumes` | Optionally specify extra list of additional volumes | `[]` | +| `extraVolumeMounts` | Optionally specify extra list of additional volumeMounts | `[]` | +| `initContainers` | Add additional init containers | `[]` | +| `sidecars` | Add additional sidecar containers | `[]` | +| `livenessProbe.enabled` | Enable livenessProbe | `true` | +| `livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `0` | +| `livenessProbe.periodSeconds` | Period seconds for livenessProbe | `5` | +| `livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `3` | +| `livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `2` | +| `livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `readinessProbe.enabled` | Enable readinessProbe | `true` | +| `readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `0` | +| `readinessProbe.periodSeconds` | Period seconds for readinessProbe | `5` | +| `readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `3` | +| `readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `2` | +| `readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `startupProbe.enabled` | Enable startupProbe | `true` | +| `startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `0` | +| `startupProbe.periodSeconds` | Period seconds for startupProbe | `5` | +| `startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `startupProbe.failureThreshold` | Failure threshold for startupProbe | `360` | +| `startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `customLivenessProbe` | Override default liveness probe | `{}` | +| `customReadinessProbe` | Override default readiness probe | `{}` | +| `customStartupProbe` | Override default startup probe | `{}` | +| `command` | Override default command | `[]` | +| `args` | Override default args | `[]` | + +### Container image settings | Name | Description | Value | | ------------------ | ----------- | --------------------------- | | `image.repository` | Repository | `2gis-on-premise/navi-back` | -| `image.tag` | Tag | `7.15.2.4` | +| `image.tag` | Tag | `7.23.0.5` | | `image.pullPolicy` | Pull Policy | `IfNotPresent` | ### Navi-Back application settings -| Name | Description | Value | -| ------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------- | -| `naviback.ecaHost` | DEPRECATED: Use naviback.ecaUrl. Domain name of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. | | -| `naviback.ecaUrl` | URL of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. | | -| `naviback.forecastHost` | URL of Traffic forecast service. See the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. | | -| `naviback.dmSourcesLimit` | Size limit for source matrices. | `1000` | -| `naviback.dmTargetsLimit` | Size limit for target matrices. | `1000` | -| `naviback.handlersNumber` | Number of HTTP handlers. | `1` | -| `naviback.maxProcessTime` | Maximum processing time limit in minutes. | `600` | -| `naviback.responseTimelimit` | Maximum response time limit in minutes. | `60` | -| `naviback.requestTimeout` | Maximum request time limit in minutes. | `60` | -| `naviback.timeoutLimitSec` | Maximum downloading time can be reached after failures. | `1200` | -| `naviback.timeoutIncrementSec` | Downloading time increment after failures. | `140` | -| `naviback.totalRetryDurationSec` | Downloading timeout with all failure retries. | `2400` | -| `naviback.initialRetryIntervalSec` | Initial timeout for a failure retry. | `2` | -| `naviback.dump.result` | Dump results in logs. | `false` | -| `naviback.dump.query` | Dump queries in logs. | `false` | -| `naviback.dump.answer` | Dump answers in logs. | `false` | -| `naviback.logLevel` | Logging level, one of: Verbose, Info, Warning, Error, Fatal. | `Info` | -| `naviback.indexFilename` | Name of index file. | `index.json.zip` | -| `naviback.citiesFilename` | Name of the cities file on Castle | `cities.conf.zip` | -| `naviback.sentry.enabled` | If sending crash dumps to Sentry needed | `false` | -| `naviback.sentry.address` | Sentry URL | `sentry.host` | -| `naviback.sentry.project` | Sentry project ID | `navi-back` | -| `naviback.sentry.username` | Sentry username | `navi-back` | -| `naviback.sentry.printMessages` | If outgoing messages needed | `false` | -| `naviback.sentry.debug` | Debugging switch | `false` | -| `naviback.sentry.reportPath` | Local directory to dump | `/tmp/sentry` | -| `naviback.sentry.handler` | Handler file location | `/usr/sbin/2gis/mosesd/crashpad_handler` | -| `naviback.castleHost` | URL of Navi-Castle service, ex: http://navi-castle.svc.
This URL should be accessible from all the pods within your Kubernetes cluster. | `""` | -| `naviback.enablePassableBarriers` | Consider passable barriers. | | -| `naviback.grpcPort` | GRPC port to serve. Disabled if empty. | | -| `naviback.disableUpdates` | Test switch for disabling runtime background updates | `false` | -| `naviback.indices` | List of dynamic indices kill switches. | | -| `naviback.additionalSections` | Optinal JSON block to be added to config file as-is. | | -| `naviback.simpleNetwork.bicycle` | Enable simple network for bicycle routing | | -| `naviback.simpleNetwork.car` | Enable simple network for auto routing | | -| `naviback.simpleNetwork.emergency` | Enable simple network for emergency vehicles routing | `false` | -| `naviback.simpleNetwork.pedestrian` | Enable simple network for pedestrian routing | | -| `naviback.simpleNetwork.taxi` | Enable simple network for taxi routing | | -| `naviback.simpleNetwork.truck` | Enable simple network for truck routing | | -| `naviback.simpleNetwork.scooter` | Enable simple network for scooters routing | | -| `naviback.attractor.bicycle` | Enable enhanced attractor for bicycle routing | | -| `naviback.attractor.car` | Enable enhanced attractor for auto routing | | -| `naviback.attractor.pedestrian` | Enable enhanced attractor for pedestrian routing | | -| `naviback.attractor.taxi` | Enable enhanced attractor for taxi routing | | -| `naviback.attractor.truck` | Enable enhanced attractor for truck routing | | -| `naviback.attractor.scooter` | Enable enhanced attractor for scooters routing | | -| `naviback.bss.enabled` | Enable sending information on the construction of routes to the business statistics service | `false` | -| `naviback.bss.client.serviceRemoteAddress` | Remote address business statistics service. Requeruired for enable sending information. | `""` | -| `naviback.bss.client.messageCountToFlush` | Message count to flush. | `500` | -| `naviback.bss.client.useCompression` | Enable compression. | `true` | -| `naviback.bss.client.packageSizeMaxBytes` | Package size max bytes. | `1800000` | -| `naviback.bss.client.pendingTransmissionMaxCount` | Pending transmission max count. | `10` | -| `naviback.reduceEdgesOptimizationFlag` | Enable optimizations for distance matrix queries processing | | -| `naviback.behindSplitter` | Current instance is behind splitter or not | `false` | -| `naviback.overrideConfig` | Complete config override. For test purposes only. | `""` | -| `naviback.rtr.enabled` | Enable real time restrictions. | `false` | -| `naviback.rtr.url` | URL real time restrictions server. | `http://rtr.navi` | +| Name | Description | Value | +| ------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------- | +| `naviback.ecaHost` | DEPRECATED: Use naviback.ecaUrl. Domain name of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster | | +| `naviback.ecaUrl` | URL of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster | | +| `naviback.forecastHost` | URL of Traffic forecast service. See the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster | | +| `naviback.dmSourcesLimit` | Size limit for source matrices | `1000` | +| `naviback.dmTargetsLimit` | Size limit for target matrices | `1000` | +| `naviback.handlersNumber` | Total number of HTTP/GRPC handlers | `1` | +| `naviback.queueSize` | Internal queue size | `128` | +| `naviback.maxProcessTime` | Maximum processing time limit in minutes | `20` | +| `naviback.responseTimelimit` | Maximum response time limit in minutes | `120` | +| `naviback.requestTimeout` | Maximum request time limit in minutes | `120` | +| `naviback.timeoutLimitSec` | Maximum downloading time can be reached after failures | `1200` | +| `naviback.timeoutIncrementSec` | Downloading time increment after failures | `140` | +| `naviback.totalRetryDurationSec` | Downloading timeout with all failure retries | `2400` | +| `naviback.initialRetryIntervalSec` | Initial timeout for a failure retry | `2` | +| `naviback.dump.result` | Dump results in logs | `false` | +| `naviback.dump.query` | Dump queries in logs | `false` | +| `naviback.dump.answer` | Dump answers in logs | `false` | +| `naviback.logLevel` | Logging level, one of: Verbose, Info, Warning, Error, Fatal | `Info` | +| `naviback.indexFilename` | Name of the index file on Castle | `index.json.zip` | +| `naviback.citiesFilename` | Name of the cities file on Castle | `cities.conf.zip` | +| `naviback.sentry.enabled` | If sending crash dumps to Sentry needed | `false` | +| `naviback.sentry.address` | Sentry URL | `sentry.local` | +| `naviback.sentry.project` | Sentry project ID | `navi-back` | +| `naviback.sentry.username` | Sentry username | `navi` | +| `naviback.sentry.printMessages` | If outgoing messages needed | `false` | +| `naviback.sentry.debug` | Debugging switch | `false` | +| `naviback.sentry.reportPath` | Local directory to dump | `/tmp/sentry` | +| `naviback.sentry.handler` | Handler file location | `/usr/sbin/2gis/mosesd/crashpad_handler` | +| `naviback.castleHost` | DEPRECATED: Use naviback.castleUrl. Domain name of Navi-Castle service.
This URL should be accessible from all the pods within your Kubernetes cluster | | +| `naviback.castleUrl` | URL of Navi-Castle service.
This URL should be accessible from all the pods within your Kubernetes cluster | `""` | +| `naviback.enablePassableBarriers` | Consider passable barriers | | +| `naviback.grpcPort` | GRPC port to serve. Disabled if empty | | +| `naviback.disableUpdates` | Test switch for disabling runtime background updates | `false` | +| `naviback.indices` | List of dynamic indices kill switches | | +| `naviback.additionalSections` | Optinal JSON block to be added to config file as-is | | +| `naviback.simpleNetwork.bicycle` | Enable simple network for bicycle routing | | +| `naviback.simpleNetwork.car` | Enable simple network for auto routing | | +| `naviback.simpleNetwork.emergency` | Enable simple network for emergency vehicles routing | | +| `naviback.simpleNetwork.pedestrian` | Enable simple network for pedestrian routing | | +| `naviback.simpleNetwork.taxi` | Enable simple network for taxi routing | | +| `naviback.simpleNetwork.truck` | Enable simple network for truck routing | | +| `naviback.simpleNetwork.scooter` | Enable simple network for scooters routing | | +| `naviback.attractor.bicycle` | Enable enhanced attractor for bicycle routing | | +| `naviback.attractor.car` | Enable enhanced attractor for auto routing | | +| `naviback.attractor.pedestrian` | Enable enhanced attractor for pedestrian routing | | +| `naviback.attractor.taxi` | Enable enhanced attractor for taxi routing | | +| `naviback.attractor.truck` | Enable enhanced attractor for truck routing | | +| `naviback.attractor.scooter` | Enable enhanced attractor for scooters routing | | +| `naviback.bss.enabled` | Enable sending information on the construction of routes to the business statistics service | `false` | +| `naviback.bss.client.serviceRemoteAddress` | Remote address business statistics service. Requeruired for enable sending information | `""` | +| `naviback.bss.client.messageCountToFlush` | Message count to flush | `500` | +| `naviback.bss.client.useCompression` | Enable compression | `true` | +| `naviback.bss.client.packageSizeMaxBytes` | Package size max bytes | `1800000` | +| `naviback.bss.client.pendingTransmissionMaxCount` | Pending transmission max count | `10` | +| `naviback.bss.client.timeoutLimitMilSec` | Maximum request time limit in milliseconds | `5000` | +| `naviback.reduceEdgesOptimizationFlag` | Enable optimizations for distance matrix queries processing | | +| `naviback.behindSplitter` | The current instance is behind splitter or not | `false` | +| `naviback.overrideConfig` | Complete config override. For test purposes only | `""` | +| `naviback.rtr.enabled` | Enable real time restrictions | `false` | +| `naviback.rtr.url` | URL real time restrictions server | `http://rtr` | +| `naviback.rtr.updatePeriod` | Update period from real time restrictions server | `60` | +| `naviback.validation.enabled` | Enable validation responses and requests (used for internal tests) | `false` | +| `naviback.validation.ctx.schemasFolder` | Path to folder with ctx JSON schemas | `/usr/share/2gis/schemas/nsr_schemas` | +| `naviback.validation.ctx.requestSchemaName` | Name of ctx request validation schema | `CTXRequestModel.json` | +| `naviback.validation.ctx.responseSchemaName` | Name of ctx response validation schema | `CTXResponseModelV4.json` | +| `naviback.validation.bss.schemasFolder` | Path to folder with bss JSON schemas | `/usr/share/2gis/schemas/bss_schemas` | +| `naviback.validation.bss.requestSchemaName` | Name of bss request validation schema | `""` | +| `naviback.validation.bss.responseSchemaName` | Name of bss response validation schema | `401.schema.json` | +| `naviback.validation.distanceMatrix.schemasFolder` | Path to folder with distance matrix JSON schemas | `/usr/share/2gis/schemas/nsr_schemas` | +| `naviback.validation.distanceMatrix.requestSchemaName` | Name of distance matrix request validation schema | `DistanceMatrixRequestModel.json` | +| `naviback.validation.distanceMatrix.responseSchemaName` | Name of distance matrix response validation schema | `DistanceMatrixResponseModel.json` | +| `naviback.validation.isochrone.schemasFolder` | Path to folder with isochrone JSON schemas | `/usr/share/2gis/schemas/nsr_schemas` | +| `naviback.validation.isochrone.requestSchemaName` | Name of isochrone request validation schema | `IsochroneApiRequestModel.json` | +| `naviback.validation.isochrone.responseSchemaName` | Name of isochrone response validation schema | `IsochroneApiResponseModel.json` | +| `naviback.tilesMetricsThreshold` | The value at which we send tiles metrics (used for internal tests) | `0` | +| `naviback.hierarchies.enabled` | If hierarchies cache available | `false` | +| `naviback.hierarchies.s3path` | Hierarchies cache remote location | `""` | +| `naviback.etaScheduleIndex.enabled` | If Schedule Index available | `false` | +| `naviback.etaScheduleIndex.url` | Schedule Index remote url | `""` | ### Envoy settings, ignored if not `transmitter.enabled`. Leave with defaults, FOR FUTURE RELEASE. -| Name | Description | Value | -| ------------------------ | ----------- | ----------------------- | -| `envoy.image.repository` | Repository | `2gis-on-premise/envoy` | -| `envoy.image.tag` | Tag | `v1.27.0` | -| `envoy.image.pullPolicy` | Pull Policy | `IfNotPresent` | - -### Frozen data settings. For test purposes only. - -| Name | Description | Value | -| -------------------------------------- | ------------------------------------------- | ----------------------------- | -| `frozenData.enabled` | If use frozen data is enabled. | `false` | -| `frozenData.image.repository` | Repository | `2gis-on-premise/frozen-data` | -| `frozenData.image.tag` | Tag | `""` | -| `frozenData.image.pullPolicy` | Pull Policy | `Always` | -| `frozenData.resources` | Container resources requirements structure. | `{}` | -| `frozenData.resources.requests.cpu` | CPU request, recommended value `100m`. | `undefined` | -| `frozenData.resources.requests.memory` | Memory request, recommended value `100Mi`. | `undefined` | -| `frozenData.resources.limits.cpu` | CPU limit, recommended value `100m`. | `undefined` | -| `frozenData.resources.limits.memory` | Memory limit, recommended value `100Mi`. | `undefined` | +| Name | Description | Value | +| --------------------------------- | ------------------------------------------ | ----------------------- | +| `envoy.image.repository` | Repository | `2gis-on-premise/envoy` | +| `envoy.image.tag` | Tag | `v1.27.0` | +| `envoy.image.pullPolicy` | Pull Policy | `IfNotPresent` | +| `envoy.resources` | Container resources requirements structure | `{}` | +| `envoy.resources.requests.cpu` | CPU request, recommended value `100m` | `undefined` | +| `envoy.resources.requests.memory` | Memory request, recommended value `100Mi` | `undefined` | +| `envoy.resources.limits.cpu` | CPU limit, recommended value `100m` | `undefined` | +| `envoy.resources.limits.memory` | Memory limit, recommended value `100Mi` | `undefined` | ### Service account settings -| Name | Description | Value | -| ---------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ------- | -| `serviceAccount.create` | Specifies whether a service account should be created. | `false` | -| `serviceAccount.annotations` | Annotations to add to the service account. | `{}` | -| `serviceAccount.name` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template. | `""` | +| Name | Description | Value | +| ---------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ------- | +| `serviceAccount.create` | Specifies whether a service account should be created | `false` | +| `serviceAccount.annotations` | Annotations to add to the service account | `{}` | +| `serviceAccount.name` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template | `""` | ### Service settings -| Name | Description | Value | -| ------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ----------- | -| `service.type` | Kubernetes [service type](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types). | `ClusterIP` | -| `service.clusterIP` | Controls Service cluster IP allocation. Cannot be changed after resource creation. | `""` | -| `service.port` | Service port. | `80` | -| `service.grpcPort` | Service GRPC port if `naviback.grpcPort` enabled. | `50051` | -| `service.annotations` | Kubernetes [service annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/). | `{}` | -| `service.labels` | Kubernetes [service labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/). | `nil` | -| `service.headless.enabled` | Enable creating a secondary headless service | `false` | -| `service.headless.annotations` | Annotations for secondary headless service | `{}` | +| Name | Description | Value | +| ------------------------------ | ----------------------------------------------------------------------------------------------------------------------------- | ----------- | +| `service.type` | Kubernetes [service type](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types) | `ClusterIP` | +| `service.clusterIP` | Controls Service cluster IP allocation. Cannot be changed after resource creation | `""` | +| `service.port` | Service port | `80` | +| `service.grpcPort` | Service GRPC port if `naviback.grpcPort` enabled | `50051` | +| `service.annotations` | Kubernetes [service annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) | `{}` | +| `service.labels` | Kubernetes [service labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/) | `nil` | +| `service.extraPorts` | Extra ports to expose in the service (normally used with the `sidecar` value) | `[]` | +| `service.headless.enabled` | Enable creating a secondary headless service | `false` | +| `service.headless.annotations` | Annotations for secondary headless service | `{}` | ### Kubernetes [Ingress](https://kubernetes.io/docs/concepts/services-networking/ingress/) settings -| Name | Description | Value | -| ------------------------------------ | ----------------------------------------- | ----------------------- | -| `ingress.enabled` | If Ingress is enabled for the service. | `false` | -| `ingress.className` | Name of the Ingress controller class. | `nginx` | -| `ingress.hosts[0].host` | Hostname for the Ingress service. | `navi-back.example.com` | -| `ingress.hosts[0].paths[0].path` | Path of the host for the Ingress service. | `/` | -| `ingress.hosts[0].paths[0].pathType` | Type of the path for the Ingress service. | `Prefix` | -| `ingress.tls` | TLS configuration | `[]` | +| Name | Description | Value | +| ------------------------------------ | ---------------------------------------- | ----------------------- | +| `ingress.className` | Name of the Ingress controller class | `nginx` | +| `ingress.enabled` | If Ingress is enabled for the service | `false` | +| `ingress.hosts[0].host` | Hostname for the Ingress service | `navi-back.example.com` | +| `ingress.hosts[0].paths[0].path` | Path of the host for the Ingress service | `/` | +| `ingress.hosts[0].paths[0].pathType` | Type of the path for the Ingress service | `Prefix` | +| `ingress.tls` | TLS configuration | `[]` | ### Limits -| Name | Description | Value | -| --------------------------- | ------------------------------------------- | ----------- | -| `resources` | Container resources requirements structure. | `{}` | -| `resources.requests.cpu` | CPU request, recommended value `1000m`. | `undefined` | -| `resources.requests.memory` | Memory request, recommended value `2Gi`. | `undefined` | -| `resources.limits.cpu` | CPU limit, recommended value `3000m`. | `undefined` | -| `resources.limits.memory` | Memory limit, recommended value `8Gi`. | `undefined` | +| Name | Description | Value | +| --------------------------- | ------------------------------------------ | ----------- | +| `resources` | Container resources requirements structure | `{}` | +| `resources.requests.cpu` | CPU request, recommended value `1000m` | `undefined` | +| `resources.requests.memory` | Memory request, recommended value `2Gi` | `undefined` | +| `resources.limits.cpu` | CPU limit, recommended value `3000m` | `undefined` | +| `resources.limits.memory` | Memory limit, recommended value `8Gi` | `undefined` | ### Kubernetes [Horizontal Pod Autoscaling](https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/) settings -| Name | Description | Value | -| ----------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | -| `hpa.enabled` | If HPA is enabled for the service. | `false` | -| `hpa.minReplicas` | Lower limit for the number of replicas to which the autoscaler can scale down. | `1` | -| `hpa.maxReplicas` | Upper limit for the number of replicas to which the autoscaler can scale up. | `100` | -| `hpa.scaleDownStabilizationWindowSeconds` | Scale-down window. | `""` | -| `hpa.scaleUpStabilizationWindowSeconds` | Scale-up window. | `""` | -| `hpa.targetCPUUtilizationPercentage` | Target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used. | `80` | -| `hpa.targetMemoryUtilizationPercentage` | Target average memory utilization (represented as a percentage of requested memory) over all the pods; if not specified the default autoscaling policy will be used. | `""` | +| Name | Description | Value | +| ----------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | +| `hpa.enabled` | If HPA is enabled for the service | `false` | +| `hpa.minReplicas` | Lower limit for the number of replicas to which the autoscaler can scale down | `1` | +| `hpa.maxReplicas` | Upper limit for the number of replicas to which the autoscaler can scale up | `100` | +| `hpa.scaleDownStabilizationWindowSeconds` | Scale-down window | `""` | +| `hpa.scaleUpStabilizationWindowSeconds` | Scale-up window | `""` | +| `hpa.targetCPUUtilizationPercentage` | Target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used | `80` | +| `hpa.targetMemoryUtilizationPercentage` | Target average memory utilization (represented as a percentage of requested memory) over all the pods; if not specified the default autoscaling policy will be used | `""` | ### Kubernetes [Vertical Pod Autoscaling](https://github.com/kubernetes/autoscaler/blob/master/vertical-pod-autoscaler/README.md) settings -| Name | Description | Value | -| ----------------------- | ------------------------------------------------------------------------------------------------------------ | ------- | -| `vpa.enabled` | If VPA is enabled for the service. | `false` | -| `vpa.updateMode` | VPA [update mode](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#quick-start). | `Auto` | -| `vpa.minAllowed.cpu` | Lower limit for the number of CPUs to which the autoscaler can scale down. | | -| `vpa.minAllowed.memory` | Lower limit for the RAM size to which the autoscaler can scale down. | | -| `vpa.maxAllowed.cpu` | Upper limit for the number of CPUs to which the autoscaler can scale up. | | -| `vpa.maxAllowed.memory` | Upper limit for the RAM size to which the autoscaler can scale up. | | +| Name | Description | Value | +| ----------------------- | ----------------------------------------------------------------------------------------------------------- | ------- | +| `vpa.enabled` | If VPA is enabled for the service | `false` | +| `vpa.updateMode` | VPA [update mode](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#quick-start) | `Auto` | +| `vpa.minAllowed.cpu` | Lower limit for the number of CPUs to which the autoscaler can scale down | | +| `vpa.minAllowed.memory` | Lower limit for the RAM size to which the autoscaler can scale down | | +| `vpa.maxAllowed.cpu` | Upper limit for the number of CPUs to which the autoscaler can scale up | | +| `vpa.maxAllowed.memory` | Upper limit for the RAM size to which the autoscaler can scale up | | ### Kubernetes [Pod Disruption Budget](https://kubernetes.io/docs/concepts/workloads/pods/disruptions/#pod-disruption-budgets) settings -| Name | Description | Value | -| -------------------- | ---------------------------------------------------- | ------- | -| `pdb.enabled` | If PDB is enabled for the service. | `false` | -| `pdb.minAvailable` | How many pods must be available after the eviction. | `""` | -| `pdb.maxUnavailable` | How many pods can be unavailable after the eviction. | `1` | +| Name | Description | Value | +| -------------------- | --------------------------------------------------- | ------- | +| `pdb.enabled` | If PDB is enabled for the service | `false` | +| `pdb.minAvailable` | How many pods must be available after the eviction | `""` | +| `pdb.maxUnavailable` | How many pods can be unavailable after the eviction | `1` | ### Kafka settings for interacting with Distance Matrix Async Service -| Name | Description | Value | -| ------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------- | -------------- | -| `kafka.enabled` | If the Kafka is enabled. | `false` | -| `kafka.groupId` | Navi-Back service group identifier. | `navi_back` | -| `kafka.properties` | Properties as supported by librdkafka. Refer to inline comments for details. | | -| `kafka.fileProperties` | As kafka.properties, but kept in a file, which passed to application as a filename. Refer to inline comments for details. | `{}` | -| `kafka.distanceMatrix` | **Settings for interacting with Distance Matrix Async service.** | | -| `kafka.distanceMatrix.taskTopic` | Name of the topic for receiving new tasks from Distance Matrix Async API. | `task_topic` | -| `kafka.distanceMatrix.cancelTopic` | Name of the topic for canceling or receiving information about finished tasks. | `cancel_topic` | -| `kafka.distanceMatrix.statusTopic` | Name of the topic for receiving task status information. | `status_topic` | -| `kafka.distanceMatrix.updateTaskStatusPeriodSec` | Update period for task statuses. | `120` | -| `kafka.distanceMatrix.messageExpiredPeriodSec` | Update period for task cancellations. | `3600` | -| `kafka.distanceMatrix.requestDownloadTimeoutSec` | Timeout for downloading request data. | `20` | -| `kafka.distanceMatrix.responseUploadTimeoutSec` | Timeout for uploading response data. | `40` | +| Name | Description | Value | +| ------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | -------------- | +| `kafka.enabled` | If the Kafka is enabled | `false` | +| `kafka.groupId` | Navi-Back service group identifier | `navi_back` | +| `kafka.handlersNumber` | Number of Kafka handlers | `2` | +| `kafka.properties` | Properties as supported by librdkafka. Refer to inline comments for details | | +| `kafka.fileProperties` | As kafka.properties, but kept in a file, which passed to application as a filename. Refer to inline comments for details | `{}` | +| `kafka.distanceMatrix` | **Settings for interacting with Distance Matrix Async service.** | | +| `kafka.distanceMatrix.taskTopic` | Name of the topic for receiving new tasks from Distance Matrix Async API | `task_topic` | +| `kafka.distanceMatrix.cancelTopic` | Name of the topic for canceling or receiving information about finished tasks | `cancel_topic` | +| `kafka.distanceMatrix.statusTopic` | Name of the topic for receiving task status information | `status_topic` | +| `kafka.distanceMatrix.updateTaskStatusPeriodSec` | Update period for task statuses | `120` | +| `kafka.distanceMatrix.messageExpiredPeriodSec` | Update period for task cancellations | `3600` | +| `kafka.distanceMatrix.requestDownloadTimeoutSec` | Timeout for downloading request data | `20` | +| `kafka.distanceMatrix.responseUploadTimeoutSec` | Timeout for uploading response data | `40` | ### S3-compatible storage settings for interacting with Distance Matrix Async Service -| Name | Description | Value | -| -------------- | --------------------------------------- | ------- | -| `s3.enabled` | if S3 storage is enabled. | `false` | -| `s3.host` | S3 endpoint, ex: async-matrix-s3.host. | `""` | -| `s3.bucket` | S3 bucket name. | `""` | -| `s3.accessKey` | S3 access key for accessing the bucket. | `""` | -| `s3.secretKey` | S3 secret key for accessing the bucket. | `""` | +| Name | Description | Value | +| -------------- | ----------------------------------------- | ------- | +| `s3.enabled` | if S3 storage is enabled | `false` | +| `s3.host` | S3 endpoint, ex: async-matrix-s3.host | `""` | +| `s3.bucket` | S3 bucket name | `""` | +| `s3.accessKey` | S3 access key for accessing the bucket | `""` | +| `s3.secretKey` | S3 secret key for accessing the bucket | `""` | +| `s3.suffix` | String to append to file names in replies | `""` | ### Settings for attractor connection. Leave with defaults, FOR FUTURE RELEASE. -| Name | Description | Value | -| ------------------------------- | ------------------------------------------------------------------- | ---------------------------- | -| `transmitter.enabled` | if attractor connection required | `false` | -| `transmitter.type` | connection type one of: grpc, grpc-async, grpc-stream, ws, ws-async | `grpc-async-stream` | -| `transmitter.host` | attractor service | `http://navi-attractor.host` | -| `transmitter.port` | attractor port | `50051` | -| `transmitter.responseTimeoutMs` | response waiting timeout | `100` | +| Name | Description | Value | +| ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------- | +| `transmitter.enabled` | if attractor connection required | `false` | +| `transmitter.type` | connection type one of: grpc, grpc-async, grpc-stream, ws, ws-async | `grpc-async-stream` | +| `transmitter.host` | attractor service | `http://navi-attractor.host` | +| `transmitter.port` | attractor port | `50051` | +| `transmitter.responseTimeoutMs` | response waiting timeout | `2000` | +| `transmitter.retry.enabled` | Enable retry failed requests | `false` | +| `transmitter.retry.retryOn` | Status [codes for retry](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on) | `internal,unavailable` | +| `transmitter.retry.numRetries` | Specifies the allowed number of retries | `5` | ### Back-end and attractor group properties. Leave with defaults, FOR FUTURE RELEASE. @@ -258,10 +304,9 @@ See the [documentation](https://docs.2gis.com/en/on-premise/navigation) to learn ### License settings -| Name | Description | Value | -| ---------------------- | ---------------------------------------------------------------- | ------- | -| `license.url` | Address of the License service v2. Ex: https://license.svc | `""` | -| `license.notSupported` | Excludes the configuration block if true, for old versions only. | `false` | +| Name | Description | Value | +| ------------- | ---------------------------------------------------------- | ----- | +| `license.url` | Address of the License service v2. Ex: https://license.svc | `""` | ### Metrics aggregator container. Leave with defaults, FOR FUTURE RELEASE. @@ -271,12 +316,12 @@ See the [documentation](https://docs.2gis.com/en/on-premise/navigation) to learn | `metrics.image.repository` | Repository | `2gis-on-premise/metrics-aggregator` | | `metrics.image.tag` | Tag | `""` | | `metrics.image.pullPolicy` | Pull Policy | `IfNotPresent` | -| `metrics.port` | Port of container. | `9090` | -| `metrics.resources` | Container resources requirements structure. | `{}` | -| `metrics.resources.requests.cpu` | CPU request, recommended value `10m`. | `undefined` | -| `metrics.resources.requests.memory` | Memory request, recommended value `10Mi`. | | -| `metrics.resources.limits.cpu` | CPU limit, recommended value `100m`. | | -| `metrics.resources.limits.memory` | Memory limit, recommended value `10Mi`. | | +| `metrics.port` | Port of container | `9090` | +| `metrics.resources` | Container resources requirements structure | `{}` | +| `metrics.resources.requests.cpu` | CPU request, recommended value `10m` | `undefined` | +| `metrics.resources.requests.memory` | Memory request, recommended value `10Mi` | | +| `metrics.resources.limits.cpu` | CPU limit, recommended value `100m` | | +| `metrics.resources.limits.memory` | Memory limit, recommended value `10Mi` | | ## Maintainers diff --git a/charts/navi-back/templates/NOTES.txt b/charts/navi-back/templates/NOTES.txt index 0dbc794de..28d930565 100644 --- a/charts/navi-back/templates/NOTES.txt +++ b/charts/navi-back/templates/NOTES.txt @@ -6,16 +6,16 @@ {{- end }} {{- end }} {{- else if contains "NodePort" .Values.service.type }} - export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "naviback.fullname" . }}) + export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "generic-chart.fullname" . }}) export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") echo http://$NODE_IP:$NODE_PORT {{- else if contains "LoadBalancer" .Values.service.type }} NOTE: It may take a few minutes for the LoadBalancer IP to be available. - You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "naviback.fullname" . }}' - export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "naviback.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") + You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "generic-chart.fullname" . }}' + export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "generic-chart.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") echo http://$SERVICE_IP:{{ .Values.service.port }} {{- else if contains "ClusterIP" .Values.service.type }} - export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "naviback.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") + export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "generic-chart.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}") echo "Visit http://127.0.0.1:8080 to use your application" kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT diff --git a/charts/navi-back/templates/_helpers.tpl b/charts/navi-back/templates/_helpers.tpl index 588d0b449..c81df9461 100644 --- a/charts/navi-back/templates/_helpers.tpl +++ b/charts/navi-back/templates/_helpers.tpl @@ -1,39 +1,9 @@ -{{/* -Expand the name of the chart. -*/}} -{{- define "naviback.name" -}} -{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} -{{- end }} - -{{/* -Create a default fully qualified app name. -We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). -If release name contains chart name it will be used as a full name. -*/}} -{{- define "naviback.fullname" -}} -{{- if .Values.fullnameOverride }} -{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} -{{- else }} -{{- $name := default .Chart.Name .Values.nameOverride }} -{{- if contains $name .Release.Name }} -{{- .Release.Name | trunc 63 | trimSuffix "-" }} -{{- else }} -{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} -{{- end }} -{{- end }} -{{- end }} - -{{/* -Create chart name and version as used by the chart label. -*/}} -{{- define "naviback.chart" -}} -{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} -{{- end }} - {{/* Distinguishable main container name +Override generic-chart +TODO: rewrite https://github.com/helm/helm/issues/11291 */}} -{{- define "naviback.containerName" -}} +{{- define "generic-chart.containerName" -}} {{- if .Values.dataGroup.enabled }} {{- .Values.dataGroup.prefix }}-{{ .Chart.Name }} {{- else }} @@ -41,51 +11,6 @@ Distinguishable main container name {{- end }} {{- end -}} -{{/* -Common labels -*/}} -{{- define "naviback.labels" -}} -helm.sh/chart: {{ include "naviback.chart" . }} -{{ include "naviback.selectorLabels" . }} -{{- if .Chart.AppVersion }} -app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} -{{- end }} -app.kubernetes.io/managed-by: {{ .Release.Service }} -{{- end }} - -{{/* -Selector labels -*/}} -{{- define "naviback.selectorLabels" -}} -app.kubernetes.io/name: {{ include "naviback.name" . }} -app.kubernetes.io/instance: {{ .Release.Name }} -{{- end }} - -{{/* -Create the name of the service account to use -*/}} -{{- define "naviback.serviceAccountName" -}} -{{- if .Values.serviceAccount.create }} -{{- default (include "naviback.fullname" .) .Values.serviceAccount.name }} -{{- else }} -{{- default "default" .Values.serviceAccount.name }} -{{- end }} -{{- end }} - - -{{/* -Renders a value that contains template. -Usage: -{{ include "tplvalues.render" ( dict "value" .Values.path.to.the.Value "context" $) }} -*/}} -{{- define "tplvalues.render" -}} - {{- if typeIs "string" .value }} - {{- tpl .value .context }} - {{- else }} - {{- tpl (.value | toYaml) .context }} - {{- end }} -{{- end -}} - {{/* Get count of CPU from limits. @@ -448,48 +373,29 @@ Usage: {{- end -}} {{- end -}} -{{/* -Return the target Kubernetes version -*/}} -{{- define "capabilities.kubeVersion" -}} -{{- if .Values.global }} - {{- if .Values.global.kubeVersion }} - {{- .Values.global.kubeVersion -}} - {{- else }} - {{- default .Capabilities.KubeVersion.Version .Values.kubeVersion -}} - {{- end -}} -{{- else }} -{{- default .Capabilities.KubeVersion.Version .Values.kubeVersion -}} -{{- end -}} -{{- end -}} - -{{/* -Return the appropriate apiVersion for Horizontal Pod Autoscaler. -*/}} -{{- define "capabilities.hpa.apiVersion" -}} -{{- if semverCompare "<1.23-0" (include "capabilities.kubeVersion" .) -}} -{{- if .beta2 -}} -{{- print "autoscaling/v2beta2" -}} -{{- else -}} -{{- print "autoscaling/v2beta1" -}} -{{- end -}} -{{- else -}} -{{- print "autoscaling/v2" -}} -{{- end -}} -{{- end -}} - {{/* Set castle url -If use frozenData return local path Usage: {{ include "config.setCastleUrl" $ }} */}} {{- define "config.setCastleUrl" -}} - {{- if .Values.frozenData.enabled -}} - {{- printf "file://{LOCAL_PATH}" -}} - {{- else if .Values.naviback.castleUrl -}} + {{- if .Values.naviback.castleUrl -}} {{- printf .Values.naviback.castleUrl -}} {{- else if .Values.naviback.castleHost -}} {{- printf "http://%s" .Values.naviback.castleHost -}} {{- end -}} {{- end -}} + +{{/* +Set restriction url +If rtr enabled return naviback.rtr.url, else return naviback.castleUrl +Usage: +{{ include "config.setRestrictionUrl" $ }} +*/}} +{{- define "config.setRestrictionUrl" -}} + {{- if .Values.naviback.rtr.enabled -}} + {{- printf .Values.naviback.rtr.url -}} + {{- else -}} + {{- printf (include "config.setCastleUrl" $) -}} + {{- end -}} +{{- end -}} diff --git a/charts/navi-back/templates/configmap.yaml b/charts/navi-back/templates/configmap.yaml index 6446863ac..0313ae448 100644 --- a/charts/navi-back/templates/configmap.yaml +++ b/charts/navi-back/templates/configmap.yaml @@ -2,7 +2,7 @@ apiVersion: v1 kind: ConfigMap metadata: - name: {{ include "naviback.fullname" . }}-configmap + name: {{ include "generic-chart.fullname" . }}-configmap data: navi-back.conf: | {{- if .Values.naviback.overrideConfig }} @@ -27,18 +27,11 @@ data: "pid_file": "/var/run/2gis/navi-back.pid" }, {{- /* distribute equally fot HTTP/GRPC */}} - {{- $httpHandlers := 0 }} - {{- $grpcHandlers := 0 }} - {{- if .Values.naviback.grpcPort }} - {{- $httpHandlers = div .Values.naviback.handlersNumber 2 }} - {{- $grpcHandlers = sub .Values.naviback.handlersNumber $httpHandlers }} - {{- else }} - {{- $httpHandlers = .Values.naviback.handlersNumber }} - {{- end }} "http": { "server": "0.0.0.0", "port": {{ .Values.naviback.appPort }}, - "handlers_number": {{ $httpHandlers }}, + "handlers_number": {{ .Values.naviback.handlersNumber | int }}, + "queue_size": {{ .Values.naviback.queueSize | int }}, "log_verbose": false, "max_process_time": {{ .Values.naviback.maxProcessTime | default 20 | int }}, "response_timelimit": {{ .Values.naviback.responseTimelimit | default 120 | int }}, @@ -52,23 +45,22 @@ data: {{- if .Values.naviback.grpcPort }} "grpc": { - "server" : "0.0.0.0", - "port" : {{ .Values.naviback.grpcPort | int }}, - "max_process_time" : {{ .Values.naviback.maxProcessTime | default 20 | int }}, - "response_timelimit" : {{ .Values.naviback.responseTimelimit | default 120 | int }}, - "request_timeout" : {{ .Values.naviback.requestTimeout | default 120 | int }}, - "thread_pool_size" : {{ $grpcHandlers }} + "server": "0.0.0.0", + "port": {{ .Values.naviback.grpcPort | int }}, + "max_process_time": {{ .Values.naviback.maxProcessTime | default 20 | int }}, + "response_timelimit": {{ .Values.naviback.responseTimelimit | default 120 | int }}, + "request_timeout": {{ .Values.naviback.requestTimeout | default 120 | int }} }, {{- end }} {{- if .Values.naviback.sentry.enabled }} - "error_tracker" : { - "report_destination_address" : {{ .Values.naviback.sentry.address | quote }}, - "project_name" : {{ .Values.naviback.sentry.project | quote }}, - "user_name" : {{ .Values.naviback.sentry.username | quote }}, - "print_outgoing_messages" : {{ .Values.naviback.sentry.printMessages | default false }}, - "debug" : {{ .Values.naviback.sentry.debug | default false }}, - "path" : {{ .Values.naviback.sentry.reportPath | default "/tmp/sentry" | quote }}, - "handler" : {{ .Values.naviback.sentry.handler | default "/usr/sbin/2gis/mosesd/crashpad_handler" | quote }} + "error_tracker": { + "report_destination_address": {{ .Values.naviback.sentry.address | quote }}, + "project_name": {{ .Values.naviback.sentry.project | quote }}, + "user_name": {{ .Values.naviback.sentry.username | quote }}, + "print_outgoing_messages": {{ .Values.naviback.sentry.printMessages | default false }}, + "debug": {{ .Values.naviback.sentry.debug | default false }}, + "path": {{ .Values.naviback.sentry.reportPath | default "/tmp/sentry" | quote }}, + "handler": {{ .Values.naviback.sentry.handler | default "/usr/sbin/2gis/mosesd/crashpad_handler" | quote }} }, {{- end }} {{- if .Values.transmitter.enabled }} @@ -76,19 +68,52 @@ data: "type": {{ .Values.transmitter.type | quote }}, "host": "127.0.0.1", "port": 9999, - "response_timeout_ms": {{ .Values.transmitter.responseTimeoutMs | int }} + "timeout_limit_ms": {{ .Values.transmitter.responseTimeoutMs | int }} }, {{- end }} "context": { + {{- if .Values.naviback.validation.enabled }} + "validation": [ + { + "service_name": "ctx", + "schemas_folder": {{ .Values.naviback.validation.ctx.schemasFolder | quote }}, + "request_schema_name": {{ .Values.naviback.validation.ctx.requestSchemaName | quote }}, + "response_schema_name": {{ .Values.naviback.validation.ctx.responseSchemaName | quote }} + }, + { + "service_name": "bss", + "schemas_folder": {{ .Values.naviback.validation.bss.schemasFolder | quote }}, + "request_schema_name": {{ .Values.naviback.validation.bss.requestSchemaName | quote }}, + "response_schema_name": {{ .Values.naviback.validation.bss.responseSchemaName | quote }} + }, + { + "service_name": "distance_matrix", + "schemas_folder": {{ .Values.naviback.validation.distanceMatrix.schemasFolder | quote }}, + "request_schema_name": {{ .Values.naviback.validation.distanceMatrix.requestSchemaName | quote }}, + "response_schema_name": {{ .Values.naviback.validation.distanceMatrix.responseSchemaName | quote }} + }, + { + "service_name": "isochrone", + "schemas_folder": {{ .Values.naviback.validation.isochrone.schemasFolder | quote }}, + "request_schema_name": {{ .Values.naviback.validation.isochrone.requestSchemaName | quote }}, + "response_schema_name": {{ .Values.naviback.validation.isochrone.responseSchemaName | quote }} + } + ], + {{- end }} "variables": { "LOCAL_PATH": "/opt/castle", "LOCAL_ETC": "/etc/2gis/mosesd", + {{- if .Values.naviback.hierarchies.enabled }} + "S3_CACHE_PATH": {{ .Values.naviback.hierarchies.s3path | quote }}, + "SHORTCUT_PATH": "/tmp/hierarchies/shortcuts", + "PATCHES_PATH": "/tmp/hierarchies/patches", + {{- end }}{{- /* if .Values.naviback.hierarchies.enabled */}} "REMOTE_PATH": "{{ include "config.setCastleUrl" $ }}", - "REMOTE_FORECAST" : "{{ .Values.naviback.forecastHost }}", - "REMOTE_ECA" : "{{ include "config.setEcaUrl" $ }}" + "REMOTE_FORECAST": "{{ .Values.naviback.forecastHost }}", + "REMOTE_ECA": "{{ include "config.setEcaUrl" $ }}" }, - "rules": { - "update_period" : 0, + "rules": { + "update_period": 0, "nodes": [ "file://{LOCAL_ETC}/rules.conf" ], @@ -120,116 +145,81 @@ data: }, {{- if not (include "config.isCTX" $) }} {{- if .Values.naviback.indices.speedIndex.enabled }} - "speed_index" : - { - "update_period" : {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, - "nodes" : - [ - "{REMOTE_ECA}/traffic/moses/speeds5.json" - ], - "timeout_seconds": - { - "count": 60 - } + "speed_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, + "nodes": [ + "{REMOTE_ECA}/traffic/moses/speeds5.json" + ], + "timeout_seconds": { + "count": 60 + } }, {{- end }}{{- /* .Values.naviback.indices.speedIndex.enabled */}} - {{- if .Values.naviback.indices.forecastedSpeedsIndex.enabled }} - "forecasted_speeds_index" : - { - "update_period" : {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, - "nodes" : - [ - "http://{REMOTE_FORECAST}/index.json" - ], - "timeout_seconds": - { - "count": 30 - } + {{- if and .Values.naviback.indices.forecastedSpeedsIndex.enabled .Values.naviback.forecastHost }} + "forecasted_speeds_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, + "nodes": [ + "http://{REMOTE_FORECAST}/index.json" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.forecastedSpeedsIndex.enabled */}} - {{- if .Values.naviback.indices.forecastedSpeeds.enabled }} - "forecasted_speeds" : - { - "update_period" : 0, - "nodes" : - [ - "http://{REMOTE_FORECAST}/" - ], - "timeout_seconds": - { - "count": 30 - } + {{- if and .Values.naviback.indices.forecastedSpeeds.enabled .Values.naviback.forecastHost }} + "forecasted_speeds": { + "update_period": 0, + "nodes": [ + "http://{REMOTE_FORECAST}/" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.forecastedSpeeds.enabled */}} {{- if .Values.naviback.indices.etaCorrectionCores.enabled }} - "eta_correction_cores" : - { - "update_period" : 0, - "nodes" : - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 60 - } + "eta_correction_cores": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 + } }, {{- end }}{{- /* .Values.naviback.indices.etaCorrectionCores.enabled */}} - {{- if .Values.naviback.indices.taxiReferers.enabled }} - "taxi_referers": - { - "update_period" : 3600, - "nodes" : - [ - "{REMOTE_PATH}/options/taxi_referers.json" - ], - "timeout_seconds": - { - "count": 360 - } - }, - {{- end }}{{- /* .Values.naviback.indices.taxiReferers.enabled */}} {{- else }} {{- if .Values.naviback.indices.restrictedTransportRoutes.enabled }} - "restricted_transport_routes" : - { - "update_period" : 0, - "nodes" : - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 10 - } + "restricted_transport_routes": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 10 + } }, {{- end }}{{- /* .Values.naviback.indices.restrictedTransportRoutes.enabled */}} {{- if .Values.naviback.indices.restrictedTransportPlatforms.enabled }} - "restricted_transport_platforms" : - { - "update_period" : 0, - "nodes" : - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 10 - } + "restricted_transport_platforms": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 10 + } }, {{- end }}{{- /* .Values.naviback.indices.restrictedTransportPlatforms.enabled */}} {{- if .Values.naviback.indices.restrictedTransportIndex.enabled }} - "restricted_transport_index" : - { - "update_period" : {{ .Values.naviback.disableUpdates | ternary 604800 300 }}, - "nodes" : - [ - "{REMOTE_PATH}/restricted_transport.json.zip" - ], - "timeout_seconds": - { - "count": 10 - } + "restricted_transport_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 300 }}, + "nodes": [ + "{REMOTE_PATH}/restricted_transport.json.zip" + ], + "timeout_seconds": { + "count": 10 + } }, {{- end }}{{- /* .Values.naviback.indices.restrictedTransportIndex.enabled */}} {{- end }} @@ -297,7 +287,7 @@ data: "restrictions": { "update_period": 0, "nodes": [ - "{REMOTE_PATH}/" + "{{ include "config.setRestrictionUrl" $ }}/" ], "timeout_seconds": { "count": 30 @@ -339,207 +329,221 @@ data: }, {{- end }}{{- /* .Values.naviback.indices.speedCams.enabled */}} {{- if .Values.naviback.indices.tugcUsersIndex.enabled }} - "tugc_users_index" : - { - "update_period" : {{ .Values.naviback.disableUpdates | ternary 604800 300 }}, - "nodes" : - [ - "{REMOTE_PATH}/tugc_users.json.zip" - ], - "timeout_seconds": - { - "count": 30 - } + "tugc_users_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 300 }}, + "nodes": [ + "{REMOTE_PATH}/tugc_users.json.zip" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.tugcUsersIndex.enabled */}} {{- if .Values.naviback.indices.tugcUsers.enabled }} - "tugc_users" : - { - "update_period" : 0, - "nodes" : - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 30 - } + "tugc_users": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.tugcUsers.enabled */}} {{- if .Values.naviback.indices.tugc2gisIndex.enabled }} - "tugc_2gis_index" : - { - "update_period" : {{ .Values.naviback.disableUpdates | ternary 604800 600 }}, - "nodes" : - [ - "{REMOTE_PATH}/tugc_2gis.json.zip" - ], - "timeout_seconds": - { - "count": 30 - } + "tugc_2gis_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 600 }}, + "nodes": [ + "{REMOTE_PATH}/tugc_2gis.json.zip" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.tugc2gisIndex.enabled */}} {{- if .Values.naviback.indices.tugc2gis.enabled }} - "tugc_2gis" : - { - "update_period" : 0, - "nodes" : - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 30 - } + "tugc_2gis": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.tugc2gis.enabled */}} {{- if .Values.naviback.indices.onlineSpeeds.enabled }} - "online_speeds" : - { - "update_period" : 0, - "max_updated_time_diff_minutes" : 20, - "nodes" : - [ - "{REMOTE_ECA}/" - ], - "timeout_seconds": - { - "count": 30 - } + "online_speeds": { + "update_period": 0, + "max_updated_time_diff_minutes": 20, + "nodes": [ + "{REMOTE_ECA}/" + ], + "timeout_seconds": { + "count": 30 + } }, {{- end }}{{- /* .Values.naviback.indices.onlineSpeeds.enabled */}} {{- end }} {{- if (include "config.isTaxi" $) }} + {{- if .Values.naviback.indices.taxiReferers.enabled }} + "taxi_referers": { + "update_period": 3600, + "nodes": [ + "{REMOTE_PATH}/options/taxi_referers.json" + ], + "timeout_seconds": { + "count": 360 + } + }, + {{- end }}{{- /* .Values.naviback.indices.taxiReferers.enabled */}} {{- if .Values.naviback.indices.taxiSpeedIndex.enabled }} - "taxi_speed_index": { - "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, - "nodes": [ - "{REMOTE_ECA}/traffic/moses/speeds5.json" - ], - "timeout_seconds": { - "count": 60 - } - }, + "taxi_speed_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 20 }}, + "nodes": [ + "{REMOTE_ECA}/traffic/moses/speeds5.json" + ], + "timeout_seconds": { + "count": 60 + } + }, {{- end }}{{- /* .Values.naviback.indices.taxiSpeedIndex.enabled */}} {{- if .Values.naviback.indices.onlineTaxiSpeeds.enabled }} - "online_taxi_speeds" : - { - "update_period" : 0, - "max_updated_time_diff_minutes" : 20, - "nodes" : - [ - "{REMOTE_ECA}/" - ], - "timeout_seconds": - { - "count": 60 - } - }, + "online_taxi_speeds": { + "update_period": 0, + "max_updated_time_diff_minutes": 20, + "nodes": [ + "{REMOTE_ECA}/" + ], + "timeout_seconds": { + "count": 60 + } + }, {{- end }}{{- /* .Values.naviback.indices.onlineTaxiSpeeds.enabled */}} {{- end }} {{- if (include "config.isTruck" $) }} {{- if .Values.naviback.indices.passZones.enabled }} - "pass_zones": - { - "update_period": 0, - "nodes": - [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": - { - "count": 60 - } - }, + "pass_zones": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 + } + }, {{- end }}{{- /* .Values.naviback.indices.passZones.enabled */}} {{- end }} - "edge_transition_probability": { - "update_period": 0, - "nodes": [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": { - "count": 60 - }, - "cache_path": "file://{LOCAL_PATH}/{project_name}/edge_transition_probability.json" - }, - "turn_penalties": { - "update_period": 0, - "nodes": [ - "{REMOTE_PATH}/" - ], - "timeout_seconds": { - "count": 60 - }, - "cache_path": "file://{LOCAL_PATH}/{project_name}/turn_penalties.json" + "edge_transition_probability": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 + }, + "cache_path": "file://{LOCAL_PATH}/{project_name}/edge_transition_probability.json" }, - {{- if .Values.s3.enabled }} - "s3": { - "distance_matrix": { - "endpoint": {{ .Values.s3.host | quote }}, - "bucket": {{ .Values.s3.bucket | quote }}, - "access_key": {{ .Values.s3.accessKey | quote }}, - "secret_key": {{ .Values.s3.secretKey | quote }} - } + "turn_penalties": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 }, + "cache_path": "file://{LOCAL_PATH}/{project_name}/turn_penalties.json" + }, + {{- if .Values.naviback.indices.snImport.enabled }} + "sn_import": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 + } + }, + {{- end }}{{- /* .Values.naviback.indices.snImport.enabled */}} + {{- if .Values.naviback.indices.geoImport.enabled }} + "geo_import": { + "update_period": 0, + "nodes": [ + "{REMOTE_PATH}/" + ], + "timeout_seconds": { + "count": 60 + } + }, + {{- end }}{{- /* .Values.naviback.indices.geoImport.enabled */}} + {{- if .Values.s3.enabled }} + "s3": { + "distance_matrix": { + {{- if .Values.s3.suffix }} + "suffix": {{ .Values.s3.suffix | quote }}, + {{- end }} + "endpoint": {{ .Values.s3.host | quote }}, + "bucket": {{ .Values.s3.bucket | quote }}, + "access_key": {{ .Values.s3.accessKey | quote }}, + "secret_key": {{ .Values.s3.secretKey | quote }} + } + }, {{- end }} {{- if (include "config.isMapMatching" $) }} - "map_matching" : - { - "fmm": - { - "k": "24", - "radius": "4000", - "gps_error": "3000", - "vmax": "40", - "factor": "1.5", - "reverse_tolerance": "0.1" - } + "map_matching": { + "fmm": { + "k": "24", + "radius": "4000", + "gps_error": "3000", + "vmax": "40", + "factor": "1.5", + "reverse_tolerance": "0.1" + } }, {{- end }} {{- if .Values.kafka.enabled }} - "kafka": { - "task_group_id" : {{ .Values.kafka.groupId | quote }}, - "cancel_group_id": {{ .Values.kafka.groupId | quote }}, - "handlers_number": {{ .Values.kafka.handlersNumber }}, - {{- /* - Collect merged Kafka properties from these dictionaries: - - kafka.properties: this is a simple key/value dictionary - - kafka.fileProperties: this is a key/content dictionary given in values, - content is sensitive and stored in Secret resource, they get - mounted as files sonamed after key. While actual secret values are - hidden this way, what actually goes here in environment properties is - file names. This value substitution is implemented down here. - */ -}} - {{- $kafkaProperties := dict -}} - {{- range $key, $_ := .Values.kafka.fileProperties -}} - {{- $_ := set $kafkaProperties $key (printf "/etc/2gis/mosesd/secret/%s" $key) -}} - {{- end -}} - {{- $kafkaProperties := mustMerge $kafkaProperties .Values.kafka.properties -}} - "kafka_properties": {{ mustToPrettyJson $kafkaProperties | nindent 12 }}, - "distance_matrix": { - "task_topic": {{ .Values.kafka.distanceMatrix.taskTopic | quote }}, - "cancel_topic": {{ .Values.kafka.distanceMatrix.cancelTopic | quote }}, - "status_topic": {{ .Values.kafka.distanceMatrix.statusTopic | quote }}, - "update_task_status_period_sec": {{ .Values.kafka.distanceMatrix.updateTaskStatusPeriodSec | int }}, - "message_expired_period_sec" : {{ .Values.kafka.distanceMatrix.messageExpiredPeriodSec | int }}, - "request_download_timeout_sec" : {{ .Values.kafka.distanceMatrix.requestDownloadTimeoutSec | int }}, - "response_upload_timeout_sec": {{ .Values.kafka.distanceMatrix.responseUploadTimeoutSec | int }} - } - }, + "kafka": { + "task_group_id": {{ .Values.kafka.groupId | quote }}, + "cancel_group_id": {{ .Values.kafka.groupId | quote }}, + "handlers_number": {{ .Values.kafka.handlersNumber }}, + {{- /* + Collect merged Kafka properties from these dictionaries: + - kafka.properties: this is a simple key/value dictionary + - kafka.fileProperties: this is a key/content dictionary given in values, + content is sensitive and stored in Secret resource, they get + mounted as files sonamed after key. While actual secret values are + hidden this way, what actually goes here in environment properties is + file names. This value substitution is implemented down here. + */ -}} + {{- $kafkaProperties := dict -}} + {{- range $key, $_ := .Values.kafka.fileProperties -}} + {{- $_ := set $kafkaProperties $key (printf "/etc/2gis/mosesd/secret/%s" $key) -}} + {{- end -}} + {{- $kafkaProperties := mustMerge $kafkaProperties .Values.kafka.properties }} + "kafka_properties": + {{- mustToPrettyJson $kafkaProperties | nindent 12 -}}, + "distance_matrix": { + "task_topic": {{ .Values.kafka.distanceMatrix.taskTopic | quote }}, + "cancel_topic": {{ .Values.kafka.distanceMatrix.cancelTopic | quote }}, + "status_topic": {{ .Values.kafka.distanceMatrix.statusTopic | quote }}, + "update_task_status_period_sec": {{ .Values.kafka.distanceMatrix.updateTaskStatusPeriodSec | int }}, + "message_expired_period_sec": {{ .Values.kafka.distanceMatrix.messageExpiredPeriodSec | int }}, + "request_download_timeout_sec": {{ .Values.kafka.distanceMatrix.requestDownloadTimeoutSec | int }}, + "response_upload_timeout_sec": {{ .Values.kafka.distanceMatrix.responseUploadTimeoutSec | int }} + } + }, {{- end }} {{- if and .Values.naviback.bss.enabled .Values.naviback.bss.client.serviceRemoteAddress }} - "business_statistics_system" : { - "client" : { - "service_remote_address" : {{ .Values.naviback.bss.client.serviceRemoteAddress | mustToJson }}, - "message_count_to_flush" : {{ .Values.naviback.bss.client.messageCountToFlush | mustToJson }}, - "use_compression" : {{ .Values.naviback.bss.client.useCompression | mustToJson }}, - "package_size_max_bytes" : {{ .Values.naviback.bss.client.packageSizeMaxBytes | mustToJson }}, - "pending_transmission_max_count" : {{ .Values.naviback.bss.client.pendingTransmissionMaxCount | mustToJson }}, - "timeout_ms" : {{ .Values.naviback.bss.client.timeoutLimitMilSec | mustToJson }} - } - }, + "business_statistics_system": { + "client": { + "service_remote_address": {{ .Values.naviback.bss.client.serviceRemoteAddress | mustToJson }}, + "message_count_to_flush": {{ .Values.naviback.bss.client.messageCountToFlush | mustToJson }}, + "use_compression": {{ .Values.naviback.bss.client.useCompression | mustToJson }}, + "package_size_max_bytes": {{ .Values.naviback.bss.client.packageSizeMaxBytes | mustToJson }}, + "pending_transmission_max_count": {{ .Values.naviback.bss.client.pendingTransmissionMaxCount | mustToJson }}, + "timeout_ms": {{ .Values.naviback.bss.client.timeoutLimitMilSec | mustToJson }} + } + }, {{- end }}{{- /* .Values.naviback.bss.enabled */}} {{- if not .Values.license.notSupported }} {{- $licenseUrl := .Values.license.url | required "Valid license.url required!" }} @@ -548,7 +552,7 @@ data: {{- end }}{{- /* if not .Values.license.notSupported */}} {{- if .Values.naviback.rtr.enabled }} "restrictions_index": { - "update_period": 300, + "update_period": {{ .Values.naviback.rtr.updatePeriod | int }}, "nodes": [ "{{ .Values.naviback.rtr.url }}/restrictions_index.json.zip" ], @@ -558,43 +562,94 @@ data: "cache_path_": "file://{LOCAL_PATH}/{project_name}/restrictions_index.json.zip" }, {{- end }}{{- /* if .Values.naviback.rtr.enabled */}} + {{- if .Values.naviback.hierarchies.enabled }} + "hierarchies": { + "graphs_file_name": "{SHORTCUT_PATH}", + "patches_dir_name": "{PATCHES_PATH}" + }, + "hierarchy_shortcuts": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 600 }}, + "nodes": [ + "{S3_CACHE_PATH}/shortcuts/shortcuts.tar.gz" + ], + "timeout_seconds": { + "count": 600 + } + }, + "hierarchy_patches": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 600 }}, + "nodes": [ + "{S3_CACHE_PATH}/patches.json" + ], + "timeout_seconds": { + "count": 600 + } + }, + "sn_import": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 600 }}, + "nodes": [ + "{S3_CACHE_PATH}/sn/export_sn.tar.gz" + ], + "timeout_seconds": { + "count": 600 + } + }, + {{- end }}{{- /* if .Values.naviback.hierarchies.enabled */}} + {{- if .Values.naviback.etaScheduleIndex.enabled }} + "eta_schedule_index": { + "update_period": {{ .Values.naviback.disableUpdates | ternary 604800 10 }}, + "nodes": [ + "{{ .Values.naviback.etaScheduleIndex.url }}" + ], + "timeout_seconds": { + "count": 5 + } + }, + "eta_schedule": { + "update_period": 0, + "timeout_seconds": { + "count": 5 + } + }, + {{- end }}{{- /* if .Values.naviback.etaScheduleIndex.enabled */}} {{- if .Values.naviback.additionalSections }} {{- include "tplvalues.render" ( dict "value" .Values.naviback.additionalSections "context" $) | nindent 8 }} {{- end }} "server_info": { - "simple_network_car" : {{ include "config.setSimpleNetworkCar" $ | default false -}}, - "simple_network_pedestrian" : {{ include "config.setSimpleNetworkPedestrian" $ | default false -}}, - "simple_network_taxi" : {{ include "config.setSimpleNetworkTaxi" $ | default false -}}, - "simple_network_bicycle" : {{ include "config.setSimpleNetworkBicycle" $ | default false -}}, - "simple_network_truck" : {{ include "config.setSimpleNetworkTruck" $ | default false -}}, - "simple_network_emergency" : {{ include "config.setSimpleNetworkEmergency" $ | default false -}}, + "tiles_metrics_threshold": {{ .Values.naviback.tilesMetricsThreshold | int }}, + "simple_network_car": {{ include "config.setSimpleNetworkCar" $ | default false -}}, + "simple_network_pedestrian": {{ include "config.setSimpleNetworkPedestrian" $ | default false -}}, + "simple_network_taxi": {{ include "config.setSimpleNetworkTaxi" $ | default false -}}, + "simple_network_bicycle": {{ include "config.setSimpleNetworkBicycle" $ | default false -}}, + "simple_network_truck": {{ include "config.setSimpleNetworkTruck" $ | default false -}}, + "simple_network_emergency": {{ include "config.setSimpleNetworkEmergency" $ | default false -}}, "ctx_only": {{ include "rules.inRoutingSectionOnly" (dict "routingValue" "ctx" "context" $) -}}, - "attractor_car" : {{ include "config.setAttractorCar" $ | default false -}}, - "attractor_pedestrian" : {{ include "config.setAttractorPedestrian" $ | default false -}}, - "attractor_bicycle" : {{ include "config.setAttractorBicycle" $ | default false -}}, - "attractor_taxi" : {{ include "config.setAttractorTaxi" $ | default false -}}, - "attractor_truck" : {{ include "config.setAttractorTruck" $ | default false -}}, - "reduce_edges_optimization_flag" : {{ include "config.setReduceEdgesOptimizationFlag" $ | default false -}}, + "attractor_car": {{ include "config.setAttractorCar" $ | default false -}}, + "attractor_pedestrian": {{ include "config.setAttractorPedestrian" $ | default false -}}, + "attractor_bicycle": {{ include "config.setAttractorBicycle" $ | default false -}}, + "attractor_taxi": {{ include "config.setAttractorTaxi" $ | default false -}}, + "attractor_truck": {{ include "config.setAttractorTruck" $ | default false -}}, + "reduce_edges_optimization_flag": {{ include "config.setReduceEdgesOptimizationFlag" $ | default false -}}, {{- if ((.Values.resources).limits).cpu }} - "dist_matrix_thread_pool_size" : {{ include "config.setCpuNumber" . }}, - "simple_network_build_thread_pool_size" : {{ include "config.setCpuNumber" . }}, + "dist_matrix_thread_pool_size": {{ include "config.setCpuNumber" . }}, + "simple_network_build_thread_pool_size": {{ include "config.setCpuNumber" . }}, {{- end }} - "update_projects_limit" : 2, - "carrouting_page_cache_size" : 8192, - "carrouting_tile_cache_size" : 8192, - "carrouting_bit_tile_cache_size" : 2048, - "dump_query" : {{ mustToJson (.Values.naviback.dump).query }}, - "dump_result" : {{ mustToJson (.Values.naviback.dump).result }}, - "dump_answer" : {{ mustToJson (.Values.naviback.dump).answer }}, - "max_parallel_workers" : 2, - "use_memory_mapped_vfs" : true, - "engine_update_period_sec" : {{ include "config.setEngineUpdatePeriod" $ | default 30 }}, + "update_projects_limit": 2, + "carrouting_page_cache_size": 8192, + "carrouting_tile_cache_size": 8192, + "carrouting_bit_tile_cache_size": 2048, + "dump_query": {{ mustToJson (.Values.naviback.dump).query }}, + "dump_result": {{ mustToJson (.Values.naviback.dump).result }}, + "dump_answer": {{ mustToJson (.Values.naviback.dump).answer }}, + "max_parallel_workers": 2, + "use_memory_mapped_vfs": true, + "engine_update_period_sec": {{ include "config.setEngineUpdatePeriod" $ | default 30 }}, {{- if .Values.naviback.server_id }} - "server_id" : "{{- include "tplvalues.render" ( dict "value" .Values.naviback.server_id "context" .) }}", + "server_id": "{{- include "tplvalues.render" ( dict "value" .Values.naviback.server_id "context" .) }}", {{- else }} - "server_id" : "{{- include "naviback.fullname" . }}", + "server_id": "{{- include "generic-chart.fullname" . }}", {{- end }} - "extended_metrics": [ ], + "extended_metrics": [], "dash_colors": [ { "ratio": 2, @@ -678,6 +733,11 @@ data: prefix: "/" route: cluster: attractor + {{- if .Values.transmitter.retry.enabled }} + retry_policy: + retry_on: {{ .Values.transmitter.retry.retryOn | quote }} + num_retries: {{ .Values.transmitter.retry.numRetries | int }} + {{- end }} http_filters: - name: envoy.router typed_config: diff --git a/charts/navi-back/templates/deployment.yaml b/charts/navi-back/templates/deployment.yaml index 44a77a566..2ff5e1da3 100644 --- a/charts/navi-back/templates/deployment.yaml +++ b/charts/navi-back/templates/deployment.yaml @@ -1,13 +1,13 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: {{ include "naviback.fullname" . }} + name: {{ include "generic-chart.fullname" . }} labels: - {{- include "naviback.labels" . | nindent 4 }} + {{- include "generic-chart.labels" . | nindent 4 }} rule: {{ .Values.naviback.app_rule | default "" | quote }} navigroup: {{ .Values.navigroup | default "" | quote }} {{- if .Values.dataGroup.enabled }} - dataGroupTimestamp: {{ .Values.dataGroup.timestamp | quote }} + dataGroupTimestamp: {{ .Values.dataGroup.timestamp | int | quote }} dataGroupPrefix: {{ .Values.dataGroup.prefix | quote }} {{- end }}{{- /* dataGroup.enabled */}} {{- with .Values.labels }} @@ -24,20 +24,20 @@ spec: {{- end }} selector: matchLabels: - {{- include "naviback.selectorLabels" . | nindent 6 }} + {{- include "generic-chart.selectorLabels" . | nindent 6 }} template: metadata: annotations: - checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - checksum/secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} + checksum/config: {{ (include (print $.Template.BasePath "/configmap.yaml") . | fromYaml).data | toYaml | sha256sum }} + checksum/secret: {{ (include (print $.Template.BasePath "/secret.yaml") . | fromYaml).data | toYaml | sha256sum }} {{- with .Values.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }} labels: - {{- include "naviback.selectorLabels" . | nindent 8 }} + {{- include "generic-chart.selectorLabels" . | nindent 8 }} navigroup: {{ .Values.navigroup | default "" | quote }} {{- if .Values.dataGroup.enabled }} - dataGroupTimestamp: {{ .Values.dataGroup.timestamp | quote }} + dataGroupTimestamp: {{ .Values.dataGroup.timestamp | int | quote }} dataGroupPrefix: {{ .Values.dataGroup.prefix | quote }} {{- end }} spec: @@ -45,53 +45,46 @@ spec: imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} - serviceAccountName: {{ include "naviback.serviceAccountName" . }} + serviceAccountName: {{ include "generic-chart.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} volumes: - - name: {{ include "naviback.fullname" . }}-configmap + - name: {{ include "generic-chart.fullname" . }}-configmap configMap: - name: {{ include "naviback.fullname" . }}-configmap + name: {{ include "generic-chart.fullname" . }}-configmap {{- if .Values.kafka.fileProperties }} - - name: {{ include "naviback.fullname" . }}-secret + - name: {{ include "generic-chart.fullname" . }}-secret secret: - secretName: {{ include "naviback.fullname" . }}-secret + secretName: {{ include "generic-chart.fullname" . }}-secret {{- end }} {{- if .Values.naviback.sentry.enabled }} - name: sentry-volume emptyDir: {} {{- end }} - {{- if .Values.frozenData.enabled }} - - name: frozen-data + {{- if .Values.naviback.hierarchies.enabled }} + - name: hierarchies-volume emptyDir: {} {{- end }} + {{- if .Values.extraVolumes }} + {{- include "tplvalues.render" (dict "value" .Values.extraVolumes "context" $) | nindent 6 }} + {{- end }} {{- if .Values.priorityClassName }} priorityClassName: {{ .Values.priorityClassName }} {{- end }} - {{- if .Values.frozenData.enabled }} + {{- if .Values.initContainers }} initContainers: - - name: frozen-data - securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} - image: {{ required "A valid .Values.dgctlDockerRegistry entry required" .Values.dgctlDockerRegistry }}/{{ .Values.frozenData.image.repository }}:{{ .Values.frozenData.image.tag }} - command: ['sh', '-ec', 'cp -r /frozen_data_init/* /opt/castle; ls -l /opt/castle'] - imagePullPolicy: {{ .Values.frozenData.pullPolicy }} - {{- if (.Values.frozenData).resources }} - resources: {{- toYaml .Values.frozenData.resources | nindent 12 }} - {{- end }} - volumeMounts: - - name: frozen-data - mountPath: /opt/castle + {{- include "tplvalues.render" (dict "value" .Values.initContainers "context" $) | nindent 8 }} {{- end }} containers: {{- if .Values.transmitter.enabled }} - - name: {{ include "naviback.containerName" . }}-envoy +{{- /* generic-chart.containerName redefined in _helpers.tpl */}} + - name: {{ include "generic-chart.containerName" . }}-envoy securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: {{ required "A valid .Values.dgctlDockerRegistry entry required" .Values.dgctlDockerRegistry }}/{{ .Values.envoy.image.repository }}:{{ .Values.envoy.image.tag }} imagePullPolicy: {{ .Values.envoy.image.pullPolicy }} volumeMounts: - - name: {{ include "naviback.fullname" . }}-configmap + - name: {{ include "generic-chart.fullname" . }}-configmap mountPath: /etc/envoy/envoy.yaml subPath: envoy.yaml {{- if (.Values.envoy).resources }} @@ -153,34 +146,48 @@ spec: resources: {{- toYaml .Values.metrics.resources | nindent 12 }} {{- end }} - - name: {{ include "naviback.containerName" . }} +{{- /* generic-chart.containerName redefined in _helpers.tpl */}} + - name: {{ include "generic-chart.containerName" . }} securityContext: {{- toYaml .Values.securityContext | nindent 12 }} image: {{ required "A valid .Values.dgctlDockerRegistry entry required" .Values.dgctlDockerRegistry }}/{{ .Values.image.repository }}:{{ .Values.image.tag }} imagePullPolicy: {{ .Values.image.pullPolicy }} + {{- if .Values.command }} + command: + {{- include "tplvalues.render" (dict "value" .Values.command "context" $) | nindent 12 }} + {{- else }} command: [ "/usr/sbin/2gis/mosesd/tini", "--" ] + {{- end }} + {{- if .Values.args }} + args: + {{- include "tplvalues.render" (dict "value" .Values.args "context" $) | nindent 12 }} + {{- else }} args: - - /usr/sbin/2gis/mosesd/mosesd - - --config - - /etc/2gis/mosesd/navi-back.conf + - /usr/sbin/2gis/mosesd/mosesd + - --config + - /etc/2gis/mosesd/navi-back.conf + {{- end }} volumeMounts: - - name: {{ include "naviback.fullname" . }}-configmap + - name: {{ include "generic-chart.fullname" . }}-configmap mountPath: /etc/2gis/mosesd/navi-back.conf subPath: navi-back.conf - - name: {{ include "naviback.fullname" . }}-configmap + - name: {{ include "generic-chart.fullname" . }}-configmap mountPath: /etc/2gis/mosesd/rules.conf subPath: rules.conf {{- if .Values.kafka.fileProperties }} - - name: {{ include "naviback.fullname" . }}-secret + - name: {{ include "generic-chart.fullname" . }}-secret mountPath: /etc/2gis/mosesd/secret/ {{- end }} {{- if .Values.naviback.sentry.enabled }} - name: sentry-volume mountPath: {{ .Values.naviback.sentry.reportPath | default "/tmp/sentry" | quote }} {{- end }} - {{- if .Values.frozenData.enabled }} - - name: frozen-data - mountPath: /opt/castle + {{- if .Values.naviback.hierarchies.enabled }} + - name: hierarchies-volume + mountPath: "/tmp/hierarchies" + {{- end }} + {{- if .Values.extraVolumeMounts }} + {{- include "tplvalues.render" (dict "value" .Values.extraVolumeMounts "context" $) | nindent 10 }} {{- end }} ports: - name: http @@ -191,26 +198,48 @@ spec: containerPort: {{ .Values.naviback.grpcPort }} protocol: TCP {{- end }} + {{- if .Values.customStartupProbe }} + startupProbe: + {{- include "tplvalues.render" (dict "value" .Values.customStartupProbe "context" $) | nindent 12 }} + {{- else if .Values.startupProbe.enabled }} startupProbe: httpGet: path: /successfulwork port: http - periodSeconds: 5 - failureThreshold: 360 + initialDelaySeconds: {{ .Values.startupProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.startupProbe.periodSeconds }} + timeoutSeconds: {{ .Values.startupProbe.timeoutSeconds }} + successThreshold: {{ .Values.startupProbe.successThreshold }} + failureThreshold: {{ .Values.startupProbe.failureThreshold }} + {{- end }} + {{- if .Values.customLivenessProbe }} + livenessProbe: + {{- include "tplvalues.render" (dict "value" .Values.customLivenessProbe "context" $) | nindent 12 }} + {{- else if .Values.startupProbe.enabled }} livenessProbe: httpGet: path: /heartbeat port: http - periodSeconds: 5 - timeoutSeconds: 3 - failureThreshold: 2 + initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.livenessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} + successThreshold: {{ .Values.livenessProbe.successThreshold }} + failureThreshold: {{ .Values.livenessProbe.failureThreshold }} + {{- end }} + {{- if .Values.customReadinessProbe }} + readinessProbe: + {{- include "tplvalues.render" (dict "value" .Values.customReadinessProbe "context" $) | nindent 12 }} + {{- else if .Values.readinessProbe.enabled }} readinessProbe: httpGet: path: /successfulwork port: http - periodSeconds: 5 - timeoutSeconds: 3 - failureThreshold: 2 + initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.readinessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} + successThreshold: {{ .Values.readinessProbe.successThreshold }} + failureThreshold: {{ .Values.readinessProbe.failureThreshold }} + {{- end }} resources: {{- toYaml .Values.resources | nindent 12 }} env: @@ -223,6 +252,9 @@ spec: preStop: exec: command: ["/bin/sh", "-c", "sleep {{ .Values.preStopDelay | default 5 | int }}"] + {{- if .Values.sidecars }} + {{- include "tplvalues.render" (dict "value" .Values.sidecars "context" $) | nindent 8 }} + {{- end }} terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds | default 60 }} {{- with .Values.nodeSelector }} nodeSelector: diff --git a/charts/navi-back/templates/hpa.yaml b/charts/navi-back/templates/hpa.yaml index 09de7f099..41e1e392d 100644 --- a/charts/navi-back/templates/hpa.yaml +++ b/charts/navi-back/templates/hpa.yaml @@ -1,39 +1 @@ -{{- if .Values.hpa.enabled }} -apiVersion: {{ include "capabilities.hpa.apiVersion" $ }} -kind: HorizontalPodAutoscaler -metadata: - name: {{ include "naviback.fullname" . }} - labels: - {{- include "naviback.labels" . | nindent 4 }} -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: {{ include "naviback.fullname" . }} - minReplicas: {{ .Values.hpa.minReplicas }} - maxReplicas: {{ .Values.hpa.maxReplicas }} - behavior: - {{- if .Values.hpa.scaleUp }} - scaleUp: - {{- include "tplvalues.render" ( dict "value" .Values.hpa.scaleUp "context" $) | nindent 8 }} - {{- end }} - {{- if .Values.hpa.scaleDown }} - scaleDown: - {{- include "tplvalues.render" ( dict "value" .Values.hpa.scaleDown "context" $) | nindent 8 }} - {{- end }} - metrics: - {{- if .Values.hpa.targetCPUUtilizationPercentage }} - - type: Resource - resource: - name: cpu - target: - type: Utilization - averageUtilization: {{ .Values.hpa.targetCPUUtilizationPercentage }} - {{- end }} - {{- if .Values.hpa.targetMemoryUtilizationPercentage }} - - type: Resource - resource: - name: memory - targetAverageUtilization: {{ .Values.hpa.targetMemoryUtilizationPercentage }} - {{- end }} -{{- end }} +{{- template "generic-chart.hpa.tpl" . }} diff --git a/charts/navi-back/templates/ingress.yaml b/charts/navi-back/templates/ingress.yaml index d8706758e..8604b0c34 100644 --- a/charts/navi-back/templates/ingress.yaml +++ b/charts/navi-back/templates/ingress.yaml @@ -1,5 +1,5 @@ {{- if .Values.ingress.enabled -}} -{{- $fullName := include "naviback.fullname" . -}} +{{- $fullName := include "generic-chart.fullname" . -}} {{- $svcPort := .Values.service.port -}} {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} @@ -17,7 +17,7 @@ kind: Ingress metadata: name: {{ $fullName }} labels: - {{- include "naviback.labels" . | nindent 4 }} + {{- include "generic-chart.labels" . | nindent 4 }} {{- with .Values.ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/charts/navi-back/templates/pdb.yaml b/charts/navi-back/templates/pdb.yaml index e51715299..824f66d70 100644 --- a/charts/navi-back/templates/pdb.yaml +++ b/charts/navi-back/templates/pdb.yaml @@ -1,21 +1 @@ -{{- with .Values.pdb }} -{{- if .enabled }} ---- -apiVersion: policy/v1 -kind: PodDisruptionBudget -metadata: - name: {{ include "naviback.fullname" $ }} - labels: - {{- include "naviback.labels" $ | nindent 4 }} -spec: - {{- if .minAvailable }} - minAvailable: {{ .minAvailable }} - {{- end }} - {{- if .maxUnavailable }} - maxUnavailable: {{ .maxUnavailable }} - {{- end }} - selector: - matchLabels: - {{- include "naviback.selectorLabels" $ | nindent 6 }} -{{- end }} -{{- end }} +{{- template "generic-chart.pdb.tpl" . }} diff --git a/charts/navi-back/templates/secret.yaml b/charts/navi-back/templates/secret.yaml index f3f376287..22e2f7c0e 100644 --- a/charts/navi-back/templates/secret.yaml +++ b/charts/navi-back/templates/secret.yaml @@ -2,9 +2,9 @@ apiVersion: v1 kind: Secret metadata: - name: {{ include "naviback.fullname" . }}-secret + name: {{ include "generic-chart.fullname" . }}-secret labels: - {{- include "naviback.labels" . | nindent 4 }} + {{- include "generic-chart.labels" . | nindent 4 }} {{- if .Values.labels }} {{- toYaml .Values.labels | nindent 4 }} {{- end }} diff --git a/charts/navi-back/templates/service.yaml b/charts/navi-back/templates/service.yaml index 1b3d93aff..4947c886e 100644 --- a/charts/navi-back/templates/service.yaml +++ b/charts/navi-back/templates/service.yaml @@ -2,9 +2,9 @@ apiVersion: v1 kind: Service metadata: - name: {{ include "naviback.fullname" . }} + name: {{ include "generic-chart.fullname" . }} labels: - {{- include "naviback.labels" . | nindent 4 }} + {{- include "generic-chart.labels" . | nindent 4 }} {{- if .Values.service.labels }} {{- include "tplvalues.render" ( dict "value" .Values.service.labels "context" $) | nindent 4 }} {{- end }} @@ -12,7 +12,7 @@ metadata: navigroup: {{ .Values.navigroup | default "" | quote }} type: {{ .Values.naviback.type | default "" | quote }} {{- if .Values.dataGroup.enabled }} - dataGroupTimestamp: {{ .Values.dataGroup.timestamp | quote }} + dataGroupTimestamp: {{ .Values.dataGroup.timestamp | int | quote }} dataGroupPrefix: {{ .Values.dataGroup.prefix | quote }} {{- end }} {{- if .Values.naviback.behindSplitter }} @@ -39,16 +39,19 @@ spec: protocol: TCP name: grpc {{- end }} + {{- if .Values.service.extraPorts }} + {{- include "tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} + {{- end }} selector: - {{- include "naviback.selectorLabels" . | nindent 4 }} + {{- include "generic-chart.selectorLabels" . | nindent 4 }} {{- if .Values.service.headless.enabled }} --- apiVersion: v1 kind: Service metadata: - name: {{ include "naviback.fullname" . }}-headless + name: {{ include "generic-chart.fullname" . }}-headless labels: - {{- include "naviback.labels" . | nindent 4 }} + {{- include "generic-chart.labels" . | nindent 4 }} {{- if .Values.service.headless.labels }} {{- include "tplvalues.render" ( dict "value" .Values.service.labels "context" $) | nindent 4 }} {{- end }} @@ -56,7 +59,7 @@ metadata: navigroup: {{ .Values.navigroup | default "" | quote }} type: {{ .Values.naviback.type | default "" | quote }} {{- if .Values.dataGroup.enabled }} - dataGroupTimestamp: {{ .Values.dataGroup.timestamp | quote }} + dataGroupTimestamp: {{ .Values.dataGroup.timestamp | int | quote }} dataGroupPrefix: {{ .Values.dataGroup.prefix | quote }} {{- end }} {{- /* pretend to be behind splitter to get ignored by mfront */}} @@ -81,5 +84,5 @@ spec: name: grpc {{- end }} selector: - {{- include "naviback.selectorLabels" . | nindent 4 }} + {{- include "generic-chart.selectorLabels" . | nindent 4 }} {{- end }} diff --git a/charts/navi-back/templates/serviceaccount.yaml b/charts/navi-back/templates/serviceaccount.yaml index 2854df970..7109eec48 100644 --- a/charts/navi-back/templates/serviceaccount.yaml +++ b/charts/navi-back/templates/serviceaccount.yaml @@ -1,12 +1 @@ -{{- if .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "naviback.serviceAccountName" . }} - labels: - {{- include "naviback.labels" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} +{{- template "generic-chart.serviceaccount.tpl" . }} diff --git a/charts/navi-back/templates/vpa.yaml b/charts/navi-back/templates/vpa.yaml index b73202472..5de5ca28e 100644 --- a/charts/navi-back/templates/vpa.yaml +++ b/charts/navi-back/templates/vpa.yaml @@ -1,35 +1 @@ -{{ with .Values.vpa }} -{{- if .enabled }} ---- - -apiVersion: autoscaling.k8s.io/v1 -kind: VerticalPodAutoscaler -metadata: - name: {{ include "naviback.fullname" $ }} - labels: - {{- include "naviback.labels" $ | nindent 4 }} -spec: - targetRef: - apiVersion: apps/v1 - kind: Deployment - name: {{ include "naviback.fullname" $ }} - updatePolicy: - updateMode: {{ default "Auto" .updateMode }} - resourcePolicy: - containerPolicies: - - containerName: {{ include "naviback.containerName" $ }} - mode: Auto - {{- with .minAllowed }} - minAllowed: - {{- toYaml . | nindent 10 }} - {{- end }} - {{- with .maxAllowed }} - maxAllowed: - {{- toYaml . | nindent 10 }} - {{- end }} - {{- if $.Values.transmitter.enabled }} - - containerName: {{ include "naviback.containerName" $ }}-envoy - mode: "Off" - {{- end }} -{{- end }} -{{- end }} +{{- template "generic-chart.vpa.tpl" . }} diff --git a/charts/navi-back/values.yaml b/charts/navi-back/values.yaml index e126cc70c..baa7949a5 100644 --- a/charts/navi-back/values.yaml +++ b/charts/navi-back/values.yaml @@ -1,27 +1,54 @@ # @section Docker Registry settings -# @param dgctlDockerRegistry Docker Registry endpoint where On-Premise services' images reside. Format: `host:port`. +# @param dgctlDockerRegistry Docker Registry endpoint where On-Premise services' images reside. Format: `host:port` dgctlDockerRegistry: '' # @section Common settings -# @param replicaCount A replica count for the pod. +# @param replicaCount A replica count for the pod # @param revisionHistoryLimit Number of replica sets to keep for deployment rollbacks -# @param imagePullSecrets Kubernetes image pull secrets. -# @param nameOverride Base name to use in all the Kubernetes entities deployed by this chart. -# @param fullnameOverride Base fullname to use in all the Kubernetes entities deployed by this chart. -# @param podAnnotations Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/). -# @param podSecurityContext Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/). -# @param securityContext Kubernetes [security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/). -# @param nodeSelector Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector). -# @param tolerations Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings. -# @param affinity Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity). -# @param labels Custom labels to set to Deployment resource. -# @param priorityClassName Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name. -# @param preStopDelay Delay in seconds before terminating container. -# @param terminationGracePeriodSeconds Maximum time allowed for graceful shutdown. +# @param imagePullSecrets Kubernetes image pull secrets +# @param nameOverride Base name to use in all the Kubernetes entities deployed by this chart +# @param fullnameOverride Base fullname to use in all the Kubernetes entities deployed by this chart +# @param podAnnotations Kubernetes [pod annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) +# @param podSecurityContext Kubernetes [pod security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) +# @param securityContext Kubernetes [security context](https://kubernetes.io/docs/tasks/configure-pod-container/security-context/) +# @param nodeSelector Kubernetes [node selectors](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) +# @param tolerations Kubernetes [tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) settings +# @param affinity Kubernetes pod [affinity settings](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity) +# @param labels Custom labels to set to Deployment resource +# @param priorityClassName Kubernetes [Pod Priority](https://kubernetes.io/docs/concepts/scheduling-eviction/pod-priority-preemption/#priorityclass) class name +# @param preStopDelay Delay in seconds before terminating container +# @param terminationGracePeriodSeconds Maximum time allowed for graceful shutdown +# @param extraVolumes Optionally specify extra list of additional volumes +# @param extraVolumeMounts Optionally specify extra list of additional volumeMounts +# @param initContainers Add additional init containers +# @param sidecars Add additional sidecar containers +# @param livenessProbe.enabled Enable livenessProbe +# @param livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe +# @param livenessProbe.periodSeconds Period seconds for livenessProbe +# @param livenessProbe.timeoutSeconds Timeout seconds for livenessProbe +# @param livenessProbe.failureThreshold Failure threshold for livenessProbe +# @param livenessProbe.successThreshold Success threshold for livenessProbe +# @param readinessProbe.enabled Enable readinessProbe +# @param readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe +# @param readinessProbe.periodSeconds Period seconds for readinessProbe +# @param readinessProbe.timeoutSeconds Timeout seconds for readinessProbe +# @param readinessProbe.failureThreshold Failure threshold for readinessProbe +# @param readinessProbe.successThreshold Success threshold for readinessProbe +# @param startupProbe.enabled Enable startupProbe +# @param startupProbe.initialDelaySeconds Initial delay seconds for startupProbe +# @param startupProbe.periodSeconds Period seconds for startupProbe +# @param startupProbe.timeoutSeconds Timeout seconds for startupProbe +# @param startupProbe.failureThreshold Failure threshold for startupProbe +# @param startupProbe.successThreshold Success threshold for startupProbe +# @param customLivenessProbe Override default liveness probe +# @param customReadinessProbe Override default readiness probe +# @param customStartupProbe Override default startup probe +# @param command Override default command +# @param args Override default args replicaCount: 1 revisionHistoryLimit: 1 @@ -38,9 +65,39 @@ labels: {} priorityClassName: '' preStopDelay: 5 terminationGracePeriodSeconds: 60 - - -# @section Deployment settings +extraVolumes: [] +extraVolumeMounts: [] +initContainers: [] +sidecars: [] +livenessProbe: + enabled: true + initialDelaySeconds: 0 + periodSeconds: 5 + timeoutSeconds: 3 + failureThreshold: 2 + successThreshold: 1 +readinessProbe: + enabled: true + initialDelaySeconds: 0 + periodSeconds: 5 + timeoutSeconds: 3 + failureThreshold: 2 + successThreshold: 1 +startupProbe: + enabled: true + initialDelaySeconds: 0 + periodSeconds: 5 + failureThreshold: 360 + timeoutSeconds: 5 + successThreshold: 1 +customLivenessProbe: {} +customReadinessProbe: {} +customStartupProbe: {} +command: [] +args: [] + + +# @section Container image settings # @param image.repository Repository # @param image.tag Tag @@ -49,30 +106,31 @@ terminationGracePeriodSeconds: 60 image: repository: 2gis-on-premise/navi-back pullPolicy: IfNotPresent - tag: 7.15.2.4 + tag: 7.23.0.5 # @section Navi-Back application settings -# @extra naviback.ecaHost DEPRECATED: Use naviback.ecaUrl. Domain name of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. -# @extra naviback.ecaUrl URL of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. -# @extra naviback.forecastHost URL of Traffic forecast service. See the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster. +# @extra naviback.ecaHost DEPRECATED: Use naviback.ecaUrl. Domain name of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster +# @extra naviback.ecaUrl URL of the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster +# @extra naviback.forecastHost URL of Traffic forecast service. See the [Traffic Proxy service](https://docs.2gis.com/en/on-premise/traffic-proxy).
This URL should be accessible from all the pods within your Kubernetes cluster # @skip naviback.appPort -# @param naviback.dmSourcesLimit Size limit for source matrices. -# @param naviback.dmTargetsLimit Size limit for target matrices. -# @param naviback.handlersNumber Number of HTTP handlers. -# @param naviback.maxProcessTime Maximum processing time limit in minutes. -# @param naviback.responseTimelimit Maximum response time limit in minutes. -# @param naviback.requestTimeout Maximum request time limit in minutes. -# @param naviback.timeoutLimitSec Maximum downloading time can be reached after failures. -# @param naviback.timeoutIncrementSec Downloading time increment after failures. -# @param naviback.totalRetryDurationSec Downloading timeout with all failure retries. -# @param naviback.initialRetryIntervalSec Initial timeout for a failure retry. -# @param naviback.dump.result Dump results in logs. -# @param naviback.dump.query Dump queries in logs. -# @param naviback.dump.answer Dump answers in logs. -# @param naviback.logLevel Logging level, one of: Verbose, Info, Warning, Error, Fatal. -# @param naviback.indexFilename Name of index file. +# @param naviback.dmSourcesLimit Size limit for source matrices +# @param naviback.dmTargetsLimit Size limit for target matrices +# @param naviback.handlersNumber Total number of HTTP/GRPC handlers +# @param naviback.queueSize Internal queue size +# @param naviback.maxProcessTime Maximum processing time limit in minutes +# @param naviback.responseTimelimit Maximum response time limit in minutes +# @param naviback.requestTimeout Maximum request time limit in minutes +# @param naviback.timeoutLimitSec Maximum downloading time can be reached after failures +# @param naviback.timeoutIncrementSec Downloading time increment after failures +# @param naviback.totalRetryDurationSec Downloading timeout with all failure retries +# @param naviback.initialRetryIntervalSec Initial timeout for a failure retry +# @param naviback.dump.result Dump results in logs +# @param naviback.dump.query Dump queries in logs +# @param naviback.dump.answer Dump answers in logs +# @param naviback.logLevel Logging level, one of: Verbose, Info, Warning, Error, Fatal +# @param naviback.indexFilename Name of the index file on Castle # @param naviback.citiesFilename Name of the cities file on Castle # @param naviback.sentry.enabled If sending crash dumps to Sentry needed # @param naviback.sentry.address Sentry URL @@ -82,11 +140,12 @@ image: # @param naviback.sentry.debug Debugging switch # @param naviback.sentry.reportPath Local directory to dump # @param naviback.sentry.handler Handler file location -# @param naviback.castleHost URL of Navi-Castle service, ex: http://navi-castle.svc.
This URL should be accessible from all the pods within your Kubernetes cluster. -# @extra naviback.enablePassableBarriers Consider passable barriers. -# @extra naviback.grpcPort GRPC port to serve. Disabled if empty. +# @extra naviback.castleHost DEPRECATED: Use naviback.castleUrl. Domain name of Navi-Castle service.
This URL should be accessible from all the pods within your Kubernetes cluster +# @param naviback.castleUrl URL of Navi-Castle service.
This URL should be accessible from all the pods within your Kubernetes cluster +# @extra naviback.enablePassableBarriers Consider passable barriers +# @extra naviback.grpcPort GRPC port to serve. Disabled if empty # @param naviback.disableUpdates Test switch for disabling runtime background updates -# @extra naviback.indices List of dynamic indices kill switches. +# @extra naviback.indices List of dynamic indices kill switches # @skip naviback.indices.carOptions.enabled # @skip naviback.indices.carOptions.filename # @skip naviback.indices.countryCarOptions.enabled @@ -95,6 +154,7 @@ image: # @skip naviback.indices.etaCorrectionCores.enabled # @skip naviback.indices.forecastedSpeeds.enabled # @skip naviback.indices.forecastedSpeedsIndex.enabled +# @skip naviback.indices.geoImport.enabled # @skip naviback.indices.onlineSpeeds.enabled # @skip naviback.indices.onlineTaxiSpeeds.enabled # @skip naviback.indices.passZones.enabled @@ -103,6 +163,7 @@ image: # @skip naviback.indices.restrictedTransportPlatforms.enabled # @skip naviback.indices.restrictedTransportRoutes.enabled # @skip naviback.indices.smatrix.enabled +# @skip naviback.indices.snImport.enabled # @skip naviback.indices.speedCams.enabled # @skip naviback.indices.speedIndex.enabled # @skip naviback.indices.taxiReferers.enabled @@ -111,10 +172,11 @@ image: # @skip naviback.indices.tugc2gisIndex.enabled # @skip naviback.indices.tugcUsers.enabled # @skip naviback.indices.tugcUsersIndex.enabled -# @extra naviback.additionalSections Optinal JSON block to be added to config file as-is. +# @extra naviback.additionalSections Optinal JSON block to be added to config file as-is +# @skip naviback.simpleNetwork # @extra naviback.simpleNetwork.bicycle Enable simple network for bicycle routing # @extra naviback.simpleNetwork.car Enable simple network for auto routing -# @param naviback.simpleNetwork.emergency Enable simple network for emergency vehicles routing +# @extra naviback.simpleNetwork.emergency Enable simple network for emergency vehicles routing # @extra naviback.simpleNetwork.pedestrian Enable simple network for pedestrian routing # @extra naviback.simpleNetwork.taxi Enable simple network for taxi routing # @extra naviback.simpleNetwork.truck Enable simple network for truck routing @@ -127,16 +189,36 @@ image: # @extra naviback.attractor.truck Enable enhanced attractor for truck routing # @extra naviback.attractor.scooter Enable enhanced attractor for scooters routing # @param naviback.bss.enabled Enable sending information on the construction of routes to the business statistics service -# @param naviback.bss.client.serviceRemoteAddress Remote address business statistics service. Requeruired for enable sending information. -# @param naviback.bss.client.messageCountToFlush Message count to flush. -# @param naviback.bss.client.useCompression Enable compression. -# @param naviback.bss.client.packageSizeMaxBytes Package size max bytes. -# @param naviback.bss.client.pendingTransmissionMaxCount Pending transmission max count. +# @param naviback.bss.client.serviceRemoteAddress Remote address business statistics service. Requeruired for enable sending information +# @param naviback.bss.client.messageCountToFlush Message count to flush +# @param naviback.bss.client.useCompression Enable compression +# @param naviback.bss.client.packageSizeMaxBytes Package size max bytes +# @param naviback.bss.client.pendingTransmissionMaxCount Pending transmission max count +# @param naviback.bss.client.timeoutLimitMilSec Maximum request time limit in milliseconds # @extra naviback.reduceEdgesOptimizationFlag Enable optimizations for distance matrix queries processing -# @param naviback.behindSplitter Current instance is behind splitter or not -# @param naviback.overrideConfig Complete config override. For test purposes only. -# @param naviback.rtr.enabled Enable real time restrictions. -# @param naviback.rtr.url URL real time restrictions server. +# @param naviback.behindSplitter The current instance is behind splitter or not +# @param naviback.overrideConfig Complete config override. For test purposes only +# @param naviback.rtr.enabled Enable real time restrictions +# @param naviback.rtr.url URL real time restrictions server +# @param naviback.rtr.updatePeriod Update period from real time restrictions server +# @param naviback.validation.enabled Enable validation responses and requests (used for internal tests) +# @param naviback.validation.ctx.schemasFolder Path to folder with ctx JSON schemas +# @param naviback.validation.ctx.requestSchemaName Name of ctx request validation schema +# @param naviback.validation.ctx.responseSchemaName Name of ctx response validation schema +# @param naviback.validation.bss.schemasFolder Path to folder with bss JSON schemas +# @param naviback.validation.bss.requestSchemaName Name of bss request validation schema +# @param naviback.validation.bss.responseSchemaName Name of bss response validation schema +# @param naviback.validation.distanceMatrix.schemasFolder Path to folder with distance matrix JSON schemas +# @param naviback.validation.distanceMatrix.requestSchemaName Name of distance matrix request validation schema +# @param naviback.validation.distanceMatrix.responseSchemaName Name of distance matrix response validation schema +# @param naviback.validation.isochrone.schemasFolder Path to folder with isochrone JSON schemas +# @param naviback.validation.isochrone.requestSchemaName Name of isochrone request validation schema +# @param naviback.validation.isochrone.responseSchemaName Name of isochrone response validation schema +# @param naviback.tilesMetricsThreshold The value at which we send tiles metrics (used for internal tests) +# @param naviback.hierarchies.enabled If hierarchies cache available +# @param naviback.hierarchies.s3path Hierarchies cache remote location +# @param naviback.etaScheduleIndex.enabled If Schedule Index available +# @param naviback.etaScheduleIndex.url Schedule Index remote url # @skip rules naviback: @@ -144,9 +226,10 @@ naviback: dmSourcesLimit: 1000 dmTargetsLimit: 1000 handlersNumber: 1 - maxProcessTime: 600 - responseTimelimit: 60 - requestTimeout: 60 + queueSize: 128 + maxProcessTime: 20 + responseTimelimit: 120 + requestTimeout: 120 timeoutLimitSec: 1200 timeoutIncrementSec: 140 totalRetryDurationSec: 2400 @@ -160,14 +243,14 @@ naviback: citiesFilename: cities.conf.zip sentry: enabled: false - address: sentry.host + address: sentry.local project: navi-back - username: navi-back + username: navi printMessages: false debug: false reportPath: /tmp/sentry handler: /usr/sbin/2gis/mosesd/crashpad_handler - castleHost: '' + castleUrl: '' disableUpdates: false indices: carOptions: @@ -185,6 +268,8 @@ naviback: enabled: false forecastedSpeedsIndex: enabled: false + geoImport: + enabled: false onlineSpeeds: enabled: false onlineTaxiSpeeds: @@ -201,6 +286,8 @@ naviback: enabled: false smatrix: enabled: false + snImport: + enabled: false speedCams: enabled: false speedIndex: @@ -228,11 +315,38 @@ naviback: useCompression: true packageSizeMaxBytes: 1800000 pendingTransmissionMaxCount: 10 + timeoutLimitMilSec: 5000 behindSplitter: false overrideConfig: '' rtr: enabled: false - url: http://rtr.navi + url: http://rtr + updatePeriod: 60 + validation: + enabled: false + ctx: + schemasFolder: /usr/share/2gis/schemas/nsr_schemas + requestSchemaName: CTXRequestModel.json + responseSchemaName: CTXResponseModelV4.json + bss: + schemasFolder: /usr/share/2gis/schemas/bss_schemas + requestSchemaName: '' + responseSchemaName: 401.schema.json + distanceMatrix: + schemasFolder: /usr/share/2gis/schemas/nsr_schemas + requestSchemaName: DistanceMatrixRequestModel.json + responseSchemaName: DistanceMatrixResponseModel.json + isochrone: + schemasFolder: /usr/share/2gis/schemas/nsr_schemas + requestSchemaName: IsochroneApiRequestModel.json + responseSchemaName: IsochroneApiResponseModel.json + tilesMetricsThreshold: 0 + hierarchies: + enabled: false + s3path: '' + etaScheduleIndex: + enabled: false + url: '' rules: [] @@ -242,40 +356,25 @@ rules: [] # @param envoy.image.repository Repository # @param envoy.image.tag Tag # @param envoy.image.pullPolicy Pull Policy +# @param envoy.resources [nullable] Container resources requirements structure +# @param envoy.resources.requests.cpu [nullable] CPU request, recommended value `100m` +# @param envoy.resources.requests.memory [nullable] Memory request, recommended value `100Mi` +# @param envoy.resources.limits.cpu [nullable] CPU limit, recommended value `100m` +# @param envoy.resources.limits.memory [nullable] Memory limit, recommended value `100Mi` envoy: image: repository: 2gis-on-premise/envoy pullPolicy: IfNotPresent tag: v1.27.0 - - -# @section Frozen data settings. For test purposes only. - -# @param frozenData.enabled If use frozen data is enabled. -# @param frozenData.image.repository Repository -# @param frozenData.image.tag Tag -# @param frozenData.image.pullPolicy Pull Policy -# @param frozenData.resources [nullable] Container resources requirements structure. -# @param frozenData.resources.requests.cpu [nullable] CPU request, recommended value `100m`. -# @param frozenData.resources.requests.memory [nullable] Memory request, recommended value `100Mi`. -# @param frozenData.resources.limits.cpu [nullable] CPU limit, recommended value `100m`. -# @param frozenData.resources.limits.memory [nullable] Memory limit, recommended value `100Mi`. - -frozenData: - enabled: false - image: - repository: 2gis-on-premise/frozen-data - pullPolicy: Always - tag: '' resources: {} # @section Service account settings -# @param serviceAccount.create Specifies whether a service account should be created. -# @param serviceAccount.annotations Annotations to add to the service account. -# @param serviceAccount.name The name of the service account to use. If not set and create is true, a name is generated using the fullname template. +# @param serviceAccount.create Specifies whether a service account should be created +# @param serviceAccount.annotations Annotations to add to the service account +# @param serviceAccount.name The name of the service account to use. If not set and create is true, a name is generated using the fullname template serviceAccount: create: false @@ -285,12 +384,13 @@ serviceAccount: # @section Service settings -# @param service.type Kubernetes [service type](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types). -# @param service.clusterIP Controls Service cluster IP allocation. Cannot be changed after resource creation. -# @param service.port Service port. -# @param service.grpcPort Service GRPC port if `naviback.grpcPort` enabled. -# @param service.annotations Kubernetes [service annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/). -# @param service.labels Kubernetes [service labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/). +# @param service.type Kubernetes [service type](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types) +# @param service.clusterIP Controls Service cluster IP allocation. Cannot be changed after resource creation +# @param service.port Service port +# @param service.grpcPort Service GRPC port if `naviback.grpcPort` enabled +# @param service.annotations Kubernetes [service annotations](https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/) +# @param service.labels Kubernetes [service labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/) +# @param service.extraPorts Extra ports to expose in the service (normally used with the `sidecar` value) # @param service.headless.enabled Enable creating a secondary headless service # @param service.headless.annotations Annotations for secondary headless service @@ -301,6 +401,7 @@ service: grpcPort: 50051 annotations: {} labels: + extraPorts: [] headless: enabled: false annotations: {} @@ -308,16 +409,16 @@ service: # @section Kubernetes [Ingress](https://kubernetes.io/docs/concepts/services-networking/ingress/) settings -# @param ingress.enabled If Ingress is enabled for the service. -# @param ingress.className Name of the Ingress controller class. -# @param ingress.hosts[0].host Hostname for the Ingress service. -# @param ingress.hosts[0].paths[0].path Path of the host for the Ingress service. -# @param ingress.hosts[0].paths[0].pathType Type of the path for the Ingress service. +# @param ingress.className Name of the Ingress controller class +# @param ingress.enabled If Ingress is enabled for the service +# @param ingress.hosts[0].host Hostname for the Ingress service +# @param ingress.hosts[0].paths[0].path Path of the host for the Ingress service +# @param ingress.hosts[0].paths[0].pathType Type of the path for the Ingress service # @param ingress.tls TLS configuration ingress: - enabled: false className: nginx + enabled: false hosts: - host: navi-back.example.com paths: @@ -331,24 +432,24 @@ ingress: # @section Limits -# @param resources [nullable] Container resources requirements structure. -# @param resources.requests.cpu [nullable] CPU request, recommended value `1000m`. -# @param resources.requests.memory [nullable] Memory request, recommended value `2Gi`. -# @param resources.limits.cpu [nullable] CPU limit, recommended value `3000m`. -# @param resources.limits.memory [nullable] Memory limit, recommended value `8Gi`. +# @param resources [nullable] Container resources requirements structure +# @param resources.requests.cpu [nullable] CPU request, recommended value `1000m` +# @param resources.requests.memory [nullable] Memory request, recommended value `2Gi` +# @param resources.limits.cpu [nullable] CPU limit, recommended value `3000m` +# @param resources.limits.memory [nullable] Memory limit, recommended value `8Gi` resources: {} # @section Kubernetes [Horizontal Pod Autoscaling](https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/) settings -# @param hpa.enabled If HPA is enabled for the service. -# @param hpa.minReplicas Lower limit for the number of replicas to which the autoscaler can scale down. -# @param hpa.maxReplicas Upper limit for the number of replicas to which the autoscaler can scale up. -# @param hpa.scaleDownStabilizationWindowSeconds Scale-down window. -# @param hpa.scaleUpStabilizationWindowSeconds Scale-up window. -# @param hpa.targetCPUUtilizationPercentage Target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used. -# @param hpa.targetMemoryUtilizationPercentage Target average memory utilization (represented as a percentage of requested memory) over all the pods; if not specified the default autoscaling policy will be used. +# @param hpa.enabled If HPA is enabled for the service +# @param hpa.minReplicas Lower limit for the number of replicas to which the autoscaler can scale down +# @param hpa.maxReplicas Upper limit for the number of replicas to which the autoscaler can scale up +# @param hpa.scaleDownStabilizationWindowSeconds Scale-down window +# @param hpa.scaleUpStabilizationWindowSeconds Scale-up window +# @param hpa.targetCPUUtilizationPercentage Target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified the default autoscaling policy will be used +# @param hpa.targetMemoryUtilizationPercentage Target average memory utilization (represented as a percentage of requested memory) over all the pods; if not specified the default autoscaling policy will be used hpa: enabled: false @@ -362,12 +463,12 @@ hpa: # @section Kubernetes [Vertical Pod Autoscaling](https://github.com/kubernetes/autoscaler/blob/master/vertical-pod-autoscaler/README.md) settings -# @param vpa.enabled If VPA is enabled for the service. -# @param vpa.updateMode VPA [update mode](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#quick-start). -# @extra vpa.minAllowed.cpu Lower limit for the number of CPUs to which the autoscaler can scale down. -# @extra vpa.minAllowed.memory Lower limit for the RAM size to which the autoscaler can scale down. -# @extra vpa.maxAllowed.cpu Upper limit for the number of CPUs to which the autoscaler can scale up. -# @extra vpa.maxAllowed.memory Upper limit for the RAM size to which the autoscaler can scale up. +# @param vpa.enabled If VPA is enabled for the service +# @param vpa.updateMode VPA [update mode](https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler#quick-start) +# @extra vpa.minAllowed.cpu Lower limit for the number of CPUs to which the autoscaler can scale down +# @extra vpa.minAllowed.memory Lower limit for the RAM size to which the autoscaler can scale down +# @extra vpa.maxAllowed.cpu Upper limit for the number of CPUs to which the autoscaler can scale up +# @extra vpa.maxAllowed.memory Upper limit for the RAM size to which the autoscaler can scale up vpa: enabled: false @@ -376,9 +477,9 @@ vpa: # @section Kubernetes [Pod Disruption Budget](https://kubernetes.io/docs/concepts/workloads/pods/disruptions/#pod-disruption-budgets) settings -# @param pdb.enabled If PDB is enabled for the service. -# @param pdb.minAvailable How many pods must be available after the eviction. -# @param pdb.maxUnavailable How many pods can be unavailable after the eviction. +# @param pdb.enabled If PDB is enabled for the service +# @param pdb.minAvailable How many pods must be available after the eviction +# @param pdb.maxUnavailable How many pods can be unavailable after the eviction pdb: enabled: false @@ -388,24 +489,26 @@ pdb: # @section Kafka settings for interacting with Distance Matrix Async Service -# @param kafka.enabled If the Kafka is enabled. -# @param kafka.groupId Navi-Back service group identifier. -# @extra kafka.properties Properties as supported by librdkafka. Refer to inline comments for details. +# @param kafka.enabled If the Kafka is enabled +# @param kafka.groupId Navi-Back service group identifier +# @param kafka.handlersNumber Number of Kafka handlers +# @extra kafka.properties Properties as supported by librdkafka. Refer to inline comments for details # @skip kafka.properties.bootstrap.servers # @skip kafka.properties.security.protocol -# @param kafka.fileProperties As kafka.properties, but kept in a file, which passed to application as a filename. Refer to inline comments for details. +# @param kafka.fileProperties As kafka.properties, but kept in a file, which passed to application as a filename. Refer to inline comments for details # @extra kafka.distanceMatrix **Settings for interacting with Distance Matrix Async service.** -# @param kafka.distanceMatrix.taskTopic Name of the topic for receiving new tasks from Distance Matrix Async API. -# @param kafka.distanceMatrix.cancelTopic Name of the topic for canceling or receiving information about finished tasks. -# @param kafka.distanceMatrix.statusTopic Name of the topic for receiving task status information. -# @param kafka.distanceMatrix.updateTaskStatusPeriodSec Update period for task statuses. -# @param kafka.distanceMatrix.messageExpiredPeriodSec Update period for task cancellations. -# @param kafka.distanceMatrix.requestDownloadTimeoutSec Timeout for downloading request data. -# @param kafka.distanceMatrix.responseUploadTimeoutSec Timeout for uploading response data. +# @param kafka.distanceMatrix.taskTopic Name of the topic for receiving new tasks from Distance Matrix Async API +# @param kafka.distanceMatrix.cancelTopic Name of the topic for canceling or receiving information about finished tasks +# @param kafka.distanceMatrix.statusTopic Name of the topic for receiving task status information +# @param kafka.distanceMatrix.updateTaskStatusPeriodSec Update period for task statuses +# @param kafka.distanceMatrix.messageExpiredPeriodSec Update period for task cancellations +# @param kafka.distanceMatrix.requestDownloadTimeoutSec Timeout for downloading request data +# @param kafka.distanceMatrix.responseUploadTimeoutSec Timeout for uploading response data kafka: enabled: false groupId: navi_back + handlersNumber: 2 properties: bootstrap.servers: kafka.host:9092 security.protocol: PLAINTEXT @@ -455,11 +558,12 @@ kafka: # @section S3-compatible storage settings for interacting with Distance Matrix Async Service -# @param s3.enabled if S3 storage is enabled. -# @param s3.host S3 endpoint, ex: async-matrix-s3.host. -# @param s3.bucket S3 bucket name. -# @param s3.accessKey S3 access key for accessing the bucket. -# @param s3.secretKey S3 secret key for accessing the bucket. +# @param s3.enabled if S3 storage is enabled +# @param s3.host S3 endpoint, ex: async-matrix-s3.host +# @param s3.bucket S3 bucket name +# @param s3.accessKey S3 access key for accessing the bucket +# @param s3.secretKey S3 secret key for accessing the bucket +# @param s3.suffix String to append to file names in replies s3: enabled: false @@ -467,6 +571,7 @@ s3: bucket: '' accessKey: '' secretKey: '' + suffix: '' # @section Settings for attractor connection. Leave with defaults, FOR FUTURE RELEASE. @@ -475,13 +580,20 @@ s3: # @param transmitter.host attractor service # @param transmitter.port attractor port # @param transmitter.responseTimeoutMs response waiting timeout +# @param transmitter.retry.enabled Enable retry failed requests +# @param transmitter.retry.retryOn Status [codes for retry](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on) +# @param transmitter.retry.numRetries Specifies the allowed number of retries transmitter: enabled: false type: grpc-async-stream host: http://navi-attractor.host port: 50051 - responseTimeoutMs: 100 + responseTimeoutMs: 2000 + retry: + enabled: false + retryOn: internal,unavailable + numRetries: 5 # @section Back-end and attractor group properties. Leave with defaults, FOR FUTURE RELEASE. @@ -497,11 +609,9 @@ dataGroup: # @section License settings # @param license.url Address of the License service v2. Ex: https://license.svc -# @param license.notSupported Excludes the configuration block if true, for old versions only. license: url: '' - notSupported: false # @section Metrics aggregator container. Leave with defaults, FOR FUTURE RELEASE. @@ -509,12 +619,12 @@ license: # @param metrics.image.repository Repository # @param metrics.image.tag Tag # @param metrics.image.pullPolicy Pull Policy -# @param metrics.port Port of container. -# @param metrics.resources [nullable] Container resources requirements structure. -# @param metrics.resources.requests.cpu [nullable] CPU request, recommended value `10m`. -# @extra metrics.resources.requests.memory [nullable] Memory request, recommended value `10Mi`. -# @extra metrics.resources.limits.cpu [nullable] CPU limit, recommended value `100m`. -# @extra metrics.resources.limits.memory [nullable] Memory limit, recommended value `10Mi`. +# @param metrics.port Port of container +# @param metrics.resources [nullable] Container resources requirements structure +# @param metrics.resources.requests.cpu [nullable] CPU request, recommended value `10m` +# @extra metrics.resources.requests.memory [nullable] Memory request, recommended value `10Mi` +# @extra metrics.resources.limits.cpu [nullable] CPU limit, recommended value `100m` +# @extra metrics.resources.limits.memory [nullable] Memory limit, recommended value `10Mi` metrics: enabled: false diff --git a/charts/navi-castle/Chart.yaml b/charts/navi-castle/Chart.yaml index b0358e607..277b7efc2 100644 --- a/charts/navi-castle/Chart.yaml +++ b/charts/navi-castle/Chart.yaml @@ -4,7 +4,7 @@ description: Castle Helm chart for Kubernetes type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.9.2 maintainers: diff --git a/charts/navi-front/Chart.yaml b/charts/navi-front/Chart.yaml index 0576d74f0..e730f981f 100644 --- a/charts/navi-front/Chart.yaml +++ b/charts/navi-front/Chart.yaml @@ -5,7 +5,7 @@ type: application keywords: - navi - front -version: 1.24.0 +version: 1.25.0 appVersion: 1.24.1 maintainers: - name: 2gis diff --git a/charts/navi-restrictions/Chart.yaml b/charts/navi-restrictions/Chart.yaml index 893e69633..ebddcd218 100644 --- a/charts/navi-restrictions/Chart.yaml +++ b/charts/navi-restrictions/Chart.yaml @@ -4,7 +4,7 @@ description: A Helm chart for Kubernetes to deploy Restrictions backend type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.24.1 maintainers: diff --git a/charts/navi-router/Chart.yaml b/charts/navi-router/Chart.yaml index a0fba8c3b..bdc7c6bed 100644 --- a/charts/navi-router/Chart.yaml +++ b/charts/navi-router/Chart.yaml @@ -5,7 +5,7 @@ type: application keywords: - navi - router -version: 1.24.0 +version: 1.25.0 appVersion: 6.17.1.2 maintainers: - name: 2gis diff --git a/charts/navi-splitter/Chart.yaml b/charts/navi-splitter/Chart.yaml index f3725996e..a2f24fe7c 100644 --- a/charts/navi-splitter/Chart.yaml +++ b/charts/navi-splitter/Chart.yaml @@ -15,5 +15,5 @@ maintainers: - name: 2gis url: https://github.com/2gis email: on-premise@2gis.com -version: 1.24.0 +version: 1.25.0 appVersion: 1.0.1 diff --git a/charts/platform/Chart.yaml b/charts/platform/Chart.yaml index 76985524a..89e4b530c 100644 --- a/charts/platform/Chart.yaml +++ b/charts/platform/Chart.yaml @@ -3,7 +3,7 @@ name: platform type: application description: A Helm chart for Kubernetes to deploy Platform -version: 1.24.0 +version: 1.25.0 appVersion: 0.8.1 maintainers: diff --git a/charts/pro-api/Chart.yaml b/charts/pro-api/Chart.yaml index 32ae9c088..49bad2991 100644 --- a/charts/pro-api/Chart.yaml +++ b/charts/pro-api/Chart.yaml @@ -4,7 +4,7 @@ description: Geo API for getting geo data type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.22.0 maintainers: diff --git a/charts/pro-api/README.md b/charts/pro-api/README.md index d4a72004a..0fb1d7330 100644 --- a/charts/pro-api/README.md +++ b/charts/pro-api/README.md @@ -90,17 +90,18 @@ ### 2GIS PRO API configuration -| Name | Description | Value | -| ------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | -| `api.serviceAccount` | Kubernetes service account | `runner` | -| `api.tempPath` | Path to directory used for temp data | `/tmp` | -| `api.allowAnyOrigin` | Cors policy: allow any origin to perform requests to pro-api service | `false` | -| `api.logging` | Logging settings | | -| `api.logging.format` | Log message format, possible options: 'default' - compact json, 'renderedCompactJson' - rendered json format, 'simple' - plain text | `simple` | -| `api.logging.targets` | Collection of logging targets divided by comma. Currently only 'console' and 'database' are supported. Console is used by default (no need to specify). | `""` | -| `api.rateLimiter` | rate limiter settings | | -| `api.rateLimiter.requestsLimit` | max number of requests from one user during time window (0 means rate limiter is disabled) | `1024` | -| `api.rateLimiter.windowSizeInSeconds` | the size of time windows to count and limit incoming requests | `1` | +| Name | Description | Value | +| ------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | +| `api.serviceAccount` | Kubernetes service account | `runner` | +| `api.serviceAccountOverride` | The name of an existing custom service account. If specified, the services in the chart will use this existing service account. If not specified, a new service account will be created and used with the name from the variable `api.serviceAccount`. | `""` | +| `api.tempPath` | Path to directory used for temp data | `/tmp` | +| `api.allowAnyOrigin` | Cors policy: allow any origin to perform requests to pro-api service | `false` | +| `api.logging` | Logging settings | | +| `api.logging.format` | Log message format, possible options: 'default' - compact json, 'renderedCompactJson' - rendered json format, 'simple' - plain text | `simple` | +| `api.logging.targets` | Collection of logging targets divided by comma. Currently only 'console' and 'database' are supported. Console is used by default (no need to specify). | `""` | +| `api.rateLimiter` | rate limiter settings | | +| `api.rateLimiter.requestsLimit` | max number of requests from one user during time window (0 means rate limiter is disabled) | `1024` | +| `api.rateLimiter.windowSizeInSeconds` | the size of time windows to count and limit incoming requests | `1` | ### Auth configuration diff --git a/charts/pro-api/templates/_helpers.tpl b/charts/pro-api/templates/_helpers.tpl index a771fb884..d114e20db 100644 --- a/charts/pro-api/templates/_helpers.tpl +++ b/charts/pro-api/templates/_helpers.tpl @@ -51,12 +51,17 @@ {{- end -}} {{- end -}} + {{- define "pro-api.service-account-name" -}} -{{- $name := default .Values.api.serviceAccount -}} -{{- if contains $name .Release.Name -}} -{{- .Release.Name | trunc 63 | trimSuffix "-" -}} +{{- if empty .Values.api.serviceAccountOverride }} + {{- $name := default .Values.api.serviceAccount -}} + {{- if contains $name .Release.Name -}} + {{- .Release.Name | trunc 63 | trimSuffix "-" -}} + {{- else -}} + {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} + {{- end -}} {{- else -}} -{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} + {{- .Values.api.serviceAccountOverride | trunc 63 | trimSuffix "-" -}} {{- end -}} {{- end -}} diff --git a/charts/pro-api/templates/service-account.yaml b/charts/pro-api/templates/service-account.yaml index dad84083d..7586bbd27 100644 --- a/charts/pro-api/templates/service-account.yaml +++ b/charts/pro-api/templates/service-account.yaml @@ -1,4 +1,6 @@ +{{- if empty .Values.api.serviceAccountOverride }} apiVersion: v1 kind: ServiceAccount metadata: name: {{ include "pro-api.service-account-name" . }} +{{- end }} diff --git a/charts/pro-api/values.yaml b/charts/pro-api/values.yaml index f15d65ec0..9174c7c89 100644 --- a/charts/pro-api/values.yaml +++ b/charts/pro-api/values.yaml @@ -148,7 +148,8 @@ s3: # @section 2GIS PRO API configuration -# @param api.serviceAccount Kubernetes service account +# @param api.serviceAccount Kubernetes service account +# @param api.serviceAccountOverride The name of an existing custom service account. If specified, the services in the chart will use this existing service account. If not specified, a new service account will be created and used with the name from the variable `api.serviceAccount`. # @param api.tempPath Path to directory used for temp data # @param api.allowAnyOrigin Cors policy: allow any origin to perform requests to pro-api service # @extra api.logging Logging settings @@ -169,6 +170,7 @@ s3: api: serviceAccount: runner + serviceAccountOverride: '' tempPath: /tmp allowAnyOrigin: false logEsQueries: false diff --git a/charts/pro-ui/Chart.yaml b/charts/pro-ui/Chart.yaml index de7deb368..b726c7003 100644 --- a/charts/pro-ui/Chart.yaml +++ b/charts/pro-ui/Chart.yaml @@ -3,7 +3,7 @@ name: pro-ui type: application description: A Helm chart for Kubernetes to deploy 2GIS Pro UI service -version: 1.24.0 +version: 1.25.0 appVersion: 2.15.1 maintainers: diff --git a/charts/search-api/Chart.yaml b/charts/search-api/Chart.yaml index 42e8b99b3..403fd54a2 100644 --- a/charts/search-api/Chart.yaml +++ b/charts/search-api/Chart.yaml @@ -4,8 +4,8 @@ description: Search engine for catalog type: application -version: 1.24.0 -appVersion: 7.76.1 +version: 1.25.0 +appVersion: 7.77.2 maintainers: - name: 2gis diff --git a/charts/search-api/README.md b/charts/search-api/README.md index d81054815..ff0aa0a4b 100644 --- a/charts/search-api/README.md +++ b/charts/search-api/README.md @@ -55,7 +55,7 @@ See the [documentation](https://docs.2gis.com/en/on-premise/search) to learn abo | Name | Description | Value | | ---------------------- | --------------------------------------------------------------------------------------------- | ---------------------------- | | `api.image.repository` | Repository | `2gis-on-premise/search-api` | -| `api.image.tag` | Tag | `7.76.1` | +| `api.image.tag` | Tag | `7.77.2` | | `api.image.pullPolicy` | Image [pull policy](https://kubernetes.io/docs/concepts/containers/images/#image-pull-policy) | `IfNotPresent` | ### API settings diff --git a/charts/search-api/values.yaml b/charts/search-api/values.yaml index 7b76861de..e074fd4b1 100644 --- a/charts/search-api/values.yaml +++ b/charts/search-api/values.yaml @@ -54,7 +54,7 @@ api: image: repository: 2gis-on-premise/search-api - tag: 7.76.1 + tag: 7.77.2 pullPolicy: IfNotPresent diff --git a/charts/stat-receiver/Chart.yaml b/charts/stat-receiver/Chart.yaml index bb0ea096d..c2cdc8a10 100644 --- a/charts/stat-receiver/Chart.yaml +++ b/charts/stat-receiver/Chart.yaml @@ -3,7 +3,7 @@ name: stat-receiver type: application description: A Helm chart for Kubernetes to deploy Stat Receiver -version: 1.24.0 +version: 1.25.0 appVersion: 1.11.1 maintainers: diff --git a/charts/tiles-api/Chart.yaml b/charts/tiles-api/Chart.yaml index c8195cde2..2609a79cb 100644 --- a/charts/tiles-api/Chart.yaml +++ b/charts/tiles-api/Chart.yaml @@ -4,7 +4,7 @@ description: Tiles API for getting cartographic data type: application -version: 1.24.0 +version: 1.25.0 appVersion: 4.54.0 maintainers: diff --git a/charts/traffic-proxy/Chart.yaml b/charts/traffic-proxy/Chart.yaml index 01af076ad..7ae7d3472 100644 --- a/charts/traffic-proxy/Chart.yaml +++ b/charts/traffic-proxy/Chart.yaml @@ -4,7 +4,7 @@ description: A Helm chart for Kubernetes to deploy Proxy for traffic jams type: application -version: 1.24.0 +version: 1.25.0 appVersion: 1.21.6 maintainers: diff --git a/charts/twins-api/Chart.yaml b/charts/twins-api/Chart.yaml index 11d657975..27547e975 100644 --- a/charts/twins-api/Chart.yaml +++ b/charts/twins-api/Chart.yaml @@ -3,7 +3,7 @@ name: twins-api type: application description: A Helm chart for Kubernetes to deploy API Twins service -version: 1.24.0 +version: 1.25.0 appVersion: 1.9.0 maintainers: diff --git a/image_versions.txt b/image_versions.txt index 08b563c2e..68bc0e436 100644 --- a/image_versions.txt +++ b/image_versions.txt @@ -34,9 +34,8 @@ navi-async-matrix navi-async-matrix:1.6.2 navi-back envoy:v1.27.0 - frozen-data: metrics-aggregator: - navi-back:7.15.2.4 + navi-back:7.23.0.5 navi-castle navi-castle:1.9.2 navi-front:1.24.1 @@ -60,7 +59,7 @@ pro-ui pro-importer:1.22.0 pro-ui:2.15.1 search-api - search-api:7.76.1 + search-api:7.77.2 search-nginx:1.21.6 stat-receiver stat-receiver-api:1.11.1