mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 19:44:53 -04:00
Add health check endpoint (#8048)
This commit is contained in:
parent
4dd27e6d11
commit
7620912d84
7 changed files with 90 additions and 3 deletions
|
@ -68,6 +68,7 @@ from synapse.replication.http import REPLICATION_PREFIX, ReplicationRestResource
|
|||
from synapse.replication.tcp.resource import ReplicationStreamProtocolFactory
|
||||
from synapse.rest import ClientRestResource
|
||||
from synapse.rest.admin import AdminRestResource
|
||||
from synapse.rest.health import HealthResource
|
||||
from synapse.rest.key.v2 import KeyApiV2Resource
|
||||
from synapse.rest.well_known import WellKnownResource
|
||||
from synapse.server import HomeServer
|
||||
|
@ -98,7 +99,9 @@ class SynapseHomeServer(HomeServer):
|
|||
if site_tag is None:
|
||||
site_tag = port
|
||||
|
||||
resources = {}
|
||||
# We always include a health resource.
|
||||
resources = {"/health": HealthResource()}
|
||||
|
||||
for res in listener_config.http_options.resources:
|
||||
for name in res.names:
|
||||
if name == "openid" and "federation" in res.names:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue