Add instructions to setup db locally

This commit is contained in:
Germain
2023-03-09 09:33:05 +00:00
committed by Quentin Gliech
parent 9675b64313
commit 3e4e057658

View File

@@ -27,6 +27,11 @@ See the [Documentation](https://matrix-org.github.io/matrix-authentication-servi
cd ..
```
- Generate the sample config via `cargo run -- config generate > config.yaml`
- Run a PostgreSQL database locally
```sh
docker run -p 5432:5432 -e 'POSTGRES_USER=postgres' -e 'POSTGRES_PASSWORD=postgres' -e 'POSTGRES_DATABASE=postgres' postgres
```
- Update the database URI in `config.yaml` to `postgresql://postgres:postgres@localhost/postgres`
- Run the database migrations via `cargo run -- database migrate`
- Run the server via `cargo run -- server -c config.yaml`
- Go to <http://localhost:8080/>