UNPKG

@fairmint/canton-node-sdk

Version:
115 lines (113 loc) 3.87 kB
# Copyright (c) 2024 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved. # SPDX-License-Identifier: Apache-2.0 {{ if .Values.validatorWebUi.enabled }} {{- $walletWebUiLabel := "wallet-web-ui" }} apiVersion: apps/v1 kind: Deployment metadata: labels: {{- include "splice-util-lib.default-labels" (set . "app" $walletWebUiLabel) | nindent 4 }} migration: {{ .Values.migration.id | quote }} name: {{ $walletWebUiLabel }} namespace: {{ .Release.Namespace }} spec: replicas: 1 selector: matchLabels: app: {{ $walletWebUiLabel }} strategy: type: Recreate template: metadata: annotations: {{- toYaml .Values.pod.annotations | nindent 8 }} labels: {{- include "splice-util-lib.default-labels" (set . "app" $walletWebUiLabel) | nindent 8 }} migration: {{ .Values.migration.id | quote }} spec: {{- include "splice-util-lib.service-account" .Values | nindent 6 }} containers: - env: - name: SPLICE_APP_UI_NETWORK_NAME value: {{ .Values.spliceInstanceNames.networkName | quote }} - name: SPLICE_APP_UI_NETWORK_FAVICON_URL value: {{ .Values.spliceInstanceNames.networkFaviconUrl | quote }} - name: SPLICE_APP_UI_AMULET_NAME value: {{ .Values.spliceInstanceNames.amuletName | quote }} - name: SPLICE_APP_UI_AMULET_NAME_ACRONYM value: {{ .Values.spliceInstanceNames.amuletNameAcronym | quote }} - name: SPLICE_APP_UI_NAME_SERVICE_NAME value: {{ .Values.spliceInstanceNames.nameServiceName | quote }} - name: SPLICE_APP_UI_NAME_SERVICE_NAME_ACRONYM value: {{ .Values.spliceInstanceNames.nameServiceNameAcronym | quote }} - name: SPLICE_APP_UI_POLL_INTERVAL value: {{ .Values.uiPollInterval | quote }} {{- if .Values.disableAuth }} - name: SPLICE_APP_UI_UNSAFE value: "true" - name: SPLICE_APP_UI_UNSAFE_SECRET value: "unsafe" - name: SPLICE_APP_UI_AUTH_AUDIENCE value: "https://validator.example.com" {{- else }} - name: SPLICE_APP_UI_AUTH_URL valueFrom: secretKeyRef: key: url name: splice-app-wallet-ui-auth optional: false - name: SPLICE_APP_UI_AUTH_AUDIENCE value: {{ .Values.auth.audience | quote }} - name: SPLICE_APP_UI_AUTH_CLIENT_ID valueFrom: secretKeyRef: key: client-id name: splice-app-wallet-ui-auth optional: false {{- end }} image: "{{ .Values.imageRepo }}/wallet-web-ui:{{ .Chart.AppVersion }}{{ ((.Values.imageDigests).wallet_web_ui) }}" {{- with .Values.imagePullPolicy }} imagePullPolicy: {{ . }} {{- end }} name: wallet-web-ui ports: - containerPort: 8080 name: http protocol: TCP resources: requests: cpu: 0.1 memory: 240Mi limits: cpu: 1 memory: 1536Mi {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }} --- apiVersion: v1 kind: Service metadata: name: {{ $walletWebUiLabel }} namespace: {{ .Release.Namespace }} labels: {{- include "splice-util-lib.default-labels" (set . "app" $walletWebUiLabel) | nindent 4 }} migration: {{ .Values.migration.id | quote }} spec: selector: app: {{ $walletWebUiLabel }} ports: - name: http port: {{ .Values.service.wallet.port }} targetPort: http protocol: TCP {{- end }}