From 662a1e17262d684b8d22d143d1090d346fc2bacb Mon Sep 17 00:00:00 2001 From: Erica Liu Date: Thu, 15 Aug 2024 16:10:09 -0700 Subject: [PATCH] [Chore] Add global singleTenantMode global value for SDP and dashboard (#392) --- dev/env-config.js | 3 ++- helmchart/sdp/Chart.yaml | 2 +- helmchart/sdp/README.md | 1 + helmchart/sdp/templates/01.1-configmap-sdp.yaml | 1 + helmchart/sdp/templates/01.4-configmap-dashboard.yaml | 5 +++-- helmchart/sdp/values.yaml | 3 +++ 6 files changed, 11 insertions(+), 4 deletions(-) diff --git a/dev/env-config.js b/dev/env-config.js index 6b1a8dcbc..f74fc26ab 100644 --- a/dev/env-config.js +++ b/dev/env-config.js @@ -3,5 +3,6 @@ window._env_ = { STELLAR_EXPERT_URL: "https://stellar.expert/explorer/testnet", HORIZON_URL: "https://horizon-testnet.stellar.org", USDC_ASSET_ISSUER: "GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5", - RECAPTCHA_SITE_KEY: "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI" + RECAPTCHA_SITE_KEY: "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI", + SINGLE_TENANT_MODE: false }; diff --git a/helmchart/sdp/Chart.yaml b/helmchart/sdp/Chart.yaml index 463527fd2..38c5197a1 100644 --- a/helmchart/sdp/Chart.yaml +++ b/helmchart/sdp/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v2 name: stellar-disbursement-platform description: A Helm chart for the Stellar Disbursement Platform Backend (A.K.A. `sdp`) -version: "2.1.0" +version: "2.1.1" appVersion: "2.1.0" type: application maintainers: diff --git a/helmchart/sdp/README.md b/helmchart/sdp/README.md index 85e57c306..31e3a866a 100644 --- a/helmchart/sdp/README.md +++ b/helmchart/sdp/README.md @@ -85,6 +85,7 @@ These parameters are shared by all charts. | `global.eventBroker.consumerGroupId` | The consumer group ID for the event broker. | `nil` | | `global.eventBroker.kafka` | Configuration related to the Kafka event broker. | | | `global.eventBroker.kafka.securityProtocol` | The security protocol to be used for the Kafka broker. Options: "PLAINTEXT", "SASL_SSL", "SASL_PLAINTEXT", "SSL". | `nil` | +| `global.singleTenantMode` | Determines if the SDP service is running in single-tenant mode. | `false` | ### Stellar Disbursement Platform (SDP) parameters diff --git a/helmchart/sdp/templates/01.1-configmap-sdp.yaml b/helmchart/sdp/templates/01.1-configmap-sdp.yaml index 3e9498fe4..bd469ec62 100644 --- a/helmchart/sdp/templates/01.1-configmap-sdp.yaml +++ b/helmchart/sdp/templates/01.1-configmap-sdp.yaml @@ -32,6 +32,7 @@ data: CONSUMER_GROUP_ID: {{ .Values.global.eventBroker.consumerGroupId | quote }} {{- if eq .Values.global.eventBroker.type "KAFKA" }} KAFKA_SECURITY_PROTOCOL: {{ .Values.global.eventBroker.kafka.securityProtocol | quote }} + SINGLE_TENANT_MODE: {{ .Values.global.singleTenantMode | quote }} {{- end }} {{- tpl (toYaml .Values.sdp.configMap.data | nindent 2) . }} {{- end }} diff --git a/helmchart/sdp/templates/01.4-configmap-dashboard.yaml b/helmchart/sdp/templates/01.4-configmap-dashboard.yaml index 7fd61c67d..539b1b80d 100644 --- a/helmchart/sdp/templates/01.4-configmap-dashboard.yaml +++ b/helmchart/sdp/templates/01.4-configmap-dashboard.yaml @@ -23,10 +23,11 @@ data: {{- end }} {{- if eq (include "isPubnet" .) "true" }} HORIZON_URL: "https://horizon.stellar.org", - STELLAR_EXPERT_URL: "https://stellar.expert/explorer/pubnet" + STELLAR_EXPERT_URL: "https://stellar.expert/explorer/pubnet", {{- else }} HORIZON_URL: "https://horizon-testnet.stellar.org", - STELLAR_EXPERT_URL: "https://stellar.expert/explorer/testnet" + STELLAR_EXPERT_URL: "https://stellar.expert/explorer/testnet", {{- end }} + SINGLE_TENANT_MODE: {{ .Values.global.singleTenantMode }} }; {{- end }} diff --git a/helmchart/sdp/values.yaml b/helmchart/sdp/values.yaml index 46b64fc8d..1315287b4 100644 --- a/helmchart/sdp/values.yaml +++ b/helmchart/sdp/values.yaml @@ -77,6 +77,9 @@ global: kafka: securityProtocol: #required + ## @param global.singleTenantMode Determines if the SDP service is running in single-tenant mode. + singleTenantMode: false + # =========================== START sdp =========================== ## @section Stellar Disbursement Platform (SDP) parameters ## @descriptionStart