Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] matrix container - default permissions issues #77

Closed
tylerstraub opened this issue Mar 15, 2023 · 3 comments
Closed

[BUG] matrix container - default permissions issues #77

tylerstraub opened this issue Mar 15, 2023 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@tylerstraub
Copy link

Greetings. I am going through the process of attempting a Matrix Synapse implementation using the A75G Docker package on the Unraid platform.

The first thing I have noticed is that there seems to be some sort of permissions issue happening out of box with the /data volume mapping.

I'm going through the process of troubleshooting it now myself and haven't solved it just yet. But I wanted to report what I'm seeing here in case the maintainer wants to try to adjust the package or add some additional setup instructions.

Thank you!

Traceback (most recent call last):
  File "/usr/lib/python3.11/logging/config.py", line 562, in configure
    handler = self.configure_handler(handlers[name])
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/logging/config.py", line 747, in configure_handler
    result = factory(**kwargs)
             ^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/logging/handlers.py", line 214, in __init__
    BaseRotatingHandler.__init__(self, filename, 'a', encoding=encoding,
  File "/usr/lib/python3.11/logging/handlers.py", line 58, in __init__
    logging.FileHandler.__init__(self, filename, mode=mode,
  File "/usr/lib/python3.11/logging/__init__.py", line 1181, in __init__
    StreamHandler.__init__(self, self._open())
                                 ^^^^^^^^^^^^
  File "/usr/lib/python3.11/logging/__init__.py", line 1213, in _open
    return open_func(self.baseFilename, self.mode,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
PermissionError: [Errno 13] Permission denied: '/homeserver.log'
@tylerstraub tylerstraub added the bug Something isn't working label Mar 15, 2023
@tylerstraub
Copy link
Author

Here was how I resolved the issue:

Made sure that the folder ownership was correct (I'm not sure if this step was necessary):
chown -R 991:991 /mnt/user/appdata/matrix

Edited my log.config file that matrix autogenerated in the /data volume and changed the path of the homeserver.log file to go inside of /data:

ex

        filename: /data/homeserver.log     

Restarted the Docker container, this resolved my issue. I think the following Github issue has some relevant data as to how this may have occurred: matrix-org/synapse#9970

Hope this helps!

@vaparetia
Copy link

chown -R 991:991 /mnt/user/appdata/matrix

This solved my issue as well. No files were being generated for me to edit until the permissions issue was resolved. Thanks for posting.

@A75G
Copy link
Owner

A75G commented Jan 23, 2024

added to template as requirement

@A75G A75G closed this as completed Jan 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants