31z4 / zookeeper-docker

Docker image packaging for Apache Zookeeper
MIT License
285 stars 243 forks source link

container start failed: /docker-entrypoint.sh: permission denied:unknown #133

Closed yuezhongtao closed 1 year ago

yuezhongtao commented 2 years ago

Before you file an issue here, please keep in mind that your issue may be not related to the image itself. Please make sure that it is, otherwise report the issue upstream.

Expected behavior

container start success. Tell us what should happen.

Actual behavior

Tell us what happens instead.

企业微信截图_02cf203c-87d9-400a-b214-331eee57d958

Steps to reproduce the behavior

Tell us how to reproduce the issue.

System configuration

Please include as much relevant information as possible.

yuezhongtao commented 2 years ago

I have figured out the cause of the problem, docker packaging will not change the permissions of the file. It is because my local newly created docker-entrypoint.sh does not have executable permission. i think dockerfile can be hardened.

31z4 commented 1 year ago

While it's possible to add RUN chmod +x /docker-entrypoint.sh into the Dockerfile I don't think it's worth an extra image layer. If you're building the image using a newly created docker-entrypoint.sh please make sure it's executable on the host.