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

debug: fix short-form custom command name on --invoke isn't used #2026

Merged
merged 1 commit into from
Aug 30, 2023

Conversation

ktock
Copy link
Collaborator

@ktock ktock commented Aug 30, 2023

This fixes the bug that --invoke ignores command name specified as the short-form argument. Sorry, this seems introduced in #1970 that uses InvokeConfig.NoCmd in an incorrect way in the short-form flag 🙏 .

master branch:

Command name (ps) on the short-form flag is ignored.

$ BUILDX_EXPERIMENTAL=1 /tmp/out/buildx build --invoke ps /tmp/ctx3/
...
Launching interactive container. Press Ctrl-a-c to switch to monitor console
Interactive container was restarted with process "a41yfa5q4d20h1ezin01ndcun". Press Ctrl-a-c to switch to the new container
root@buildkitsandbox:/# 

This PR:

Command name (ps) is enabled.

$ BUILDX_EXPERIMENTAL=1 /tmp/out/buildx build --invoke ps /tmp/ctx3/
...
Launching interactive container. Press Ctrl-a-c to switch to monitor console
Interactive container was restarted with process "su15exc88brmlsj7ae7c77nzv". Press Ctrl-a-c to switch to the new container
    PID TTY          TIME CMD
      1 pts/0    00:00:00 ps

@tonistiigi tonistiigi merged commit 76119b0 into docker:master Aug 30, 2023
59 checks passed
@ktock ktock deleted the fix-invoke-flag branch August 31, 2023 07:36
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