[docker] update matrix docker-compose for Task#11983

This commit is contained in:
kjg 2023-09-08 14:23:45 +00:00
parent 8e972990cf
commit ee39fb4449
4 changed files with 3024 additions and 1 deletions

View file

@ -5,18 +5,28 @@ services:
restart: unless-stopped restart: unless-stopped
environment: environment:
- SYNAPSE_CONFIG_PATH=/data/homeserver.yaml - SYNAPSE_CONFIG_PATH=/data/homeserver.yaml
- SERVERNAME=${homeServerFQDN}
- PUBLICBASEURL=${synapseFQDN}
- ELEMENTWEB=${elementWebFQDN}
ports: ports:
- "8008:8008/tcp" - "8008:8008/tcp"
volumes: volumes:
- ./synapse:/data - ./synapse:/data
entrypoint: sh -c "/data/homeserver.yaml.sh && chmod -R 775 /data && /start.py"
depends_on: depends_on:
- postgres - postgres
element: element:
image: vectorim/element-web:latest image: vectorim/element-web:latest
restart: unless-stopped restart: unless-stopped
environment:
- SERVERNAME=${homeServerFQDN}
- PUBLICBASEURL=${synapseFQDN}
- ELEMENTWEB=${elementWebFQDN}
volumes: volumes:
- ./element-config.json:/app/config.json - ./element/config.json.sh:/app/config.json.sh
command: sh -c "/app/config.json.sh && nginx -g 'daemon off;'"
#entrypoint: /app/config.json.sh
ports: ports:
- "80:80/tcp" - "80:80/tcp"

55
element/config.json.sh Executable file
View file

@ -0,0 +1,55 @@
#!/bin/sh
/docker-entrypoint.sh
cat << EOF > /app/config.json
{
"default_server_config": {
"m.homeserver": {
"base_url": "https://$PUBLICBASEURL",
"server_name": "$SERVERNAME"
},
"m.identity_server": {
"base_url": "https://vector.im"
}
},
"disable_custom_urls": false,
"disable_guests": false,
"disable_login_language_selector": false,
"disable_3pid_login": false,
"brand": "Element",
"integrations_ui_url": "https://scalar.vector.im/",
"integrations_rest_url": "https://scalar.vector.im/api",
"integrations_widgets_urls": [
"https://scalar.vector.im/_matrix/integrations/v1",
"https://scalar.vector.im/api",
"https://scalar-staging.vector.im/_matrix/integrations/v1",
"https://scalar-staging.vector.im/api",
"https://scalar-staging.riot.im/scalar/api"
],
"default_country_code": "GB",
"show_labs_settings": false,
"features": {},
"default_federate": true,
"default_theme": "light",
"room_directory": {
"servers": ["matrix.org"]
},
"enable_presence_by_hs_url": {
"https://matrix.org": false,
"https://matrix-client.matrix.org": false
},
"setting_defaults": {
"breadcrumbs": true
},
"jitsi": {
"preferred_domain": "meet.element.io"
},
"element_call": {
"url": "https://call.element.io",
"participant_limit": 8,
"brand": "Element Call"
},
"map_style_url": "https://api.maptiler.com/maps/streets/style.json?key=fU3vlMsMn4Jb6dnEIFsx"
}
EOF

2925
synapse/synapse/homeserver.yaml.sh Executable file

File diff suppressed because it is too large Load diff

33
synapse/synapse/log.yaml Executable file
View file

@ -0,0 +1,33 @@
version: 1
formatters:
fmt:
format: '%(asctime)s - %(name)s - %(lineno)d - %(levelname)s - %(request)s- %(message)s'
filters:
context:
(): synapse.logging.context.LoggingContextFilter
request: ""
handlers:
console:
class: logging.StreamHandler
formatter: fmt
filters: [context]
root:
level: INFO
handlers: [console] # to use file handler instead, switch to [file]
loggers:
synapse:
level: INFO
synapse.storage.SQL:
level: INFO
ldap3:
level: INFO
ldap_auth_provider:
level: INFO