2022-05-06 07:04:51 +00:00
|
|
|
# Configuration
|
|
|
|
|
2022-11-27 01:53:06 +00:00
|
|
|
## General
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Domain
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Hostname the relay will be hosted on.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
domain: relay.example.com
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
2022-11-27 01:53:06 +00:00
|
|
|
### Listener
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
The address and port the relay will listen on. If the reverse proxy (nginx, apache, caddy, etc)
|
2024-01-24 05:48:15 +00:00
|
|
|
is running on the same host, it is recommended to change `listen` to `localhost` if the reverse
|
|
|
|
proxy is on the same host.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
listen: 0.0.0.0
|
|
|
|
port: 8080
|
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Push Workers
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
The relay can be configured to use threads to push messages out. For smaller relays, this isn't
|
|
|
|
necessary, but bigger ones (>100 instances) will want to set this to the number of available cpu
|
|
|
|
threads.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
workers: 0
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Database type
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
SQL database backend to use. Valid values are `sqlite` or `postgres`.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
database_type: sqlite
|
2022-11-27 01:53:06 +00:00
|
|
|
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Sqlite File Path
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Path to the sqlite database file. If the path is not absolute, it is relative to the config file.
|
|
|
|
directory.
|
2022-11-27 01:53:06 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
sqlite_path: relay.jsonld
|
2022-11-27 01:53:06 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
## Postgresql
|
2022-11-27 01:53:06 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
In order to use the Postgresql backend, the user and database need to be created first.
|
2022-11-27 01:53:06 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
sudo -u postgres psql -c "CREATE USER activityrelay"
|
|
|
|
sudo -u postgres psql -c "CREATE DATABASE activityrelay OWNER activityrelay"
|
2022-11-27 01:53:06 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Database Name
|
2022-11-27 01:53:06 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Name of the database to use.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
name: activityrelay
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
|
|
|
### Host
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Hostname, IP address, or unix socket the server is hosted on.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
host: /var/run/postgresql
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Port
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Port number the server is listening on.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
port: 5432
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Username
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
User to use when logging into the server.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
user: null
|
2022-05-06 07:04:51 +00:00
|
|
|
|
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
### Password
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
Password for the specified user.
|
2022-05-06 07:04:51 +00:00
|
|
|
|
2024-01-24 05:48:15 +00:00
|
|
|
pass: null
|