-
Notifications
You must be signed in to change notification settings - Fork 84
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
krun can't pass --
correctly
#273
Comments
Just a guess without checking it: Could it be related to this issue? |
@slp the Should be reassigned to libkrun? |
https://github.com/containers/libkrun/blob/main/src/libkrun/src/lib.rs#L1166 seems to get confused with another Reassigning EDIT: the issue seems to be in the cmdline handling, these arguments seem to get lost once in the kernel. @slp is there any reason to not always use the config.json file when it is available? |
No, in fact we intend to deprecate |
thanks for confirming it. Opened a PR: containers/crun#1689 |
returning to the original issue, the kernel seems to call twice
A quick hack like the following patch seems to fix it, but I've not tested it carefully: ➜ diff -Naur linux-6.12.12/kernel/params.c.old linux-6.12.12/kernel/params.c
--- linux-6.12.12/kernel/params.c.old 2025-03-07 11:24:19.438764863 +0100
+++ linux-6.12.12/kernel/params.c 2025-03-07 11:23:52.109603366 +0100
@@ -180,7 +180,7 @@
args = next_arg(args, ¶m, &val);
/* Stop at -- */
- if (!val && strcmp(param, "--") == 0) {
+ if (!val && min_level >= 0 && strcmp(param, "--") == 0) {
return err ?: args;
}
irq_was_disabled = irqs_disabled(); For crun, I think just avoiding |
Regarding fixing In it's current state, you probably shouldn't use |
Issue Description
podman run --runtime=krun --entrypoint echo -it --rm fedora:41 -- test
don't display everything while it should give-- test
Steps to reproduce the issue
Steps to reproduce the issue
podman run --runtime=krun --entrypoint echo -it --rm fedora:41 -- test
podman run --runtime=crun --entrypoint echo -it --rm fedora:41 -- test
Describe the results you received
in step 1 no output is produced, but in step 2 I get
-- test
Describe the results you expected
The behavior should be consistent and the result should be equivlent to running
echo -- test
on the host.podman info output
Podman in a container
No
Privileged Or Rootless
Rootless
Upstream Latest Release
No
Additional environment details
Additional environment details
Additional information
I know
--
is very special in command line phrasing, maybe there is some program stopped phrasing incorrectly when seeing the--
in the chain of passing the full command?The text was updated successfully, but these errors were encountered: