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

Docker Synapse image crash with saml2_config section #5467

Closed
kallama opened this issue Jun 15, 2019 · 1 comment
Closed

Docker Synapse image crash with saml2_config section #5467

kallama opened this issue Jun 15, 2019 · 1 comment
Labels
A-Docker Docker images, or making it easier to run Synapse in a container.

Comments

@kallama
Copy link

kallama commented Jun 15, 2019

This is in reference to the official matrix synapse docker image. Added the following to my homeserver.yaml file:

saml2_config:
  sp_config:
    metadata:
      remote:
        - url: https://myserver/metadata.xml

and generated the following errors when my synapse docker tries to start:

Jun 14 20:51:36 docker systemd[1]: Started Synapse server.
Jun 14 20:51:39 docker matrix-synapse[14453]: Traceback (most recent call last):
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/runpy.py", line 193, in _run_module_as_main
Jun 14 20:51:39 docker matrix-synapse[14453]:     "__main__", mod_spec)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/runpy.py", line 85, in _run_code
Jun 14 20:51:39 docker matrix-synapse[14453]:     exec(code, run_globals)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/app/homeserver.py", line 663, in <module>
Jun 14 20:51:39 docker matrix-synapse[14453]:     main()
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/app/homeserver.py", line 658, in main
Jun 14 20:51:39 docker matrix-synapse[14453]:     hs = setup(sys.argv[1:])
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/app/homeserver.py", line 331, in setup
Jun 14 20:51:39 docker matrix-synapse[14453]:     config_options,
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/config/_base.py", line 362, in load_or_generate_config
Jun 14 20:51:39 docker matrix-synapse[14453]:     generate_keys=generate_keys,
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/config/_base.py", line 408, in read_config_files
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.parse_config_dict(config)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/config/_base.py", line 411, in parse_config_dict
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.invoke_all("read_config", config_dict)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/config/_base.py", line 146, in invoke_all
Jun 14 20:51:39 docker matrix-synapse[14453]:     results.append(getattr(cls, name)(self, *args, **kargs))
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/synapse/config/saml2_config.py", line 33, in read_config
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.saml2_sp_config.load(saml2_config.get("sp_config", {}))
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/config.py", line 374, in load
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.load_complex(cnf, metadata_construction=metadata_construction)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/config.py", line 314, in load_complex
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.load_metadata(cnf["metadata"]))
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/config.py", line 415, in load_metadata
Jun 14 20:51:39 docker matrix-synapse[14453]:     disable_ssl_certificate_validation=disable_validation)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/mdstore.py", line 873, in __init__
Jun 14 20:51:39 docker matrix-synapse[14453]:     self.security = security_context(config)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/sigver.py", line 1019, in security_context
Jun 14 20:51:39 docker matrix-synapse[14453]:     xmlsec_binary = get_xmlsec_binary(_path)
Jun 14 20:51:39 docker matrix-synapse[14453]:   File "/usr/local/lib/python3.6/site-packages/saml2/sigver.py", line 195, in get_xmlsec_binary
Jun 14 20:51:39 docker matrix-synapse[14453]:     raise SigverError('Cannot find {binary}'.format(binary=bin_name))
Jun 14 20:51:39 docker matrix-synapse[14453]: saml2.sigver.SigverError: Cannot find ['xmlsec1']
Jun 14 20:51:39 docker systemd[1]: matrix-synapse.service: Main process exited, code=exited, status=1/FAILURE
Jun 14 20:51:39 docker systemd[1]: matrix-synapse.service: Failed with result 'exit-code'.

It looks like it's trying to call xmlsec1 but it doesn't exist in the docker image?

richvdh added a commit that referenced this issue Jun 18, 2019
@richvdh richvdh added the A-Docker Docker images, or making it easier to run Synapse in a container. label Jun 19, 2019
@richvdh
Copy link
Member

richvdh commented Jun 19, 2019

fixed by #5490 I hope

@richvdh richvdh closed this as completed Jun 19, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Docker Docker images, or making it easier to run Synapse in a container.
Projects
None yet
Development

No branches or pull requests

2 participants