[RFC] runc cli: --rootless flag idiosyncrasies
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
Research direction
Start by comparing the global runc help output with runc spec --help and trace how each --rootless flag is defined and applied to the affected commands. The work is done when maintainers agree on consistent flag semantics, deprecation warnings, and the eventual removal plan described in the proposal.
Written by the indexing model from the issue text.
Description
While looking into https://github.com/opencontainers/runc/issues/2639 I found out we have two --rootless flags with different meaning:
- Global flag, documented in
runc helpas
--rootless value ignore cgroup permission errors ('true', 'false', or 'auto') (default: "auto")
- A flag specific to
spec, documented inrunc spec --helpas
--rootless generate a configuration for a rootless container
The problem here is non-uniform syntax:
-
The first (global) option applies (I guess) to
create,run,execandupdate), the second applies tospec. -
The second option is true boolean, meaning that specifying
--rootlessis equivalent to--rootless=true. This is what I would expect. The first option is "bool-or-auto" meaning that specifying--rootlessis equivalent to no option, and to actually enable rootless mode one has to use--rootless=true.
Both items are confusing, second is more.
Proposal
I think we can do the following to rectify this:
-
Deprecate the local
--rootlessflag forrunc spec, adding a warning that the global one should be used. -
Make the global
--rootlessequivalent to--rootless=yes, and warn that using--rootless=autois deprecated (as it is "auto" without specifying any option). -
Eventually remove the local
--rootlessand the global--rootless=auto.
@AkihiroSuda @cyphar @mrunalp what do you think?
- Dominant language
- Go
- Stars
- 13.5k
- Forks
- 2.3k
- Avg merge
- 2d 8h
- Merged PRs (30d)
- 30
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from opencontainers/runc
-
`root.readonly` is silently ignored (rootfs left writable) when the container has no mount namespace Openllm-generated
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
opencontainers/runc#5371 ·
-
llm-generated
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
opencontainers/runc#5370 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
opencontainers/runc#2214 · 3 comments ·
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
opencontainers/runc#1679 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 68/100
opencontainers/runc#5474 ·
All issues in opencontainers/runc
Similar issues
-
optimization optimization:agents-md-curator
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
githubnext/gh-aw-cao#13143 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
blinklabs-io/bursa#904 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
yanet-platform/ipfw-go#129 ·
-
bug confmap/provider/googlesecretmanagerprovider needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
open-telemetry/opentelemetry-collector-contrib#51273 · 2 comments ·
-
bug: AI Gateway client filter lists "Unknown" twice when NULL and literal Unknown clients coexist Openbug
Difficulty 2/5 1-3 hours Newbie friendliness 90/100