Skip to content

fix: skip rootless reexec for help-only command paths#4994

Merged
AkihiroSuda merged 1 commit into
containerd:mainfrom
immanuwell:fix/rootless-help-paths
Jun 25, 2026
Merged

fix: skip rootless reexec for help-only command paths#4994
AkihiroSuda merged 1 commit into
containerd:mainfrom
immanuwell:fix/rootless-help-paths

Conversation

@immanuwell

Copy link
Copy Markdown
Contributor

rootless help paths can die early right now.

nerdctl and parent commands like nerdctl system try to reexec into RootlessKit before showing help. if rootless containerd is not running, users get rootless containerd not running? instead of usage.

This skips that reexec when the command only needs to show subcommands. real runtime commands still keep the old path, so no funny business.

How to repro

  1. On Linux as a non root user, make sure rootless containerd is not running.
  2. Run go build -o /tmp/nerdctl ./cmd/nerdctl
  3. Run /tmp/nerdctl
  4. Run /tmp/nerdctl system

Before, both commands fail with rootless containerd not running?.
After, both print help. system info still follows the old path.

Kinda adjacent to #3185.

Signed-off-by: immanuwell <pchpr.00@list.ru>
@AkihiroSuda AkihiroSuda added this to the v2.3.4 milestone Jun 24, 2026
@AkihiroSuda AkihiroSuda added the area/rootless Rootless mode label Jun 24, 2026

@AkihiroSuda AkihiroSuda left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@AkihiroSuda AkihiroSuda merged commit 9350c77 into containerd:main Jun 25, 2026
146 of 167 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/rootless Rootless mode

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants