opencontainers / opencontainers/runc

"root": { "readonly": true } not fully honoured

Open
#1,670 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
13.5k
Forks
2.3k
Avg merge
2d 8h
Merged PRs (30d)
30

Description

Running a rootless container and specifying a mounts section with a destination which does not yet exist in the rootfs, an mkdir of the missing bind mount point is performed.

Example for a read-only FS:

$ runc --root /tmp/runc run somefun
container_linux.go:262: starting container process caused "process_linux.go:339: container init caused \"rootfs_linux.go:57: mounting \\\"/var/tmp/olifre\\\" to rootfs \\\"/home/olifre/singularity/ubuntu_ro\\\" at \\\"/home/olifre/singularity/ubuntu_ro/beegfs\\\" caused \\\"mkdir /home/olifre/singularity/ubuntu_ro/beegfs: read-only file system\\\"\""

If the FS was not really read-only, a directory would be created (and never cleaned up).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Reproduce the issue with the provided runc command and a rootless container whose read-only rootfs lacks the mount destination; trace the mount setup path. Done means a read-only rootfs no longer attempts to create the missing bind-mount directory, while writable-rootfs behavior is covered and the relevant tests pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
infrastructure
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.