diff --git a/chart/README.md b/chart/README.md index eb546548..3321601c 100644 --- a/chart/README.md +++ b/chart/README.md @@ -176,9 +176,13 @@ To install, upgrade or uninstall this chart, please refer to [the root README.md | `cartoSecrets.defaultGoogleServiceAccount.existingSecret.name` | Name of the pre-existent secret containing the `cartoSecrets.defaultGoogleServiceAccount.existingSecret.key`. If `cartoSecrets.defaultGoogleServiceAccount.value` is defined, this value is going to be ignored and not used. | `""` | | `cartoSecrets.defaultGoogleServiceAccount.existingSecret.key` | Key to find in `cartoSecrets.defaultGoogleServiceAccount.existingSecret.name` where the value of `cartoSecrets.defaultGoogleServiceAccount` is found. If `cartoSecrets.defaultGoogleServiceAccount.value` is defined, this value is going to be ignored and not used. | `""` | | `cartoSecrets.gitbookApiToken` | GitBook API Token provided by CARTO | | -| `cartoSecrets.gitbookApiToken.value` | Value of the secret used by the app to connect to google services. This couldn't be changed. One of `cartoSecrets.gitbookApiToken.value` or `cartoSecrets.gitbookApiToken.existingSecret` could be defined. | `""` | +| `cartoSecrets.gitbookApiToken.value` | Value of the secret used by the app to connect to Gitbook. This couldn't be changed. One of `cartoSecrets.gitbookApiToken.value` or `cartoSecrets.gitbookApiToken.existingSecret` could be defined. | `""` | | `cartoSecrets.gitbookApiToken.existingSecret.name` | Name of the pre-existent secret containing the `cartoSecrets.gitbookApiToken.existingSecret.key`. If `cartoSecrets.gitbookApiToken.value` is defined, this value is going to be ignored and not used. | `""` | | `cartoSecrets.gitbookApiToken.existingSecret.key` | Key to find in `cartoSecrets.gitbookApiToken.existingSecret.name` where the value of `cartoSecrets.gitbookApiToken` is found. If `cartoSecrets.gitbookApiToken.value` is defined, this value is going to be ignored and not used. | `""` | +| `cartoSecrets.vitallyToken` | Vitally Token provided by CARTO | | +| `cartoSecrets.vitallyToken.value` | Value of the secret used by the app to connect to Vitally. This couldn't be changed. One of `cartoSecrets.vitallyToken.value` or `cartoSecrets.vitallyToken.existingSecret` could be defined. | `""` | +| `cartoSecrets.vitallyToken.existingSecret.name` | Name of the pre-existent secret containing the `cartoSecrets.vitallyToken.existingSecret.key`. If `cartoSecrets.vitallyToken.value` is defined, this value is going to be ignored and not used. | `""` | +| `cartoSecrets.vitallyToken.existingSecret.key` | Key to find in `cartoSecrets.vitallyToken.existingSecret.name` where the value of `cartoSecrets.vitallyToken` is found. If `cartoSecrets.vitallyToken.value` is defined, this value is going to be ignored and not used. | `""` | | `cartoSecrets.instanceId` | The secret used to define the instance ID for the active installation | | | `cartoSecrets.instanceId.value` | Value of the secret used to define the instance ID for the active installation. One of `cartoSecrets.instanceId.value` or `cartoSecrets.instanceId.existingSecret` could be defined. | `""` | | `cartoSecrets.instanceId.existingSecret.name` | Name of the pre-existent secret containing the `cartoSecrets.instanceId.existingSecret.key`. If `cartoSecrets.instanceId.value` is defined, this value is going to be ignored and not used. | `""` | diff --git a/chart/templates/_helpers.tpl b/chart/templates/_helpers.tpl index c4635dc1..a77f6ec6 100644 --- a/chart/templates/_helpers.tpl +++ b/chart/templates/_helpers.tpl @@ -45,6 +45,7 @@ Association between env secret and path of the secret in values.yaml */}} {{- define "carto._utils.secretAssociation" -}} BIGQUERY_OAUTH2_CLIENT_SECRET: appSecrets.bigqueryOauth2ClientSecret +CARTO_SELFHOSTED_INSTANCE_ID: cartoSecrets.instanceId ENCRYPTION_SECRET_KEY: cartoSecrets.encryptionSecretKey IMPORT_ACCESSKEYID: appSecrets.awsAccessKeyId IMPORT_AWS_ACCESS_KEY_ID: appSecrets.importAwsAccessKeyId @@ -55,6 +56,7 @@ IMPORT_STORAGE_ACCESSKEY: appSecrets.azureStorageAccessKey GITBOOK_API_TOKEN: cartoSecrets.gitbookApiToken EXPORTS_S3_BUCKET_ACCESS_KEY_ID: appSecrets.exportAwsAccessKeyId EXPORTS_S3_BUCKET_SECRET_ACCESS_KEY: appSecrets.exportAwsSecretAccessKey +GOOGLE_MAPS_API_KEY: appSecrets.googleMapsApiKey LDS_JWT_SECRET: cartoSecrets.jwtApiSecret LDS_PROVIDER_HERE_API_KEY: appSecrets.ldsHereApiKey LDS_PROVIDER_MAPBOX_API_KEY: appSecrets.ldsMapboxApiKey @@ -64,7 +66,7 @@ LDS_PROVIDER_TRAVELTIME_API_KEY: appSecrets.ldsTravelTimeApiKey LDS_PROVIDER_TRAVELTIME_APP_ID: appSecrets.ldsTravelTimeAppId LAUNCHDARKLY_SDK_KEY: cartoSecrets.launchDarklySdkKey MAPS_API_V3_JWT_SECRET: cartoSecrets.jwtApiSecret -GOOGLE_MAPS_API_KEY: appSecrets.googleMapsApiKey +REACT_APP_VITALLY_TOKEN: cartoSecrets.vitallyToken VARNISH_DEBUG_SECRET: cartoSecrets.varnishDebugSecret VARNISH_PURGE_SECRET: cartoSecrets.varnishPurgeSecret WORKSPACE_IMPORTS_ACCESSKEYID: appSecrets.awsAccessKeyId @@ -74,7 +76,6 @@ WORKSPACE_JWT_SECRET: cartoSecrets.jwtApiSecret WORKSPACE_THUMBNAILS_ACCESSKEYID: appSecrets.awsAccessKeyId WORKSPACE_THUMBNAILS_SECRETACCESSKEY: appSecrets.awsAccessKeySecret WORKSPACE_THUMBNAILS_STORAGE_ACCESSKEY: appSecrets.azureStorageAccessKey -CARTO_SELFHOSTED_INSTANCE_ID: cartoSecrets.instanceId {{- end -}} {{/* diff --git a/chart/templates/workspace-www/configmap.yaml b/chart/templates/workspace-www/configmap.yaml index 40d444f3..a8e00e2d 100644 --- a/chart/templates/workspace-www/configmap.yaml +++ b/chart/templates/workspace-www/configmap.yaml @@ -37,7 +37,6 @@ data: REACT_APP_WORKSPACE_WWW_ENABLE_TRACKJS: {{ .Values.appConfigValues.enableTrackJS | quote }} REACT_APP_WORKSPACE_WWW_ENABLE_EXPORTS: "false" REACT_APP_WORKSPACE_WWW_ENABLE_GENAI: "false" - REACT_APP_ASKNICELY_MIN_HOURS_ACCOUNT_OLD_ENOUGH: "1920" {{- if .Values.appConfigValues.ssoOrganizationId }} REACT_APP_ORGANIZATION_ID: {{ .Values.appConfigValues.ssoOrganizationId }} {{- end }} diff --git a/chart/templates/workspace-www/deployment.yaml b/chart/templates/workspace-www/deployment.yaml index 46e2ac03..781c62ef 100644 --- a/chart/templates/workspace-www/deployment.yaml +++ b/chart/templates/workspace-www/deployment.yaml @@ -96,14 +96,20 @@ spec: /docker-entrypoint.sh nginx -g "daemon off;" {{- end }} env: - {{- include "carto._utils.generateSecretDefs" (dict "vars" (list "GOOGLE_MAPS_API_KEY") "context" $ ) | nindent 12 }} + {{- include "carto._utils.generateSecretDefs" (dict "vars" (list + "GOOGLE_MAPS_API_KEY" + "REACT_APP_VITALLY_TOKEN" + ) "context" $ ) | nindent 12 }} {{- if .Values.workspaceWww.extraEnvVars }} {{- include "common.tplvalues.render" (dict "value" .Values.workspaceWww.extraEnvVars "context" $) | nindent 12 }} {{- end }} envFrom: - configMapRef: name: {{ template "carto.workspaceWww.configmapName" . }} - {{- $secretContent := include "carto._utils.generateSecretObjects" (dict "vars" (list "GOOGLE_MAPS_API_KEY") "context" $ ) -}} + {{- $secretContent := include "carto._utils.generateSecretObjects" (dict "vars" (list + "GOOGLE_MAPS_API_KEY" + "REACT_APP_VITALLY_TOKEN" + ) "context" $ ) -}} {{- if $secretContent }} - secretRef: name: {{ include "carto.workspaceWww.secretName" . }} diff --git a/chart/templates/workspace-www/secret.yaml b/chart/templates/workspace-www/secret.yaml index cc60c103..d28544d2 100644 --- a/chart/templates/workspace-www/secret.yaml +++ b/chart/templates/workspace-www/secret.yaml @@ -1,4 +1,7 @@ -{{ $secretContent := include "carto._utils.generateSecretObjects" (dict "vars" (list "GOOGLE_MAPS_API_KEY") "context" $ )}} +{{ $secretContent := include "carto._utils.generateSecretObjects" (dict "vars" (list + "GOOGLE_MAPS_API_KEY" + "REACT_APP_VITALLY_TOKEN" +) "context" $ )}} {{- if $secretContent }} apiVersion: v1 kind: Secret diff --git a/chart/values.yaml b/chart/values.yaml index df055fa7..9d60b962 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -344,7 +344,7 @@ cartoSecrets: key: "" ## @extra cartoSecrets.gitbookApiToken GitBook API Token provided by CARTO gitbookApiToken: - ## @param cartoSecrets.gitbookApiToken.value Value of the secret used by the app to connect to google services. This couldn't be changed. One of `cartoSecrets.gitbookApiToken.value` or `cartoSecrets.gitbookApiToken.existingSecret` could be defined. + ## @param cartoSecrets.gitbookApiToken.value Value of the secret used by the app to connect to Gitbook. This couldn't be changed. One of `cartoSecrets.gitbookApiToken.value` or `cartoSecrets.gitbookApiToken.existingSecret` could be defined. value: "" ## @param cartoSecrets.gitbookApiToken.existingSecret.name Name of the pre-existent secret containing the `cartoSecrets.gitbookApiToken.existingSecret.key`. If `cartoSecrets.gitbookApiToken.value` is defined, this value is going to be ignored and not used. ## @param cartoSecrets.gitbookApiToken.existingSecret.key Key to find in `cartoSecrets.gitbookApiToken.existingSecret.name` where the value of `cartoSecrets.gitbookApiToken` is found. If `cartoSecrets.gitbookApiToken.value` is defined, this value is going to be ignored and not used. @@ -352,6 +352,16 @@ cartoSecrets: existingSecret: name: "" key: "" + ## @extra cartoSecrets.vitallyToken Vitally Token provided by CARTO + vitallyToken: + ## @param cartoSecrets.vitallyToken.value Value of the secret used by the app to connect to Vitally. This couldn't be changed. One of `cartoSecrets.vitallyToken.value` or `cartoSecrets.vitallyToken.existingSecret` could be defined. + value: "" + ## @param cartoSecrets.vitallyToken.existingSecret.name Name of the pre-existent secret containing the `cartoSecrets.vitallyToken.existingSecret.key`. If `cartoSecrets.vitallyToken.value` is defined, this value is going to be ignored and not used. + ## @param cartoSecrets.vitallyToken.existingSecret.key Key to find in `cartoSecrets.vitallyToken.existingSecret.name` where the value of `cartoSecrets.vitallyToken` is found. If `cartoSecrets.vitallyToken.value` is defined, this value is going to be ignored and not used. + ## + existingSecret: + name: "" + key: "" ## @extra cartoSecrets.instanceId The secret used to define the instance ID for the active installation instanceId: ## @param cartoSecrets.instanceId.value Value of the secret used to define the instance ID for the active installation. One of `cartoSecrets.instanceId.value` or `cartoSecrets.instanceId.existingSecret` could be defined. diff --git a/manifests/kots-helm.yaml b/manifests/kots-helm.yaml index 799c65ed..db372ac7 100644 --- a/manifests/kots-helm.yaml +++ b/manifests/kots-helm.yaml @@ -39,6 +39,8 @@ spec: value: '{{repl ConfigOption "cartoPlatformGoogleSA" }}' instanceId: value: '{{repl ConfigOption "autogeneratedInstanceId" }}' + vitallyToken: + value: '{{repl LicenseFieldValue "vitallyToken" }}' # Carto Config Values cartoConfigValues: cartoAccApiDomain: '{{repl fromJson (ConfigOption "valuesDerivedFromCartoPlatformEnvironment") | dig "cartoAccApiDomain" "" | Base64Decode }}'