-
Notifications
You must be signed in to change notification settings - Fork 310
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
Remote - Containers: NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/workspace/index.js' #6984
Comments
One addition to this issue. When I run the devcontainer removing every reference to the devcontainer.json {
"name": "Test",
"dockerComposeFile": [
"docker-compose.yml"
],
"service": "app",
"workspaceFolder": "/workspace",
"forwardPorts": [8080],
// "remoteUser": "node",
"extensions": [
]
} Dockerfile FROM node:bullseye However. I want to run as the |
I just did some more testing. The configuration works flawlessly when I use docker engine. Perhaps the problem is related to docker-desktop being ran in user mode? |
I am running into the exact same issue. Have you figured out how to fix the issue using docker-desktop? The documentation says that "any mounted files/folders will have the exact same permissions as outside the container - including the owner user ID (UID) and group ID (GID)", but that doesn't seem to be the case as they are mounted as root. |
I haven't tried it anymore after switching to docker engine. |
yeah it's what i'm doing too, but it'd be great to be able to fix it nonetheless |
Tracking rootless support as #4646. Thanks. |
Hi,
I am running into the following error:
Unable to write file 'vscode-remote://dev-container+7b2...d7d/workspace/index.js' (NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/workspace/index.js')
The interesting thing is that I can edit and delete all the existing files. I just cannot create new ones.
I am using the official node docker image.
I am using the non-root user provided by the image.
I run docker-desktop as my unprivileged user account (
systemctl --user start docker-desktop.service
).The user
node
is available in the image.The UID and GID are synced correctly between my local user and the
node
user inside the container.I have tried all the solutions in the other issues that resemble my problem but none has worked. I have the same error on two different linux machines, specs below.
System 1.
System 2.
Remote-Containers is the only extension installed.
Reproducible steps (1... 2... 3...) that cause the issue
Rebuild and Reopen in Container
What you expected to see, versus what you actually saw
I would expect:
node@70562af9dd33:/workspace$ ls -la total 12 drwxr-xr-x 3 node node 4096 Jul 22 21:30 . drwxr-xr-x 1 root root 4096 Jul 22 21:28 .. drwxr-xr-x 2 node node 4096 Jul 22 19:54 .devcontainer
But saw this:
ls -la
output of my workspace when the container has started.node@70562af9dd33:/workspace$ ls -la total 12 drwxr-xr-x 3 root root 4096 Jul 22 21:30 . drwxr-xr-x 1 root root 4096 Jul 22 21:28 .. drwxr-xr-x 2 root root 4096 Jul 22 19:54 .devcontainer
Include your container configuration files if you are able to.
devcontainer.json
docker-compose.yml
Dockerfile
Hope anyone can help me. Let me know if you need more information.
The text was updated successfully, but these errors were encountered: