sample_config.yaml 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113
  1. # The config is maintained as an up-to-date snapshot of the default
  2. # homeserver.yaml configuration generated by Synapse.
  3. #
  4. # It is intended to act as a reference for the default configuration,
  5. # helping admins keep track of new options and other changes, and compare
  6. # their configs with the current default. As such, many of the actual
  7. # config values shown are placeholders.
  8. #
  9. # It is *not* intended to be copied and used as the basis for a real
  10. # homeserver.yaml. Instead, if you are starting from scratch, please generate
  11. # a fresh config using Synapse by following the instructions in INSTALL.md.
  12. ## Server ##
  13. # The domain name of the server, with optional explicit port.
  14. # This is used by remote servers to connect to this server,
  15. # e.g. matrix.org, localhost:8080, etc.
  16. # This is also the last part of your UserID.
  17. #
  18. server_name: "SERVERNAME"
  19. # When running as a daemon, the file to store the pid in
  20. #
  21. pid_file: DATADIR/homeserver.pid
  22. # CPU affinity mask. Setting this restricts the CPUs on which the
  23. # process will be scheduled. It is represented as a bitmask, with the
  24. # lowest order bit corresponding to the first logical CPU and the
  25. # highest order bit corresponding to the last logical CPU. Not all CPUs
  26. # may exist on a given system but a mask may specify more CPUs than are
  27. # present.
  28. #
  29. # For example:
  30. # 0x00000001 is processor #0,
  31. # 0x00000003 is processors #0 and #1,
  32. # 0xFFFFFFFF is all processors (#0 through #31).
  33. #
  34. # Pinning a Python process to a single CPU is desirable, because Python
  35. # is inherently single-threaded due to the GIL, and can suffer a
  36. # 30-40% slowdown due to cache blow-out and thread context switching
  37. # if the scheduler happens to schedule the underlying threads across
  38. # different cores. See
  39. # https://www.mirantis.com/blog/improve-performance-python-programs-restricting-single-cpu/.
  40. #
  41. # This setting requires the affinity package to be installed!
  42. #
  43. #cpu_affinity: 0xFFFFFFFF
  44. # The path to the web client which will be served at /_matrix/client/
  45. # if 'webclient' is configured under the 'listeners' configuration.
  46. #
  47. #web_client_location: "/path/to/web/root"
  48. # The public-facing base URL that clients use to access this HS
  49. # (not including _matrix/...). This is the same URL a user would
  50. # enter into the 'custom HS URL' field on their client. If you
  51. # use synapse with a reverse proxy, this should be the URL to reach
  52. # synapse via the proxy.
  53. #
  54. #public_baseurl: https://example.com/
  55. # Set the soft limit on the number of file descriptors synapse can use
  56. # Zero is used to indicate synapse should set the soft limit to the
  57. # hard limit.
  58. #
  59. #soft_file_limit: 0
  60. # Set to false to disable presence tracking on this homeserver.
  61. #
  62. #use_presence: false
  63. # The GC threshold parameters to pass to `gc.set_threshold`, if defined
  64. #
  65. #gc_thresholds: [700, 10, 10]
  66. # Set the limit on the returned events in the timeline in the get
  67. # and sync operations. The default value is -1, means no upper limit.
  68. #
  69. #filter_timeline_limit: 5000
  70. # Whether room invites to users on this server should be blocked
  71. # (except those sent by local server admins). The default is False.
  72. #
  73. #block_non_admin_invites: True
  74. # Room searching
  75. #
  76. # If disabled, new messages will not be indexed for searching and users
  77. # will receive errors when searching for messages. Defaults to enabled.
  78. #
  79. #enable_search: false
  80. # Restrict federation to the following whitelist of domains.
  81. # N.B. we recommend also firewalling your federation listener to limit
  82. # inbound federation traffic as early as possible, rather than relying
  83. # purely on this application-layer restriction. If not specified, the
  84. # default is to whitelist everything.
  85. #
  86. #federation_domain_whitelist:
  87. # - lon.example.com
  88. # - nyc.example.com
  89. # - syd.example.com
  90. # List of ports that Synapse should listen on, their purpose and their
  91. # configuration.
  92. #
  93. # Options for each listener include:
  94. #
  95. # port: the TCP port to bind to
  96. #
  97. # bind_addresses: a list of local addresses to listen on. The default is
  98. # 'all local interfaces'.
  99. #
  100. # type: the type of listener. Normally 'http', but other valid options are:
  101. # 'manhole' (see docs/manhole.md),
  102. # 'metrics' (see docs/metrics-howto.rst),
  103. # 'replication' (see docs/workers.rst).
  104. #
  105. # tls: set to true to enable TLS for this listener. Will use the TLS
  106. # key/cert specified in tls_private_key_path / tls_certificate_path.
  107. #
  108. # x_forwarded: Only valid for an 'http' listener. Set to true to use the
  109. # X-Forwarded-For header as the client IP. Useful when Synapse is
  110. # behind a reverse-proxy.
  111. #
  112. # resources: Only valid for an 'http' listener. A list of resources to host
  113. # on this port. Options for each resource are:
  114. #
  115. # names: a list of names of HTTP resources. See below for a list of
  116. # valid resource names.
  117. #
  118. # compress: set to true to enable HTTP comression for this resource.
  119. #
  120. # additional_resources: Only valid for an 'http' listener. A map of
  121. # additional endpoints which should be loaded via dynamic modules.
  122. #
  123. # Valid resource names are:
  124. #
  125. # client: the client-server API (/_matrix/client). Also implies 'media' and
  126. # 'static'.
  127. #
  128. # consent: user consent forms (/_matrix/consent). See
  129. # docs/consent_tracking.md.
  130. #
  131. # federation: the server-server API (/_matrix/federation). Also implies
  132. # 'media', 'keys', 'openid'
  133. #
  134. # keys: the key discovery API (/_matrix/keys).
  135. #
  136. # media: the media API (/_matrix/media).
  137. #
  138. # metrics: the metrics interface. See docs/metrics-howto.rst.
  139. #
  140. # openid: OpenID authentication.
  141. #
  142. # replication: the HTTP replication API (/_synapse/replication). See
  143. # docs/workers.rst.
  144. #
  145. # static: static resources under synapse/static (/_matrix/static). (Mostly
  146. # useful for 'fallback authentication'.)
  147. #
  148. # webclient: A web client. Requires web_client_location to be set.
  149. #
  150. listeners:
  151. # TLS-enabled listener: for when matrix traffic is sent directly to synapse.
  152. #
  153. # Disabled by default. To enable it, uncomment the following. (Note that you
  154. # will also need to give Synapse a TLS key and certificate: see the TLS section
  155. # below.)
  156. #
  157. #- port: 8448
  158. # type: http
  159. # tls: true
  160. # resources:
  161. # - names: [client, federation]
  162. # Unsecure HTTP listener: for when matrix traffic passes through a reverse proxy
  163. # that unwraps TLS.
  164. #
  165. # If you plan to use a reverse proxy, please see
  166. # https://github.com/matrix-org/synapse/blob/master/docs/reverse_proxy.rst.
  167. #
  168. - port: 8008
  169. tls: false
  170. bind_addresses: ['::1', '127.0.0.1']
  171. type: http
  172. x_forwarded: true
  173. resources:
  174. - names: [client, federation]
  175. compress: false
  176. # example additonal_resources:
  177. #
  178. #additional_resources:
  179. # "/_matrix/my/custom/endpoint":
  180. # module: my_module.CustomRequestHandler
  181. # config: {}
  182. # Turn on the twisted ssh manhole service on localhost on the given
  183. # port.
  184. #
  185. #- port: 9000
  186. # bind_addresses: ['::1', '127.0.0.1']
  187. # type: manhole
  188. ## Homeserver blocking ##
  189. # How to reach the server admin, used in ResourceLimitError
  190. #
  191. #admin_contact: 'mailto:admin@server.com'
  192. # Global blocking
  193. #
  194. #hs_disabled: False
  195. #hs_disabled_message: 'Human readable reason for why the HS is blocked'
  196. #hs_disabled_limit_type: 'error code(str), to help clients decode reason'
  197. # Monthly Active User Blocking
  198. #
  199. #limit_usage_by_mau: False
  200. #max_mau_value: 50
  201. #mau_trial_days: 2
  202. # If enabled, the metrics for the number of monthly active users will
  203. # be populated, however no one will be limited. If limit_usage_by_mau
  204. # is true, this is implied to be true.
  205. #
  206. #mau_stats_only: False
  207. # Sometimes the server admin will want to ensure certain accounts are
  208. # never blocked by mau checking. These accounts are specified here.
  209. #
  210. #mau_limit_reserved_threepids:
  211. # - medium: 'email'
  212. # address: 'reserved_user@example.com'
  213. ## TLS ##
  214. # PEM-encoded X509 certificate for TLS.
  215. # This certificate, as of Synapse 1.0, will need to be a valid and verifiable
  216. # certificate, signed by a recognised Certificate Authority.
  217. #
  218. # See 'ACME support' below to enable auto-provisioning this certificate via
  219. # Let's Encrypt.
  220. #
  221. # If supplying your own, be sure to use a `.pem` file that includes the
  222. # full certificate chain including any intermediate certificates (for
  223. # instance, if using certbot, use `fullchain.pem` as your certificate,
  224. # not `cert.pem`).
  225. #
  226. #tls_certificate_path: "CONFDIR/SERVERNAME.tls.crt"
  227. # PEM-encoded private key for TLS
  228. #
  229. #tls_private_key_path: "CONFDIR/SERVERNAME.tls.key"
  230. # ACME support: This will configure Synapse to request a valid TLS certificate
  231. # for your configured `server_name` via Let's Encrypt.
  232. #
  233. # Note that provisioning a certificate in this way requires port 80 to be
  234. # routed to Synapse so that it can complete the http-01 ACME challenge.
  235. # By default, if you enable ACME support, Synapse will attempt to listen on
  236. # port 80 for incoming http-01 challenges - however, this will likely fail
  237. # with 'Permission denied' or a similar error.
  238. #
  239. # There are a couple of potential solutions to this:
  240. #
  241. # * If you already have an Apache, Nginx, or similar listening on port 80,
  242. # you can configure Synapse to use an alternate port, and have your web
  243. # server forward the requests. For example, assuming you set 'port: 8009'
  244. # below, on Apache, you would write:
  245. #
  246. # ProxyPass /.well-known/acme-challenge http://localhost:8009/.well-known/acme-challenge
  247. #
  248. # * Alternatively, you can use something like `authbind` to give Synapse
  249. # permission to listen on port 80.
  250. #
  251. acme:
  252. # ACME support is disabled by default. Uncomment the following line
  253. # (and tls_certificate_path and tls_private_key_path above) to enable it.
  254. #
  255. #enabled: true
  256. # Endpoint to use to request certificates. If you only want to test,
  257. # use Let's Encrypt's staging url:
  258. # https://acme-staging.api.letsencrypt.org/directory
  259. #
  260. #url: https://acme-v01.api.letsencrypt.org/directory
  261. # Port number to listen on for the HTTP-01 challenge. Change this if
  262. # you are forwarding connections through Apache/Nginx/etc.
  263. #
  264. #port: 80
  265. # Local addresses to listen on for incoming connections.
  266. # Again, you may want to change this if you are forwarding connections
  267. # through Apache/Nginx/etc.
  268. #
  269. #bind_addresses: ['::', '0.0.0.0']
  270. # How many days remaining on a certificate before it is renewed.
  271. #
  272. #reprovision_threshold: 30
  273. # The domain that the certificate should be for. Normally this
  274. # should be the same as your Matrix domain (i.e., 'server_name'), but,
  275. # by putting a file at 'https://<server_name>/.well-known/matrix/server',
  276. # you can delegate incoming traffic to another server. If you do that,
  277. # you should give the target of the delegation here.
  278. #
  279. # For example: if your 'server_name' is 'example.com', but
  280. # 'https://example.com/.well-known/matrix/server' delegates to
  281. # 'matrix.example.com', you should put 'matrix.example.com' here.
  282. #
  283. # If not set, defaults to your 'server_name'.
  284. #
  285. #domain: matrix.example.com
  286. # List of allowed TLS fingerprints for this server to publish along
  287. # with the signing keys for this server. Other matrix servers that
  288. # make HTTPS requests to this server will check that the TLS
  289. # certificates returned by this server match one of the fingerprints.
  290. #
  291. # Synapse automatically adds the fingerprint of its own certificate
  292. # to the list. So if federation traffic is handled directly by synapse
  293. # then no modification to the list is required.
  294. #
  295. # If synapse is run behind a load balancer that handles the TLS then it
  296. # will be necessary to add the fingerprints of the certificates used by
  297. # the loadbalancers to this list if they are different to the one
  298. # synapse is using.
  299. #
  300. # Homeservers are permitted to cache the list of TLS fingerprints
  301. # returned in the key responses up to the "valid_until_ts" returned in
  302. # key. It may be necessary to publish the fingerprints of a new
  303. # certificate and wait until the "valid_until_ts" of the previous key
  304. # responses have passed before deploying it.
  305. #
  306. # You can calculate a fingerprint from a given TLS listener via:
  307. # openssl s_client -connect $host:$port < /dev/null 2> /dev/null |
  308. # openssl x509 -outform DER | openssl sha256 -binary | base64 | tr -d '='
  309. # or by checking matrix.org/federationtester/api/report?server_name=$host
  310. #
  311. #tls_fingerprints: [{"sha256": "<base64_encoded_sha256_fingerprint>"}]
  312. ## Database ##
  313. database:
  314. # The database engine name
  315. name: "sqlite3"
  316. # Arguments to pass to the engine
  317. args:
  318. # Path to the database
  319. database: "DATADIR/homeserver.db"
  320. # Number of events to cache in memory.
  321. #
  322. #event_cache_size: 10K
  323. ## Logging ##
  324. # A yaml python logging config file
  325. #
  326. log_config: "CONFDIR/SERVERNAME.log.config"
  327. ## Ratelimiting ##
  328. # Number of messages a client can send per second
  329. #
  330. #rc_messages_per_second: 0.2
  331. # Number of message a client can send before being throttled
  332. #
  333. #rc_message_burst_count: 10.0
  334. # Ratelimiting settings for registration and login.
  335. #
  336. # Each ratelimiting configuration is made of two parameters:
  337. # - per_second: number of requests a client can send per second.
  338. # - burst_count: number of requests a client can send before being throttled.
  339. #
  340. # Synapse currently uses the following configurations:
  341. # - one for registration that ratelimits registration requests based on the
  342. # client's IP address.
  343. # - one for login that ratelimits login requests based on the client's IP
  344. # address.
  345. # - one for login that ratelimits login requests based on the account the
  346. # client is attempting to log into.
  347. # - one for login that ratelimits login requests based on the account the
  348. # client is attempting to log into, based on the amount of failed login
  349. # attempts for this account.
  350. #
  351. # The defaults are as shown below.
  352. #
  353. #rc_registration:
  354. # per_second: 0.17
  355. # burst_count: 3
  356. #
  357. #rc_login:
  358. # address:
  359. # per_second: 0.17
  360. # burst_count: 3
  361. # account:
  362. # per_second: 0.17
  363. # burst_count: 3
  364. # failed_attempts:
  365. # per_second: 0.17
  366. # burst_count: 3
  367. # The federation window size in milliseconds
  368. #
  369. #federation_rc_window_size: 1000
  370. # The number of federation requests from a single server in a window
  371. # before the server will delay processing the request.
  372. #
  373. #federation_rc_sleep_limit: 10
  374. # The duration in milliseconds to delay processing events from
  375. # remote servers by if they go over the sleep limit.
  376. #
  377. #federation_rc_sleep_delay: 500
  378. # The maximum number of concurrent federation requests allowed
  379. # from a single server
  380. #
  381. #federation_rc_reject_limit: 50
  382. # The number of federation requests to concurrently process from a
  383. # single server
  384. #
  385. #federation_rc_concurrent: 3
  386. # Target outgoing federation transaction frequency for sending read-receipts,
  387. # per-room.
  388. #
  389. # If we end up trying to send out more read-receipts, they will get buffered up
  390. # into fewer transactions.
  391. #
  392. #federation_rr_transactions_per_room_per_second: 50
  393. # Directory where uploaded images and attachments are stored.
  394. #
  395. media_store_path: "DATADIR/media_store"
  396. # Media storage providers allow media to be stored in different
  397. # locations.
  398. #
  399. #media_storage_providers:
  400. # - module: file_system
  401. # # Whether to write new local files.
  402. # store_local: false
  403. # # Whether to write new remote media
  404. # store_remote: false
  405. # # Whether to block upload requests waiting for write to this
  406. # # provider to complete
  407. # store_synchronous: false
  408. # config:
  409. # directory: /mnt/some/other/directory
  410. # Directory where in-progress uploads are stored.
  411. #
  412. uploads_path: "DATADIR/uploads"
  413. # The largest allowed upload size in bytes
  414. #
  415. #max_upload_size: 10M
  416. # Maximum number of pixels that will be thumbnailed
  417. #
  418. #max_image_pixels: 32M
  419. # Whether to generate new thumbnails on the fly to precisely match
  420. # the resolution requested by the client. If true then whenever
  421. # a new resolution is requested by the client the server will
  422. # generate a new thumbnail. If false the server will pick a thumbnail
  423. # from a precalculated list.
  424. #
  425. #dynamic_thumbnails: false
  426. # List of thumbnails to precalculate when an image is uploaded.
  427. #
  428. #thumbnail_sizes:
  429. # - width: 32
  430. # height: 32
  431. # method: crop
  432. # - width: 96
  433. # height: 96
  434. # method: crop
  435. # - width: 320
  436. # height: 240
  437. # method: scale
  438. # - width: 640
  439. # height: 480
  440. # method: scale
  441. # - width: 800
  442. # height: 600
  443. # method: scale
  444. # Is the preview URL API enabled? If enabled, you *must* specify
  445. # an explicit url_preview_ip_range_blacklist of IPs that the spider is
  446. # denied from accessing.
  447. #
  448. #url_preview_enabled: false
  449. # List of IP address CIDR ranges that the URL preview spider is denied
  450. # from accessing. There are no defaults: you must explicitly
  451. # specify a list for URL previewing to work. You should specify any
  452. # internal services in your network that you do not want synapse to try
  453. # to connect to, otherwise anyone in any Matrix room could cause your
  454. # synapse to issue arbitrary GET requests to your internal services,
  455. # causing serious security issues.
  456. #
  457. #url_preview_ip_range_blacklist:
  458. # - '127.0.0.0/8'
  459. # - '10.0.0.0/8'
  460. # - '172.16.0.0/12'
  461. # - '192.168.0.0/16'
  462. # - '100.64.0.0/10'
  463. # - '169.254.0.0/16'
  464. # - '::1/128'
  465. # - 'fe80::/64'
  466. # - 'fc00::/7'
  467. #
  468. # List of IP address CIDR ranges that the URL preview spider is allowed
  469. # to access even if they are specified in url_preview_ip_range_blacklist.
  470. # This is useful for specifying exceptions to wide-ranging blacklisted
  471. # target IP ranges - e.g. for enabling URL previews for a specific private
  472. # website only visible in your network.
  473. #
  474. #url_preview_ip_range_whitelist:
  475. # - '192.168.1.1'
  476. # Optional list of URL matches that the URL preview spider is
  477. # denied from accessing. You should use url_preview_ip_range_blacklist
  478. # in preference to this, otherwise someone could define a public DNS
  479. # entry that points to a private IP address and circumvent the blacklist.
  480. # This is more useful if you know there is an entire shape of URL that
  481. # you know that will never want synapse to try to spider.
  482. #
  483. # Each list entry is a dictionary of url component attributes as returned
  484. # by urlparse.urlsplit as applied to the absolute form of the URL. See
  485. # https://docs.python.org/2/library/urlparse.html#urlparse.urlsplit
  486. # The values of the dictionary are treated as an filename match pattern
  487. # applied to that component of URLs, unless they start with a ^ in which
  488. # case they are treated as a regular expression match. If all the
  489. # specified component matches for a given list item succeed, the URL is
  490. # blacklisted.
  491. #
  492. #url_preview_url_blacklist:
  493. # # blacklist any URL with a username in its URI
  494. # - username: '*'
  495. #
  496. # # blacklist all *.google.com URLs
  497. # - netloc: 'google.com'
  498. # - netloc: '*.google.com'
  499. #
  500. # # blacklist all plain HTTP URLs
  501. # - scheme: 'http'
  502. #
  503. # # blacklist http(s)://www.acme.com/foo
  504. # - netloc: 'www.acme.com'
  505. # path: '/foo'
  506. #
  507. # # blacklist any URL with a literal IPv4 address
  508. # - netloc: '^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$'
  509. # The largest allowed URL preview spidering size in bytes
  510. #
  511. #max_spider_size: 10M
  512. ## Captcha ##
  513. # See docs/CAPTCHA_SETUP for full details of configuring this.
  514. # This Home Server's ReCAPTCHA public key.
  515. #
  516. #recaptcha_public_key: "YOUR_PUBLIC_KEY"
  517. # This Home Server's ReCAPTCHA private key.
  518. #
  519. #recaptcha_private_key: "YOUR_PRIVATE_KEY"
  520. # Enables ReCaptcha checks when registering, preventing signup
  521. # unless a captcha is answered. Requires a valid ReCaptcha
  522. # public/private key.
  523. #
  524. #enable_registration_captcha: false
  525. # A secret key used to bypass the captcha test entirely.
  526. #
  527. #captcha_bypass_secret: "YOUR_SECRET_HERE"
  528. # The API endpoint to use for verifying m.login.recaptcha responses.
  529. #
  530. #recaptcha_siteverify_api: "https://www.recaptcha.net/recaptcha/api/siteverify"
  531. ## TURN ##
  532. # The public URIs of the TURN server to give to clients
  533. #
  534. #turn_uris: []
  535. # The shared secret used to compute passwords for the TURN server
  536. #
  537. #turn_shared_secret: "YOUR_SHARED_SECRET"
  538. # The Username and password if the TURN server needs them and
  539. # does not use a token
  540. #
  541. #turn_username: "TURNSERVER_USERNAME"
  542. #turn_password: "TURNSERVER_PASSWORD"
  543. # How long generated TURN credentials last
  544. #
  545. #turn_user_lifetime: 1h
  546. # Whether guests should be allowed to use the TURN server.
  547. # This defaults to True, otherwise VoIP will be unreliable for guests.
  548. # However, it does introduce a slight security risk as it allows users to
  549. # connect to arbitrary endpoints without having first signed up for a
  550. # valid account (e.g. by passing a CAPTCHA).
  551. #
  552. #turn_allow_guests: True
  553. ## Registration ##
  554. #
  555. # Registration can be rate-limited using the parameters in the "Ratelimiting"
  556. # section of this file.
  557. # Enable registration for new users.
  558. #
  559. #enable_registration: false
  560. # The user must provide all of the below types of 3PID when registering.
  561. #
  562. #registrations_require_3pid:
  563. # - email
  564. # - msisdn
  565. # Explicitly disable asking for MSISDNs from the registration
  566. # flow (overrides registrations_require_3pid if MSISDNs are set as required)
  567. #
  568. #disable_msisdn_registration: true
  569. # Mandate that users are only allowed to associate certain formats of
  570. # 3PIDs with accounts on this server.
  571. #
  572. #allowed_local_3pids:
  573. # - medium: email
  574. # pattern: '.*@matrix\.org'
  575. # - medium: email
  576. # pattern: '.*@vector\.im'
  577. # - medium: msisdn
  578. # pattern: '\+44'
  579. # If set, allows registration of standard or admin accounts by anyone who
  580. # has the shared secret, even if registration is otherwise disabled.
  581. #
  582. # registration_shared_secret: <PRIVATE STRING>
  583. # Set the number of bcrypt rounds used to generate password hash.
  584. # Larger numbers increase the work factor needed to generate the hash.
  585. # The default number is 12 (which equates to 2^12 rounds).
  586. # N.B. that increasing this will exponentially increase the time required
  587. # to register or login - e.g. 24 => 2^24 rounds which will take >20 mins.
  588. #
  589. #bcrypt_rounds: 12
  590. # Allows users to register as guests without a password/email/etc, and
  591. # participate in rooms hosted on this server which have been made
  592. # accessible to anonymous users.
  593. #
  594. #allow_guest_access: false
  595. # The identity server which we suggest that clients should use when users log
  596. # in on this server.
  597. #
  598. # (By default, no suggestion is made, so it is left up to the client.
  599. # This setting is ignored unless public_baseurl is also set.)
  600. #
  601. #default_identity_server: https://matrix.org
  602. # The list of identity servers trusted to verify third party
  603. # identifiers by this server.
  604. #
  605. # Also defines the ID server which will be called when an account is
  606. # deactivated (one will be picked arbitrarily).
  607. #
  608. #trusted_third_party_id_servers:
  609. # - matrix.org
  610. # - vector.im
  611. # Users who register on this homeserver will automatically be joined
  612. # to these rooms
  613. #
  614. #auto_join_rooms:
  615. # - "#example:example.com"
  616. # Where auto_join_rooms are specified, setting this flag ensures that the
  617. # the rooms exist by creating them when the first user on the
  618. # homeserver registers.
  619. # Setting to false means that if the rooms are not manually created,
  620. # users cannot be auto-joined since they do not exist.
  621. #
  622. #autocreate_auto_join_rooms: true
  623. ## Metrics ###
  624. # Enable collection and rendering of performance metrics
  625. #
  626. #enable_metrics: False
  627. # Enable sentry integration
  628. # NOTE: While attempts are made to ensure that the logs don't contain
  629. # any sensitive information, this cannot be guaranteed. By enabling
  630. # this option the sentry server may therefore receive sensitive
  631. # information, and it in turn may then diseminate sensitive information
  632. # through insecure notification channels if so configured.
  633. #
  634. #sentry:
  635. # dsn: "..."
  636. # Whether or not to report anonymized homeserver usage statistics.
  637. # report_stats: true|false
  638. ## API Configuration ##
  639. # A list of event types that will be included in the room_invite_state
  640. #
  641. #room_invite_state_types:
  642. # - "m.room.join_rules"
  643. # - "m.room.canonical_alias"
  644. # - "m.room.avatar"
  645. # - "m.room.encryption"
  646. # - "m.room.name"
  647. # A list of application service config files to use
  648. #
  649. #app_service_config_files:
  650. # - app_service_1.yaml
  651. # - app_service_2.yaml
  652. # Uncomment to enable tracking of application service IP addresses. Implicitly
  653. # enables MAU tracking for application service users.
  654. #
  655. #track_appservice_user_ips: True
  656. # a secret which is used to sign access tokens. If none is specified,
  657. # the registration_shared_secret is used, if one is given; otherwise,
  658. # a secret key is derived from the signing key.
  659. #
  660. # macaroon_secret_key: <PRIVATE STRING>
  661. # Used to enable access token expiration.
  662. #
  663. #expire_access_token: False
  664. # a secret which is used to calculate HMACs for form values, to stop
  665. # falsification of values. Must be specified for the User Consent
  666. # forms to work.
  667. #
  668. # form_secret: <PRIVATE STRING>
  669. ## Signing Keys ##
  670. # Path to the signing key to sign messages with
  671. #
  672. signing_key_path: "CONFDIR/SERVERNAME.signing.key"
  673. # The keys that the server used to sign messages with but won't use
  674. # to sign new messages. E.g. it has lost its private key
  675. #
  676. #old_signing_keys:
  677. # "ed25519:auto":
  678. # # Base64 encoded public key
  679. # key: "The public part of your old signing key."
  680. # # Millisecond POSIX timestamp when the key expired.
  681. # expired_ts: 123456789123
  682. # How long key response published by this server is valid for.
  683. # Used to set the valid_until_ts in /key/v2 APIs.
  684. # Determines how quickly servers will query to check which keys
  685. # are still valid.
  686. #
  687. #key_refresh_interval: 1d
  688. # The trusted servers to download signing keys from.
  689. #
  690. #perspectives:
  691. # servers:
  692. # "matrix.org":
  693. # verify_keys:
  694. # "ed25519:auto":
  695. # key: "Noi6WqcDj0QmPxCNQqgezwTlBKrfqehY1u2FyWP9uYw"
  696. # Enable SAML2 for registration and login. Uses pysaml2.
  697. #
  698. # `sp_config` is the configuration for the pysaml2 Service Provider.
  699. # See pysaml2 docs for format of config.
  700. #
  701. # Default values will be used for the 'entityid' and 'service' settings,
  702. # so it is not normally necessary to specify them unless you need to
  703. # override them.
  704. #
  705. #saml2_config:
  706. # sp_config:
  707. # # point this to the IdP's metadata. You can use either a local file or
  708. # # (preferably) a URL.
  709. # metadata:
  710. # #local: ["saml2/idp.xml"]
  711. # remote:
  712. # - url: https://our_idp/metadata.xml
  713. #
  714. # # The rest of sp_config is just used to generate our metadata xml, and you
  715. # # may well not need it, depending on your setup. Alternatively you
  716. # # may need a whole lot more detail - see the pysaml2 docs!
  717. #
  718. # description: ["My awesome SP", "en"]
  719. # name: ["Test SP", "en"]
  720. #
  721. # organization:
  722. # name: Example com
  723. # display_name:
  724. # - ["Example co", "en"]
  725. # url: "http://example.com"
  726. #
  727. # contact_person:
  728. # - given_name: Bob
  729. # sur_name: "the Sysadmin"
  730. # email_address": ["admin@example.com"]
  731. # contact_type": technical
  732. #
  733. # # Instead of putting the config inline as above, you can specify a
  734. # # separate pysaml2 configuration file:
  735. # #
  736. # config_path: "CONFDIR/sp_conf.py"
  737. # Enable CAS for registration and login.
  738. #
  739. #cas_config:
  740. # enabled: true
  741. # server_url: "https://cas-server.com"
  742. # service_url: "https://homeserver.domain.com:8448"
  743. # #required_attributes:
  744. # # name: value
  745. # The JWT needs to contain a globally unique "sub" (subject) claim.
  746. #
  747. #jwt_config:
  748. # enabled: true
  749. # secret: "a secret"
  750. # algorithm: "HS256"
  751. password_config:
  752. # Uncomment to disable password login
  753. #
  754. #enabled: false
  755. # Uncomment and change to a secret random string for extra security.
  756. # DO NOT CHANGE THIS AFTER INITIAL SETUP!
  757. #
  758. #pepper: "EVEN_MORE_SECRET"
  759. # Enable sending emails for notification events
  760. # Defining a custom URL for Riot is only needed if email notifications
  761. # should contain links to a self-hosted installation of Riot; when set
  762. # the "app_name" setting is ignored.
  763. #
  764. # If your SMTP server requires authentication, the optional smtp_user &
  765. # smtp_pass variables should be used
  766. #
  767. #email:
  768. # enable_notifs: false
  769. # smtp_host: "localhost"
  770. # smtp_port: 25
  771. # smtp_user: "exampleusername"
  772. # smtp_pass: "examplepassword"
  773. # require_transport_security: False
  774. # notif_from: "Your Friendly %(app)s Home Server <noreply@example.com>"
  775. # app_name: Matrix
  776. # # if template_dir is unset, uses the example templates that are part of
  777. # # the Synapse distribution.
  778. # #template_dir: res/templates
  779. # notif_template_html: notif_mail.html
  780. # notif_template_text: notif_mail.txt
  781. # notif_for_new_users: True
  782. # riot_base_url: "http://localhost/riot"
  783. #password_providers:
  784. # - module: "ldap_auth_provider.LdapAuthProvider"
  785. # config:
  786. # enabled: true
  787. # uri: "ldap://ldap.example.com:389"
  788. # start_tls: true
  789. # base: "ou=users,dc=example,dc=com"
  790. # attributes:
  791. # uid: "cn"
  792. # mail: "email"
  793. # name: "givenName"
  794. # #bind_dn:
  795. # #bind_password:
  796. # #filter: "(objectClass=posixAccount)"
  797. # Clients requesting push notifications can either have the body of
  798. # the message sent in the notification poke along with other details
  799. # like the sender, or just the event ID and room ID (`event_id_only`).
  800. # If clients choose the former, this option controls whether the
  801. # notification request includes the content of the event (other details
  802. # like the sender are still included). For `event_id_only` push, it
  803. # has no effect.
  804. #
  805. # For modern android devices the notification content will still appear
  806. # because it is loaded by the app. iPhone, however will send a
  807. # notification saying only that a message arrived and who it came from.
  808. #
  809. #push:
  810. # include_content: true
  811. #spam_checker:
  812. # module: "my_custom_project.SuperSpamChecker"
  813. # config:
  814. # example_option: 'things'
  815. # Uncomment to allow non-server-admin users to create groups on this server
  816. #
  817. #enable_group_creation: true
  818. # If enabled, non server admins can only create groups with local parts
  819. # starting with this prefix
  820. #
  821. #group_creation_prefix: "unofficial/"
  822. # User Directory configuration
  823. #
  824. # 'enabled' defines whether users can search the user directory. If
  825. # false then empty responses are returned to all queries. Defaults to
  826. # true.
  827. #
  828. # 'search_all_users' defines whether to search all users visible to your HS
  829. # when searching the user directory, rather than limiting to users visible
  830. # in public rooms. Defaults to false. If you set it True, you'll have to run
  831. # UPDATE user_directory_stream_pos SET stream_id = NULL;
  832. # on your database to tell it to rebuild the user_directory search indexes.
  833. #
  834. #user_directory:
  835. # enabled: true
  836. # search_all_users: false
  837. # User Consent configuration
  838. #
  839. # for detailed instructions, see
  840. # https://github.com/matrix-org/synapse/blob/master/docs/consent_tracking.md
  841. #
  842. # Parts of this section are required if enabling the 'consent' resource under
  843. # 'listeners', in particular 'template_dir' and 'version'.
  844. #
  845. # 'template_dir' gives the location of the templates for the HTML forms.
  846. # This directory should contain one subdirectory per language (eg, 'en', 'fr'),
  847. # and each language directory should contain the policy document (named as
  848. # '<version>.html') and a success page (success.html).
  849. #
  850. # 'version' specifies the 'current' version of the policy document. It defines
  851. # the version to be served by the consent resource if there is no 'v'
  852. # parameter.
  853. #
  854. # 'server_notice_content', if enabled, will send a user a "Server Notice"
  855. # asking them to consent to the privacy policy. The 'server_notices' section
  856. # must also be configured for this to work. Notices will *not* be sent to
  857. # guest users unless 'send_server_notice_to_guests' is set to true.
  858. #
  859. # 'block_events_error', if set, will block any attempts to send events
  860. # until the user consents to the privacy policy. The value of the setting is
  861. # used as the text of the error.
  862. #
  863. # 'require_at_registration', if enabled, will add a step to the registration
  864. # process, similar to how captcha works. Users will be required to accept the
  865. # policy before their account is created.
  866. #
  867. # 'policy_name' is the display name of the policy users will see when registering
  868. # for an account. Has no effect unless `require_at_registration` is enabled.
  869. # Defaults to "Privacy Policy".
  870. #
  871. #user_consent:
  872. # template_dir: res/templates/privacy
  873. # version: 1.0
  874. # server_notice_content:
  875. # msgtype: m.text
  876. # body: >-
  877. # To continue using this homeserver you must review and agree to the
  878. # terms and conditions at %(consent_uri)s
  879. # send_server_notice_to_guests: True
  880. # block_events_error: >-
  881. # To continue using this homeserver you must review and agree to the
  882. # terms and conditions at %(consent_uri)s
  883. # require_at_registration: False
  884. # policy_name: Privacy Policy
  885. #
  886. # Server Notices room configuration
  887. #
  888. # Uncomment this section to enable a room which can be used to send notices
  889. # from the server to users. It is a special room which cannot be left; notices
  890. # come from a special "notices" user id.
  891. #
  892. # If you uncomment this section, you *must* define the system_mxid_localpart
  893. # setting, which defines the id of the user which will be used to send the
  894. # notices.
  895. #
  896. # It's also possible to override the room name, the display name of the
  897. # "notices" user, and the avatar for the user.
  898. #
  899. #server_notices:
  900. # system_mxid_localpart: notices
  901. # system_mxid_display_name: "Server Notices"
  902. # system_mxid_avatar_url: "mxc://server.com/oumMVlgDnLYFaPVkExemNVVZ"
  903. # room_name: "Server Notices"
  904. # Uncomment to disable searching the public room list. When disabled
  905. # blocks searching local and remote room lists for local and remote
  906. # users by always returning an empty list for all queries.
  907. #
  908. #enable_room_list_search: false
  909. # The `alias_creation` option controls who's allowed to create aliases
  910. # on this server.
  911. #
  912. # The format of this option is a list of rules that contain globs that
  913. # match against user_id, room_id and the new alias (fully qualified with
  914. # server name). The action in the first rule that matches is taken,
  915. # which can currently either be "allow" or "deny".
  916. #
  917. # Missing user_id/room_id/alias fields default to "*".
  918. #
  919. # If no rules match the request is denied. An empty list means no one
  920. # can create aliases.
  921. #
  922. # Options for the rules include:
  923. #
  924. # user_id: Matches against the creator of the alias
  925. # alias: Matches against the alias being created
  926. # room_id: Matches against the room ID the alias is being pointed at
  927. # action: Whether to "allow" or "deny" the request if the rule matches
  928. #
  929. # The default is:
  930. #
  931. #alias_creation_rules:
  932. # - user_id: "*"
  933. # alias: "*"
  934. # room_id: "*"
  935. # action: allow
  936. # The `room_list_publication_rules` option controls who can publish and
  937. # which rooms can be published in the public room list.
  938. #
  939. # The format of this option is the same as that for
  940. # `alias_creation_rules`.
  941. #
  942. # If the room has one or more aliases associated with it, only one of
  943. # the aliases needs to match the alias rule. If there are no aliases
  944. # then only rules with `alias: *` match.
  945. #
  946. # If no rules match the request is denied. An empty list means no one
  947. # can publish rooms.
  948. #
  949. # Options for the rules include:
  950. #
  951. # user_id: Matches agaisnt the creator of the alias
  952. # room_id: Matches against the room ID being published
  953. # alias: Matches against any current local or canonical aliases
  954. # associated with the room
  955. # action: Whether to "allow" or "deny" the request if the rule matches
  956. #
  957. # The default is:
  958. #
  959. #room_list_publication_rules:
  960. # - user_id: "*"
  961. # alias: "*"
  962. # room_id: "*"
  963. # action: allow