microsoft / vscode-docker

Docker Extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker
Other
1.18k stars 508 forks source link

remote ssh docker : error cannot statx #4302

Closed gxcuit closed 1 month ago

gxcuit commented 1 month ago

Hi, I'm using remote-ssh to connect the docker .

through the docker pannel, I cannot access the file in the container. However, attach vs code works fine. image

image

bwateratmsft commented 1 month ago

Can you post the full error message?

gxcuit commented 1 month ago

Can you post the full error message?

Hi, Is there any way that I can get the log?

Almost all of the files are not available. Files under a folder are not available,

bwateratmsft commented 1 month ago

Does anything show up under /etc or /var? The folders that are visible when you attach VSCode are very different from what is available when you use the file browser in the Docker container view.

gxcuit commented 1 month ago

Does anything show up under /etc or /var? The folders that are visible when you attach VSCode are very different from what is available when you use the file browser in the Docker container view.

When I attach vs code, everything works fine. However when I use file browser, only file under the folder is available(i.e. I can access /etc/a.txt BUT CANNOT /etc/folder/*)

bwateratmsft commented 1 month ago

We use the stat command to list files and folders. It might be a permissions issue, i.e., the default Docker user in the container does not have permission to execute the stat command. Does this happen for all containers? e.g. can you run a generic alpine:latest container and see if it's happening in that container too?

gxcuit commented 1 month ago

We use the stat command to list files and folders. It might be a permissions issue, i.e., the default Docker user in the container does not have permission to execute the stat command. Does this happen for all containers? e.g. can you run a generic alpine:latest container and see if it's happening in that container too?

@bwateratmsft Hi, Thanks for your reply.

I use Ubuntu container, everything works fine. I guess it maybe a permission issue . image

bwateratmsft commented 1 month ago

Ok, I'll close this issue for now. Let me know if it starts happening on other containers. Thanks!