Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Allow sharded database in db migrate script
Browse files Browse the repository at this point in the history
Signed-off-by: Finn Herzfeld <[email protected]>
  • Loading branch information
finn committed Jul 29, 2022
1 parent d548d8f commit 0874fd4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions changelog.d/13422.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
let update_synapse_database run in configurations with multiple databases. Contributed by @thefinn93 @ Beeper.
4 changes: 2 additions & 2 deletions synapse/_scripts/update_synapse_database.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ def main() -> None:
# Load, process and sanity-check the config.
hs_config = yaml.safe_load(args.database_config)

if "database" not in hs_config:
sys.stderr.write("The configuration file must have a 'database' section.\n")
if "database" not in hs_config and "databases" not in hs_config:
sys.stderr.write("The configuration file must have a 'database' or 'databases' section.\n")
sys.exit(4)

config = HomeServerConfig()
Expand Down

0 comments on commit 0874fd4

Please sign in to comment.