On debian bullseye I install matrix-synapse as usual:
sudo apt-get install python3-frozendict/bullseye-backports
sudo apt-get install matrix-synapse/bullseye-backports
and then trying to upgrade it from SQLite to postgresql as said here:
https://matrix-org.github.io/synapse/latest/postgres.html#porting-from-sqlite
But when I run
synapse_port_db --sqlite-database /var/lib/matrix-synapse/homeserver.db \
--postgres-config /etc/matrix-synapse/homeserver.yaml
I get error:
Traceback (most recent call last):
File "/usr/bin/synapse_port_db", line 1217, in <module>
config.parse_config_dict(hs_config, "", "")
File "/usr/lib/python3/dist-packages/synapse/config/_base.py", line 731, in parse_config_dict
self.invoke_all(
File "/usr/lib/python3/dist-packages/synapse/config/_base.py", line 357, in invoke_all
res[config_class.section] = getattr(config, func_name)(*args, **kwargs)
File "/usr/lib/python3/dist-packages/synapse/config/server.py", line 252, in read_config
self.server_name = config["server_name"]
KeyError: 'server_name'
But if I add "server_name" to the homeserver.yaml
cat /etc/matrix-synapse/conf.d/server_name.yaml >> \
/etc/matrix-synapse/homeserver.yaml
synapse_port_db starts working as it should.
My guess, synapse_port_db is not aware of /etc/matrix-synapse/conf.d/
confings, thus we are having problems