Permission denied: '/home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der' #211

Closed
opened 2026-02-04 18:38:43 +03:00 by OVERLORD · 4 comments
Owner

Originally created by @LukasWerfel on GitHub (Jan 25, 2019).

All of the sudden bitwarden cannot be upped anymore.

[user]$ docker-compose up -d
Building standardnotes
Traceback (most recent call last):
  File "site-packages/docker/utils/build.py", line 96, in create_archive
PermissionError: [Errno 13] Permission denied: '/home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "bin/docker-compose", line 6, in <module>
  File "compose/cli/main.py", line 71, in main
  File "compose/cli/main.py", line 127, in perform_command
  File "compose/cli/main.py", line 1080, in up
  File "compose/cli/main.py", line 1076, in up
  File "compose/project.py", line 475, in up
  File "compose/service.py", line 358, in ensure_image_exists
  File "compose/service.py", line 1082, in build
  File "site-packages/docker/api/build.py", line 154, in build
  File "site-packages/docker/utils/build.py", line 31, in tar
  File "site-packages/docker/utils/build.py", line 100, in create_archive
OSError: Can not read file in context: /home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der
[23602] Failed to execute script docker-compose
[user@localhost server]$ SUDO ^C
[user@localhost server]$ sudo systemctl restart docker
[user@localhost server]$ docker-compose up -d
Building standardnotes
Traceback (most recent call last):
  File "site-packages/docker/utils/build.py", line 96, in create_archive
PermissionError: [Errno 13] Permission denied: '/home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "bin/docker-compose", line 6, in <module>
  File "compose/cli/main.py", line 71, in main
  File "compose/cli/main.py", line 127, in perform_command
  File "compose/cli/main.py", line 1080, in up
  File "compose/cli/main.py", line 1076, in up
  File "compose/project.py", line 475, in up
  File "compose/service.py", line 358, in ensure_image_exists
  File "compose/service.py", line 1082, in build
  File "site-packages/docker/api/build.py", line 154, in build
  File "site-packages/docker/utils/build.py", line 31, in tar
  File "site-packages/docker/utils/build.py", line 100, in create_archive
OSError: Can not read file in context: /home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der
[23789] Failed to execute script docker-compose

My compose file

Problem remains after using a backuped volume that previously worked.

Originally created by @LukasWerfel on GitHub (Jan 25, 2019). All of the sudden bitwarden cannot be upped anymore. ``` [user]$ docker-compose up -d Building standardnotes Traceback (most recent call last): File "site-packages/docker/utils/build.py", line 96, in create_archive PermissionError: [Errno 13] Permission denied: '/home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "bin/docker-compose", line 6, in <module> File "compose/cli/main.py", line 71, in main File "compose/cli/main.py", line 127, in perform_command File "compose/cli/main.py", line 1080, in up File "compose/cli/main.py", line 1076, in up File "compose/project.py", line 475, in up File "compose/service.py", line 358, in ensure_image_exists File "compose/service.py", line 1082, in build File "site-packages/docker/api/build.py", line 154, in build File "site-packages/docker/utils/build.py", line 31, in tar File "site-packages/docker/utils/build.py", line 100, in create_archive OSError: Can not read file in context: /home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der [23602] Failed to execute script docker-compose [user@localhost server]$ SUDO ^C [user@localhost server]$ sudo systemctl restart docker [user@localhost server]$ docker-compose up -d Building standardnotes Traceback (most recent call last): File "site-packages/docker/utils/build.py", line 96, in create_archive PermissionError: [Errno 13] Permission denied: '/home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "bin/docker-compose", line 6, in <module> File "compose/cli/main.py", line 71, in main File "compose/cli/main.py", line 127, in perform_command File "compose/cli/main.py", line 1080, in up File "compose/cli/main.py", line 1076, in up File "compose/project.py", line 475, in up File "compose/service.py", line 358, in ensure_image_exists File "compose/service.py", line 1082, in build File "site-packages/docker/api/build.py", line 154, in build File "site-packages/docker/utils/build.py", line 31, in tar File "site-packages/docker/utils/build.py", line 100, in create_archive OSError: Can not read file in context: /home/user/server-setup/server/volumes/bitwarden/data/rsa_key.der [23789] Failed to execute script docker-compose ``` [My compose file](https://github.com/LukasWerfel/server-setup/blob/master/server/docker-compose.yml) Problem remains after using a backuped volume that previously worked.
Author
Owner

@dani-garcia commented on GitHub (Jan 26, 2019):

There hasn't been any change to that recently, so I'm not sure why it would break now.

Can you check the permission of that file, to see if you can access it correctly?

You could also try deleting all the rsa_key.* files, they'll be regenerated at next start, but you'll have to login again with all the clients.

@dani-garcia commented on GitHub (Jan 26, 2019): There hasn't been any change to that recently, so I'm not sure why it would break now. Can you check the permission of that file, to see if you can access it correctly? You could also try deleting all the rsa_key.* files, they'll be regenerated at next start, but you'll have to login again with all the clients.
Author
Owner

@LukasWerfel commented on GitHub (Jan 26, 2019):

Hi, turns out it was not a bitwarden specific issue, thanks for your help!

@LukasWerfel commented on GitHub (Jan 26, 2019): Hi, turns out it was not a bitwarden specific issue, thanks for your help!
Author
Owner

@jonahbron commented on GitHub (Oct 31, 2020):

@LukasWerfel What was the solution for you? I'm having this same error, but no matter how much I open up the permissions, I still get the error.

@jonahbron commented on GitHub (Oct 31, 2020): @LukasWerfel What was the solution for you? I'm having this same error, but no matter how much I open up the permissions, I still get the error.
Author
Owner

@jonahbron commented on GitHub (Oct 31, 2020):

Found the issue. I wasn't taking into account the ReadWritePaths set in my systemd service. Once I moved my data dir into that path it worked fine.

@jonahbron commented on GitHub (Oct 31, 2020): Found the issue. I wasn't taking into account the `ReadWritePaths` set in my systemd service. Once I moved my data dir into that path it worked fine.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#211