Skip to content

No touch /dev#8

Open
shankerwangmiao wants to merge 4 commits intoghedo:masterfrom
shankerwangmiao:no_touch_dev
Open

No touch /dev#8
shankerwangmiao wants to merge 4 commits intoghedo:masterfrom
shankerwangmiao:no_touch_dev

Conversation

@shankerwangmiao
Copy link

Sometimes we need to create some dev nodes in advance (for example, i want to use tun device inside the container), but we don't want the container with the capability to create any dev nodes. The --no-dev option is used to tell the pflask not to touch my /dev

Here is an example usage:

pflask \
    --chroot=/path/to/fakeRoot \
    --chdir=/ \
    --mount=bind-ro:/lib:/lib \
    --mount=bind-ro:/lib64:/lib64 \
    --mount=bind-ro:/usr/local/lib:/usr/local/lib  \
    --mount=bind-ro:/usr/lib:/usr/lib \
    --mount=tmp:/tmp \
    --mount=tmp:/var/run \
    --mount=tmp:/dev/shm \
    --user-map=0:2000:65536 \
    --no-dev \
    /sbin/init

And I can use mount -t devpts -o newinstance lxcpts /dev/pts to create /dev/pts manually

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.

1 participant

Comments