... |
... |
@@ -18,57 +18,81 @@ spec: |
18
|
18
|
app: synapse
|
19
|
19
|
tier: backend
|
20
|
20
|
spec:
|
21
|
|
- initContainers:
|
22
|
|
- - name: render-synapse-config
|
23
|
|
- image: alpine
|
24
|
|
- command: ['sh', '-c', 'echo "${HOMESERVER_YAML}" > /data/homeserver.yaml && echo "${LOG_CONFIG}" > /data/matrix.c3sl.ufpr.br.log.config']
|
25
|
|
- volumeMounts:
|
26
|
|
- - name: synapse-persistent-storage
|
27
|
|
- mountPath: /data
|
28
|
|
- env:
|
29
|
|
- - name: HOMESERVER_YAML
|
30
|
|
- valueFrom:
|
31
|
|
- secretKeyRef:
|
32
|
|
- name: matrix
|
33
|
|
- key: synapseHomeserverYaml
|
34
|
|
- - name: LOG_CONFIG
|
35
|
|
- valueFrom:
|
36
|
|
- secretKeyRef:
|
37
|
|
- name: matrix
|
38
|
|
- key: synapseLogConfig
|
39
|
|
- - name: fix-perms
|
40
|
|
- image: alpine
|
41
|
|
- command: ['sh', '-c', 'chown -R 991:991 /data && chmod -R 700 /data']
|
42
|
|
- volumeMounts:
|
43
|
|
- - name: synapse-persistent-storage
|
44
|
|
- mountPath: /data
|
45
|
21
|
containers:
|
46
|
22
|
- image: harbor.c3sl.ufpr.br/root/synapse
|
47
|
23
|
name: synapse
|
48
|
24
|
env:
|
49
|
25
|
- name: SYNAPSE_SERVER_NAME
|
50
|
26
|
value: matrix.c3sl.ufpr.br
|
51
|
|
- - name: SYNAPSE_REPORT_STATS
|
52
|
|
- value: 'no'
|
|
27
|
+ - containerPort: 8008
|
|
28
|
+ name: synapse
|
|
29
|
+ # ======== POSTGRES ======== #
|
53
|
30
|
- name: POSTGRES_HOST
|
54
|
|
- value: postgres.c3sl.ufpr.br
|
|
31
|
+ valueFrom:
|
|
32
|
+ secretKeyRef:
|
|
33
|
+ name: matrix
|
|
34
|
+ key: synapsePostgresHost
|
55
|
35
|
- name: POSTGRES_USER
|
56
|
|
- value: synapse
|
|
36
|
+ valueFrom:
|
|
37
|
+ secretKeyRef:
|
|
38
|
+ name: matrix
|
|
39
|
+ key: synapsePostgresUser
|
57
|
40
|
- name: POSTGRES_DB
|
58
|
|
- value: synapse
|
|
41
|
+ valueFrom:
|
|
42
|
+ secretKeyRef:
|
|
43
|
+ name: matrix
|
|
44
|
+ key: synapsePostgresDatabase
|
59
|
45
|
- name: POSTGRES_PASSWORD
|
60
|
46
|
valueFrom:
|
61
|
47
|
secretKeyRef:
|
62
|
|
- name: synapse-postgres
|
63
|
|
- key: password
|
64
|
|
- ports:
|
65
|
|
- - containerPort: 8008
|
66
|
|
- name: synapse
|
|
48
|
+ name: matrix
|
|
49
|
+ key: synapsePostgresPassword
|
|
50
|
+ # ======== OPENID ======== #
|
|
51
|
+ - name: OIDC_IDP_NAME
|
|
52
|
+ value: DInf/C3SL
|
|
53
|
+ - name: OIDC_ISSUER
|
|
54
|
+ value: https://keycloak.c3sl.ufpr.br/realms/DInfC3SL
|
|
55
|
+ - name: OIDC_CLIENT_ID
|
|
56
|
+ valueFrom:
|
|
57
|
+ secretKeyRef:
|
|
58
|
+ name: matrix
|
|
59
|
+ key: synapseOidcClientId
|
|
60
|
+ - name: OIDC_CLIENT_SECREt
|
|
61
|
+ valueFrom:
|
|
62
|
+ secretKeyRef:
|
|
63
|
+ name: matrix
|
|
64
|
+ key: synapseOidcClientSecret
|
|
65
|
+ # ======== S3 ======== #
|
|
66
|
+ - name: S3_BUCKET_NAME
|
|
67
|
+ valueFrom:
|
|
68
|
+ secretKeyRef:
|
|
69
|
+ name: matrix
|
|
70
|
+ key: synapseS3BucketName
|
|
71
|
+ - name: S3_REGION_NAME
|
|
72
|
+ valueFrom:
|
|
73
|
+ secretKeyRef:
|
|
74
|
+ name: matrix
|
|
75
|
+ key: synapseS3RegionName
|
|
76
|
+ - name: S3_ENDPOINT_URL
|
|
77
|
+ valueFrom:
|
|
78
|
+ secretKeyRef:
|
|
79
|
+ name: matrix
|
|
80
|
+ key: synapseS3EndpointURL
|
|
81
|
+ - name: S3_ACCESS_KEY_ID
|
|
82
|
+ valueFrom:
|
|
83
|
+ secretKeyRef:
|
|
84
|
+ name: matrix
|
|
85
|
+ key: synapseS3AccessKeyId
|
|
86
|
+ - name: S3_SECRET_ACCESS_KEY
|
|
87
|
+ valueFrom:
|
|
88
|
+ secretKeyRef:
|
|
89
|
+ name: matrix
|
|
90
|
+ key: synapseS3SecretAccessKey
|
67
|
91
|
volumeMounts:
|
68
|
|
- - name: synapse-persistent-storage
|
|
92
|
+ - name: synapse-data
|
69
|
93
|
mountPath: /data
|
70
|
94
|
volumes:
|
71
|
|
- - name: synapse-persistent-storage
|
|
95
|
+ - name: synapse-data
|
72
|
96
|
persistentVolumeClaim:
|
73
|
97
|
claimName: synapse
|
74
|
98
|
---
|
... |
... |
@@ -93,19 +117,6 @@ spec: |
93
|
117
|
app: element
|
94
|
118
|
tier: frontend
|
95
|
119
|
spec:
|
96
|
|
- initContainers:
|
97
|
|
- - name: set-configjson
|
98
|
|
- image: alpine
|
99
|
|
- command: ['sh', '-c', 'echo "${CONFIG_JSON}" > /app/config.json']
|
100
|
|
- volumeMounts:
|
101
|
|
- - name: element
|
102
|
|
- mountPath: /app/
|
103
|
|
- env:
|
104
|
|
- - name: CONFIG_JSON
|
105
|
|
- valueFrom:
|
106
|
|
- secretKeyRef:
|
107
|
|
- name: matrix
|
108
|
|
- key: elementConfigJson
|
109
|
120
|
containers:
|
110
|
121
|
- image: vectorim/element-web
|
111
|
122
|
name: element
|
... |
... |
@@ -113,9 +124,10 @@ spec: |
113
|
124
|
- containerPort: 80
|
114
|
125
|
name: element
|
115
|
126
|
volumeMounts:
|
116
|
|
- - name: element
|
117
|
|
- mountPath: /app/
|
|
127
|
+ - name: element-config
|
|
128
|
+ mountPath: /app/config.json
|
|
129
|
+ subPath: elementConfigJson
|
118
|
130
|
volumes:
|
119
|
|
- - name: element
|
120
|
|
- persistentVolumeClaim:
|
121
|
|
- claimName: element |
|
131
|
+ - name: element-config
|
|
132
|
+ secret:
|
|
133
|
+ secretName: matrix |