mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2024-09-06 23:11:58 +00:00
Make it clear that the image has two modes of operation
This commit is contained in:
parent
b9b668e4bb
commit
d8680c969b
@ -21,23 +21,42 @@ You may have a local Python wheel cache available, in which case copy the releva
|
|||||||
|
|
||||||
## Run
|
## Run
|
||||||
|
|
||||||
|
This image is designed to run either with an automatically generated configuration
|
||||||
|
file or with a custom configuration that requires manual edition.
|
||||||
|
|
||||||
|
### Automated configuration
|
||||||
|
|
||||||
It is recommended that you use Docker Compose to run your containers, including
|
It is recommended that you use Docker Compose to run your containers, including
|
||||||
this image and a Postgres server. A sample ``docker-compose.yml`` is provided,
|
this image and a Postgres server. A sample ``docker-compose.yml`` is provided,
|
||||||
including example labels for reverse proxying and other artifacts.
|
including example labels for reverse proxying and other artifacts.
|
||||||
|
|
||||||
Then, to run the server:
|
Read the section about environment variables and set at least mandatory variables,
|
||||||
|
then run the server:
|
||||||
|
|
||||||
```
|
```
|
||||||
docker-compose up -d
|
docker-compose up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
In the case you specify a custom path for you configuration file and wish to
|
### Manual configuration
|
||||||
generate a fresh ``homeserver.yaml``, simply run:
|
|
||||||
|
A sample ``docker-compose.yml`` is provided, including example labels for
|
||||||
|
reverse proxying and other artifacts.
|
||||||
|
|
||||||
|
Specify a ``SYNAPSE_CONFIG_PATH``, preferably to a persistent path,
|
||||||
|
to use manual configuration. To generate a fresh ``homeserver.yaml``, simply run:
|
||||||
|
|
||||||
```
|
```
|
||||||
docker-compose run --rm -e SYNAPSE_SERVER_NAME=my.matrix.host synapse generate
|
docker-compose run --rm -e SYNAPSE_SERVER_NAME=my.matrix.host synapse generate
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Then, customize your configuration and run the server:
|
||||||
|
|
||||||
|
```
|
||||||
|
docker-compose up -d
|
||||||
|
```
|
||||||
|
|
||||||
|
### Without Compose
|
||||||
|
|
||||||
If you do not wish to use Compose, you may still run this image using plain
|
If you do not wish to use Compose, you may still run this image using plain
|
||||||
Docker commands. Note that the following is just a guideline and you may need
|
Docker commands. Note that the following is just a guideline and you may need
|
||||||
to add parameters to the docker run command to account for the network situation
|
to add parameters to the docker run command to account for the network situation
|
||||||
@ -49,10 +68,10 @@ docker run \
|
|||||||
--name synapse \
|
--name synapse \
|
||||||
-v ${DATA_PATH}:/data \
|
-v ${DATA_PATH}:/data \
|
||||||
-e SYNAPSE_SERVER_NAME=my.matrix.host \
|
-e SYNAPSE_SERVER_NAME=my.matrix.host \
|
||||||
matrixdotorg/synapse:latest
|
-e SYNAPSE_REPORT_STATS=yes \
|
||||||
|
docker.io/matrixdotorg/synapse:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## Volumes
|
## Volumes
|
||||||
|
|
||||||
The image expects a single volume, located at ``/data``, that will hold:
|
The image expects a single volume, located at ``/data``, that will hold:
|
||||||
|
Loading…
Reference in New Issue
Block a user