-
Notifications
You must be signed in to change notification settings - Fork 96
Description
Describe the bug
Homarr fails to start. It returns 'Server 500' in the web browser and the logs get flooded with:
homarr | message: 'SECRET_ENCRYPTION_KEY must only contain hex characters, please generate a 64 character secret in hex format or use the following: "41966b49750ba284cbdaf003a3aa23b606db4c343c5ca6006b44a27d0dfa90d3"',
This is due to the automatic key generation in the Python script:
Line 218 in ffede4f
| key = os.urandom(124).hex() |
To Reproduce
Steps to reproduce the behavior:
- Use
python3 main.pyto setup - Answer
yesto configure Homarr - Start docker compose
- Watch the logs of the homarr container
- Try to open the web interface
Expected behavior
A clear and concise description of what you expected to happen.
System (please complete the following information):
- OS: Ubuntu 24.04
- Browser: Firefox
- Deployed both with Podman and Docker
Easy fix
Set key generation to 32*, instead of 128.
(*Because os.urandom(32) generates 32 random bytes, and .hex() converts each byte into two hexadecimal characters.)
