-
Notifications
You must be signed in to change notification settings - Fork 37
Expand file tree
/
Copy pathconfigmap.yml
More file actions
57 lines (56 loc) · 2.54 KB
/
configmap.yml
File metadata and controls
57 lines (56 loc) · 2.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{{- $dbHost := .Values.db.host -}}
{{- if eq $dbHost "" -}}
{{- $dbHost = printf "%s-postgresql-ha-pgpool.%s.svc.cluster.local" .Release.Name .Release.Namespace -}}
{{- end -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "netmaker.fullname" . }}-env
data:
BROKER_ENDPOINT: "wss://{{ .Values.ingress.hostPrefix.broker }}.{{ required "A valid .Values.baseDomain entry required!" .Values.baseDomain}}"
SERVER_NAME: "{{ required "A valid .Values.baseDomain entry required!" .Values.baseDomain}}"
STUN_LIST: "stun1.netmaker.io:3478,stun2.netmaker.io:3478,stun1.l.google.com:19302,stun2.l.google.com:19302"
SERVER_HOST: "SERVER_PUBLIC_IP"
SERVER_API_CONN_STRING: "{{ .Values.ingress.hostPrefix.rest }}.{{ required "A valid .Values.baseDomain entry required!" .Values.baseDomain}}:443"
COREDNS_ADDR: "SERVER_PUBLIC_IP"
DNS_MODE: "on"
SERVER_HTTP_HOST: "{{ .Values.ingress.hostPrefix.rest }}.{{ required "A valid .Values.baseDomain entry required!" .Values.baseDomain}}"
API_PORT: "8081"
MESSAGEQUEUE_BACKEND: "on"
MASTER_KEY: "{{ .Values.server.masterKey }}"
CORS_ALLOWED_ORIGIN: "*"
DISPLAY_KEYS: "on"
DATABASE: "{{ .Values.db.type }}"
SERVER_BROKER_ENDPOINT: "ws://{{ .Release.Name }}-mqtt.{{ .Release.Namespace }}.svc.cluster.local:1883"
VERBOSITY: "1"
K8s: "true"
MQ_PASSWORD: "{{ .Values.mq.password }}"
MQ_USERNAME: "{{ .Values.mq.username }}"
LICENSE_KEY: "{{ .Values.server.ee.licensekey }}" # needed if EE
NETMAKER_TENANT_ID: "{{ .Values.server.ee.tenantId }}" # needed if EE
{{- if not .Values.db.existingSecret.enabled }}
SQL_HOST: "{{ $dbHost }}"
SQL_PORT: "{{ .Values.db.port }}"
SQL_DB: "{{ .Values.db.database }}"
SQL_USER: "{{ .Values.db.username }}"
SQL_PASS: "{{ .Values.db.password }}"
{{- end }}
SQL_SSL_MODE: "{{ .Values.db.sslmode }}"
JWT_VALIDITY_DURATION: "{{ .Values.server.jwtDuration }}"
RAC_AUTO_DISABLE: "{{ .Values.server.racAutoDisable }}"
CACHING_ENABLED: "false" # should be false for HA to work
AUTH_PROVIDER: "{{ .Values.server.authProvider }}"
CLIENT_ID: "{{ .Values.server.oAuthclientID }}"
CLIENT_SECRET: "{{ .Values.server.oAuthClientSecret }}"
FRONTEND_URL: "{{ .Values.server.frontendURL }}"
AZURE_TENANT: "{{ .Values.server.azureTenant }}"
OIDC_ISSUER: "{{ .Values.server.oidcIssuer }}"
IS_HA: "true"
{{- if .Values.server.turn.enabled -}}
TURN_SERVER_HOST: "REPLACE_TURN_HOST"
TURN_SERVER_API_HOST: "REPLACE_TURN_API_HOST"
TURN_PORT: "REPLACE_TURN_PORT"
TURN_USERNAME: "REPLACE_TURN_USER"
TURN_PASSWORD: "REPLACE_TURN_PASS"
USE_TURN: "true"
{{- end -}}