2021-12-25 16:59:12 +00:00
|
|
|
## Usage and Components
|
2021-12-25 15:04:59 +00:00
|
|
|
|
2021-12-25 18:18:54 +00:00
|
|
|
Note: as of 2021-12-25 this chart is available internally as apps/prod/matrix.
|
|
|
|
|
|
|
|
|
2021-12-25 17:27:20 +00:00
|
|
|
### Sample usage
|
|
|
|
|
|
|
|
Setting up matrix for ...
|
|
|
|
|
|
|
|
- the matrix domain "fn.nf"
|
|
|
|
- the homeserver matrix.fnnf.svc.p10.k8s.ooo
|
2021-12-25 17:50:33 +00:00
|
|
|
- element web on m.fn.nf
|
2021-12-25 17:27:20 +00:00
|
|
|
|
|
|
|
Using automatic DNS from the p10.k8s.ooo cluster:
|
|
|
|
|
|
|
|
```
|
|
|
|
helm upgrade --install --create-namespace --namespace fnnf \
|
2021-12-25 17:50:33 +00:00
|
|
|
--set homeServerFQDN=fn.nf,elementWebFQDN=m.fn.nf,letsencryptStaging=no,clusterDomain=p10.k8s.ooo matrix matrix/
|
2021-12-25 17:27:20 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
Setting up matrix.fn.nf in DNS
|
|
|
|
|
|
|
|
```
|
|
|
|
matrix CNAME matrix-element-web.fnnf.svc.p10.k8s.ooo.
|
|
|
|
```
|
|
|
|
|
2021-12-25 17:50:33 +00:00
|
|
|
Creating the two json files
|
|
|
|
* /.well-known/matrix/server and
|
|
|
|
* /.well-known/matrix/client
|
|
|
|
on the fn.nf web server using the samples:
|
|
|
|
|
2021-12-25 18:10:03 +00:00
|
|
|
```
|
|
|
|
% curl -Ls https://m.fn.nf/.well-known/matrix/server > server
|
|
|
|
% curl -Ls https://m.fn.nf/.well-known/matrix/client > client
|
|
|
|
```
|
|
|
|
|
|
|
|
And finally creating a user:
|
2021-12-25 17:50:33 +00:00
|
|
|
|
2021-12-25 18:10:03 +00:00
|
|
|
```
|
2021-12-25 18:11:09 +00:00
|
|
|
kubectl -n fnnf exec -ti matrix-matrix-synapse-864c4bfb4-4h4cn -c synapse -- register_new_matrix_user http://localhost:8008 -c /config/homeserver.yaml -u admin -p ... -a
|
2021-12-25 18:10:03 +00:00
|
|
|
```
|
2021-12-25 17:27:20 +00:00
|
|
|
|
2021-12-25 15:04:59 +00:00
|
|
|
### Element-Web
|
|
|
|
|
|
|
|
* Includes config.json that is being populated by values.yaml
|
|
|
|
* Includes nginx on port localhost:8080 (http)
|
|
|
|
* Includes nginx proxy on port 80+443 (http redirect, https)
|
2021-12-25 16:34:19 +00:00
|
|
|
|
2021-12-25 16:59:12 +00:00
|
|
|
The service is reachable as `{{ .Release.Name }}-element-web`.
|
|
|
|
|
2021-12-25 16:34:19 +00:00
|
|
|
### Synapse
|
|
|
|
|
|
|
|
* homeserver.yaml is created from a ConfigMap in /config-ro
|
|
|
|
* homeserver.yaml is edited using sed to add the postgres password and
|
|
|
|
stored in /config/homeserver.yaml
|
|
|
|
* Logging configured to stdout
|
|
|
|
|
2021-12-25 16:59:12 +00:00
|
|
|
The service is reachable as `{{ .Release.Name }}`.
|
|
|
|
|
2021-12-25 16:34:19 +00:00
|
|
|
### Postgres
|
|
|
|
|
|
|
|
Tuned with `--no-locale --encoding=UTF8` using `POSTGRES_INITDB_ARGS` (required by synapse).
|
|
|
|
|
2021-12-25 16:59:12 +00:00
|
|
|
The service is reachable as `{{ .Release.Name }}-postgres`.
|
|
|
|
|
2021-12-25 16:34:19 +00:00
|
|
|
See
|
|
|
|
|
|
|
|
* https://www.postgresql.org/docs/9.5/app-initdb.html
|
|
|
|
* https://hub.docker.com/_/postgres
|
|
|
|
* https://github.com/matrix-org/synapse/blob/develop/docs/postgres.md
|
2021-12-25 16:59:12 +00:00
|
|
|
|
|
|
|
|
|
|
|
## Missing
|
|
|
|
|
|
|
|
- SMTP settings / secrets (ungleich mail + sops?)
|
|
|
|
|
|
|
|
### admin user
|
|
|
|
|
|
|
|
docker exec -it synapse register_new_matrix_user http://localhost:8008 -c /data/homeserver.yaml --help
|
2021-12-25 17:27:20 +00:00
|
|
|
|
|
|
|
### Resource configuration
|