Skip to content
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

ENTRYPOINT was Replaced with CMD in mesos-slave Dockerfile #84

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ser94mor
Copy link

@ser94mor ser94mor commented Feb 27, 2017

Issue #80.
Why ENTRYPOINT was replaced with CMD?
In large clusters, many nodes will only have mesos-slave docker image on hosts. When docker containerizer is used, mesos-slave will start mesos-execute in a separate container and it will start your task in another container accordingly. Docker image for mesos-execute should be specified with --docker_mesos_image flag or MESOS_DOCKER_MESOS_IMAGE environment variable for mesos-slave. It is reasonable to set this flag/env. variable to mesos-slave docker image because you most probably want to pull lesser docker images for each host while setting up a dockerized Mesos cluster.

So, when mesos-slave container is started with --docker_mesos_image pointing to mesosphere/mesos-slave:<tag> image, it tries to start mesos-execute, specifying it as a command to docker container. But, since mesos-slave Dockerfile uses ENTRYPOINT command instead of CMD, mesos-execute container's start will fail (mesos-execute container will have the following command in this case: mesos-slave mesos-execute ...flags...). The use of CMD instead of ENTRYPOINT will fix the situation and entry command to mesos-execute container will be mesos-execute ...flags....

There is a possible concern: if somebody relied on the ENTRYPOINT declaration for mesos-slave and included someting like docker run ... mesosphere/mesos-slave:<tag> ...flags_for_mesos_slave... in his scripts, then he should update these scripts with docker run ... mesosphere/mesos-slave:<tag> mesos-slave ...flags_for_mesos_slave... (mesos-slave added immediately after image name).

I would prefer to have a CMD command to be able to reuse mesosphere/mesos-slave:<tag> for mesos-execute. What do you think?

@lhoss
Copy link

lhoss commented Oct 13, 2017

where's the mesosphere maintainers ?!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants