-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
When populating CMD, do not include Entrypoint #3744
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mheon The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@nalind PTAL. I know you've done a lot of dancing with CMD and ENTRYPOINT. |
Previously, we use CreateConfig's Command to populate container Command (which is used as CMD for Inspect and Commit). Unfortunately, CreateConfig's Command is the container's full command, including a prepend of Entrypoint - so we duplicate Entrypoint for images that include it. Maintain a separate UserCommand in CreateConfig that does not include the entrypoint, and use that instead. Fixes containers#3708 Signed-off-by: Matthew Heon <matthew.heon@pm.me>
@mheon gofmt is not your friend here |
5ccc82f
to
b6f3cd9
Compare
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Tests are green. |
how dare you write a test for your code! LGTM |
/lgtm |
Previously, we use CreateConfig's Command to populate container Command (which is used as CMD for Inspect and Commit). Unfortunately, CreateConfig's Command is the container's full command, including a prepend of Entrypoint - so we duplicate Entrypoint for images that include it.
Maintain a separate UserCommand in CreateConfig that does not include the entrypoint, and use that instead.
Fixes #3708