Added synapse app service in development environment and code cleanup

This commit is contained in:
2021-04-23 13:06:59 +02:00
parent 10402f4de0
commit 1bc49eacc2
5 changed files with 20 additions and 14 deletions

View File

@@ -6,7 +6,7 @@ THIS PROJECT IS IN EARLY DEVELOPMENT - WORK IN PROGRESS (including this README)
## Prerequisites
Install and run keycloak and synapse.
You can find some docker-compose files in docker folder.
`docker/README` explains how to get a working local development environment.
## How to run
1. `git clone git@git.fosil.eu:eneko/okupamicoche.git`

View File

@@ -1,5 +1,5 @@
# Okupa mi coche - Docker containers for the backend
Guide for seting up development environment for the backend.
Guide for seting up a local development environment for the backend.
## Setup
1. Install Docker in local machine
@@ -34,7 +34,8 @@ docker run -it --rm \
```
docker run --name okupamicoche-synapse -p 8008:8008 --mount type=volume,src=synapse-data,dst=/data \
-e SYNAPSE_CONFIG_PATH=/homeserver.yaml \
-v $(pwd)/homeserver.yaml:/homeserver.yaml --network=okupamicoche okupamicoche-synapse
-v $(pwd)/homeserver.yaml:/homeserver.yaml -v $(pwd)/okupamicoche-appservice.yaml:/okupamicoche-appservice.yaml \
--network=okupamicoche okupamicoche-synapse
```
## Run

View File

@@ -9,13 +9,6 @@ listeners:
resources:
- names: [ client, federation ]
compress: false
acme:
enabled: false
port: 80
bind_addresses: [ '::', '0.0.0.0' ]
reprovision_threshold: 30
domain: matrix.example.com
account_key_file: /data/acme_account.key
database:
name: sqlite3
args:
@@ -27,7 +20,6 @@ report_stats: false
macaroon_secret_key: "6VvBQj_TedGcDDB_z,-qXV1W3:.CXrRG6AWF&4p:~iGNguy&_h"
form_secret: "FM,2TSq++sZ@Tl0atcQP"
signing_key_path: "/data/okupamicoche-synapse.signing.key"
old_signing_keys:
trusted_key_servers:
- server_name: "matrix.org"
oidc_providers:
@@ -43,4 +35,6 @@ oidc_providers:
display_name_template: "{{ user.name }}"
sso:
client_whitelist:
- http://localhost:4200/
- http://localhost:4200/
app_service_config_files:
- /okupamicoche-appservice.yaml

View File

@@ -0,0 +1,11 @@
id: "Okupa mi coche"
url: "http://172.17.0.1:8081"
as_token: "30c05ae90a248a4188e620216fa72e349803310ec83e2a77b34fe90be6081f46"
hs_token: "312df522183efd404ec1cd22d2ffa4bbc76a8c1ccf541dd692eef281356bb74e"
sender_localpart: "okupamicoche"
namespaces:
users: [ ]
aliases:
- regex: "#viaje_.*"
exclusive: true
rooms: [ ]

View File

@@ -25,7 +25,7 @@ logging:
matrix:
bot:
# The domain-part of matrix-ids. E. g. example.org when your userIds look like @unicorn:example.org
serverName: synapse
serverName: okupamicoche-synapse
# The localpart (username) of the user associated with the application service
# or just the username of your bot.
username: okupamicoche
@@ -54,7 +54,7 @@ matrix:
client:
homeServer:
# The hostname of your Homeserver.
hostname: synapse
hostname: okupamicoche-synapse
# (optional) The port of your Homeserver. Default is 443.
port: 8008
# (optional) Use http or https. Default is true (so uses https).