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
/docker-entrypoint.sh": permission denied #7
Comments
Did you build this image yourself? If so, what umask were you using? Can you show the permissions of the files in your working dir? |
I am asking cause I had some issues myself when I was building the image locally, but that was because for some reason (I suspect umask cause I was messing around with that for another project) the permissions were only applied for the owner (none for group or 'other').
When building locally the above would yield me the following, which would not work:
|
Yes, I'm trying to build the image to learn how it works. But this time I'm trying with your image, because it is ready and testand, and after I will use it directly from dockerhub. The file status on host (including permission): The file status in the image (accesing with docker run): I run the chmod 777 command in the docker-entrypoint.sh file but the problem still persist. I will try with the image direct from dockerhub to verify that. |
Very peculiar. Can you include a log of your terminal showing the exact commands you ran and the exact error messages it produced? |
You should make your host's |
@herloct is correct. Permissions applied through the |
What is the rationale behind this? I can't control the file system on the machine where my docker image may be built. If I'm building an enterprise application, the machine building the image might be a build server VM. It seems kind of crazy to have to package a pre-build step to change permissions on the file before running docker build |
The rationale behind this, is that I did not invent Docker, and as such, I do not know the intricate inner workings of their tooling. You are looking in the wrong place for answers to your question. This repo is for the Composer image and related Dockerfile, not for questions about how or why certain things in Docker work the way they do. |
you may want to track/upvote moby/moby#34819 |
Try exposing volume with :z option in the end.
|
used |
After run |
The solution of @zoryamba works like a charm! 👍 |
You got to chmod the script to proper permission on the host, before you build the image. |
it work for me, thank you @zoryamba |
Avoiding permission errors with the entrypoint.sh Moreover, read this: composer/docker#7
You saved me a great deal. Thank you so much |
For me none of the solutions mentioned worked. Furthermore, I do not have in my host a |
I have the same situation as you @JoseFMP. what ever I tried it's showing UPDATE: I removed docker and docker-compose completely from project, and installed again, everything work fine! What caused my issue, I am not sure....so I don't have this issue any more. |
@JoseFMP @sajcics create new bug report, with all details from your system. how you obtained the image, did you built it, what was the build context, etc. dragging along old and closed issues does not help anyone. it's too confusing to any volunteer even to dig into the problem to explain what even your "me too" means. |
Thanks |
Complete reinstall of docker is the only thing that helped |
Previous tips didn't help me. Solving (Windows 11): |
Hi!
I'm trying to run a composer: 1.3.1 image in my host, but when I try to run the "composer" command the shell returns the message bellow:
Exec: "/docker-entrypoint.sh": permission denied
I just inserted the chmod + x /docker-entrypoint.sh command in my Dockerfile, but the problem continues.
I have inserted the composer entry function in my ~ / .bashrc to load the composer installation of the image.
I'm using the docker-compose to clusterize my environment.
docker-compose.yml
Dockerfile
The text was updated successfully, but these errors were encountered: