element-hq / element-hq/synapse

Docker Containers for Synapse Workers failed with 'signing_key' in config.yml file

Open
#18,688 2 comments 0 reactions 0 assignees View on GitHub
A-Docker A-Workers
Dominant language
Python
Stars
4.6k
Forks
600
Avg merge
5d 22h
Merged PRs (30d)
51

Description

### Description

Dear Synapse Team,

I would like to report the following issue.

I runs Synapse in a Docker Enviroment (latest) and would like to improve that with worker containers. I did RTFM :) but Containers didn´t comes up.

Source: https://hub.docker.com/r/matrixdotorg/synapse

I got:

```
File "/usr/local/lib/python3.12/site-packages/synapse/config/key.py", line 128, in read_config
self.signing_key = read_signing_keys([config["signing_key"]])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/signedjson/key.py", line 147, in read_signing_keys
algorithm, version, key_base64 = line.split()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 3, got 1)
```

I rendered the homserver.yml into the '/data/ mounted dir and the worker.yml configs into a sub dir called 'workers'. I added in the worker.yml the 'signing_key: /data/singing.key'. In the homeserver.yml I did not need to add that line. Homserver Container comes up. I did a lot of debugging. The path is correct, the permissions are correct and the worker container can read the signinf.key file. There is no hidden character or an empty line in the key file.

I tied to add the 'signing_key: /data/singing.key' line into the homeserver.yml and the homeserver did not come up with the same issue. I remove the 'signing_key: /data/singing.key' line from worker.yml and render it to the '/data' dir and they comes up.

I hope that information are enough to reproduce the issue.

kind redards

### Steps to reproduce

- list the steps
- that reproduce the bug
- using hyphens as bullet points

### Homeserver

anonther homeserver

### Synapse Version

1.133.0

### Installation Method

Docker (matrixdotorg/synapse)

### Database

PostgreSQL

### Workers

Multiple workers

### Platform

OS of homeserver is Debian 12 and an VPS cloud hosted. Docker is installed.

### Configuration

_No response_

### Relevant log output

```shell
File "/usr/local/lib/python3.12/site-packages/synapse/config/key.py", line 128, in read_config
self.signing_key = read_signing_keys([config["signing_key"]])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/signedjson/key.py", line 147, in read_signing_keys
algorithm, version, key_base64 = line.split()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 3, got 1)
```

### Anything else that would be useful to know?

No, may you need anything else.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.