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
Error when use docker cp. open : permission denied #564
Comments
same issue. anyone has any thoughts. Btw, it works when we do sudo docker cp x:y/z /root/ A workaround is to redirect stdout to a file on host filesystem: |
I also have the same problem when the user is not root and |
Same issue as @edward-agarwala and @mannharleen -> Temp. workaround for anyone stumbling upon this, is to copy the file to /tmp/ and move it from there. |
Seems like a straight forward problem with permissions. |
Hey @cpuguy83 I use copy in a dockerfile for the same folder and this works flawless. Nevertheless after executing the container and pulling the result with docker cp from bash, the error appears. Every command is done without root permissions. |
The issue is not the container but the location you are copying to on the client side. |
Closing since this doesn't really look like a docker issue. |
Use sudo, ex : sudo docker cp 0e543d3f05:/home/crossTest /home |
But using the 'sudo' is making the files to be with the owner as 'root', which is not good... |
I use sudo to execute this command and still get this error. |
Same here. Even using sudo does not slove the problem |
Same.
In that case, copy it to /tmp and you will find it in /tmp/snap.docker/tmp. |
this is NOT an issue of docker, this is an issue of snap. please report this problem to snap. @chopin2712 |
for me it ended up in |
I'm the same, brother. Have you solved it on your end. |
It seems to be an issue with snap. I added the current user to the docker group and restarted docker using snap (disable, then enable), and everything was fine. (Prior to this, I had been using sudo docker) Reference: snapcraft.io/docker sudo snap disable docker
sudo snap enable docker |
Dear developers
I recently installed a Mediawiki app with this command
sudo docker run -d -p 12345:80 --name andrewiki mediawiki
That works perfectly but I loose my
LocalSettings.php
file (nessessary to change basic variables)So I run this :
cd /home/gene/DBak/Andrew Bennett/
sudo docker cp andrewiki:/var/www/html/LocalSettings.php .
And there is the output :
open /home/gene/DBak/Andrew Bennett/LocalSettings.php: permission denied
I search elsewhere to find other issue like this one, but I didn't found anything pertinent. So I try :
sudo chown 777 daemon:daemon .
But nothing. The issue continue.
Please help me, if you find other way to have
LocalSettings.php
I will be very thanks.Thanks in advance.
SudoBash
The text was updated successfully, but these errors were encountered: