matrix-synapse/matrix-synapse-1.4.1-paths.patch

62 lines
2.5 KiB
Diff
Raw Normal View History

Index: synapse/contrib/example_log_config.yaml
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
===================================================================
--- synapse.orig/contrib/example_log_config.yaml
+++ synapse/contrib/example_log_config.yaml
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
@@ -26,7 +26,7 @@ handlers:
file:
class: logging.handlers.RotatingFileHandler
formatter: fmt
- filename: /var/log/synapse/homeserver.log
+ filename: /var/log/matrix-synapse/homeserver.log
maxBytes: 100000000
backupCount: 3
filters: [context]
Index: synapse/synapse/config/key.py
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
===================================================================
--- synapse.orig/synapse/config/key.py
+++ synapse/synapse/config/key.py
@@ -110,7 +110,7 @@ class KeyConfig(Config):
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
signing_key_path = config.get("signing_key_path")
if signing_key_path is None:
signing_key_path = os.path.join(
- config_dir_path, config["server_name"] + ".signing.key"
+ '/etc/matrix-synapse/keys.d', config["server_name"] + ".signing.key"
)
self.signing_key = self.read_signing_keys(signing_key_path, "signing_key")
@@ -183,7 +183,7 @@ class KeyConfig(Config):
generate_secrets: bool = False,
**kwargs: Any,
) -> str:
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
- base_key_name = os.path.join(config_dir_path, server_name)
+ base_key_name = os.path.join('/etc/matrix-synapse/keys.d', server_name)
macaroon_secret_key = ""
form_secret = ""
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
Index: synapse/synapse/config/logger.py
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
===================================================================
--- synapse.orig/synapse/config/logger.py
+++ synapse/synapse/config/logger.py
@@ -150,7 +150,7 @@ class LoggingConfig(Config):
def generate_config_section(
self, config_dir_path: str, server_name: str, **kwargs: Any
) -> str:
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
- log_config = os.path.join(config_dir_path, server_name + ".log.config")
+ log_config = os.path.join('/etc/matrix-synapse/', server_name + ".log.config")
return (
"""\
log_config: "%(log_config)s"
Index: synapse/synapse/config/server.py
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
===================================================================
--- synapse.orig/synapse/config/server.py
+++ synapse/synapse/config/server.py
@@ -742,7 +742,7 @@ class ServerConfig(Config):
Accepting request 768057 from home:darix:apps - update to 1.9.1 Fix bug where setting mau_limit_reserved_threepids config would cause Synapse to refuse to start. (#6793) - package cleanup - make sure we have all libraries to actually install the package: - buildrequires all runtime requirements - (build)require python3-typing_extensions - having it use the python package name is not really useful here. - refreshed and renamed better-paths.patch to matrix-synapse-1.4.1-paths.patch - also fix existing synapse user - group to synapse instead of nogroup - home directory to /var/lib/matrix-synapse - shell to /bin/false (which actually exists) - improvements to the logging configuration: - install copy of the current /etc/matrix-synapse/log.yaml as /etc/matrix-synapse/log.systemd.yaml - install /etc/matrix-synapse/log.file.yaml which logs to /var/log/matrix-synapse/homeserver.log - add the log directory /var/log/matrix-synapse/ - added README.SUSE - better way to bootstrap a new config: 1. ExecStartPre would have never worked anyway 2. added %{_sbindir}/matrix-synapse-generate-config Usage: %{_sbindir}/matrix-synapse-generate-config servername - fix group and shell for the synapse user - added better-paths.patch - put the pid file into /run/matrix-synapse/ - use a default logging config in /etc/matrix-synapse/log.yaml to have systemd logging by default - use full path in the service file - actually use source 50 instead of the service file in the tarball - make permissions tighter on the config files as it contains passwords and other secrets: root:synapse u=rwX,g=rX,o= OBS-URL: https://build.opensuse.org/request/show/768057 OBS-URL: https://build.opensuse.org/package/show/network:messaging:matrix/matrix-synapse?expand=0&rev=111
2020-02-03 11:56:06 +01:00
bind_port = 8448
unsecure_port = 8008
- pid_file = os.path.join(data_dir_path, "homeserver.pid")
+ pid_file = os.path.join("/run/matrix-synapse", "homeserver.pid")
secure_listeners = []
unsecure_listeners = []