Skip to content

Support for unprivileged docker daemon #104

Closed
@vorner

Description

@vorner

I have my dockerd configured to run under an unprivileged user. However, it seems this is not really supported by cross:

$ cross test --target armv7-unknown-linux-musleabihf
docker: Error response from daemon: Privileged mode is incompatible with user namespaces.
See 'docker run --help'.
error: `"docker" "run" "--privileged" "--rm" "-it" "ubuntu:16.04" "sh" "-c" "apt-get update && apt-get install --no-install-recommends -y binfmt-support qemu-user-static"` failed with exit code: Some(125)
note: run with `RUST_BACKTRACE=1` for a backtrace

It fails with a different error with build, which probably could be solved by granting some unreasonable permissive permissions to ~/.cargo:

docker: Error response from daemon: oci runtime error: container_linux.go:247: starting container process caused "process_linux.go:359: container init caused \"rootfs_linux.go:54: mounting \\\"/home/vorner/.cargo\\\" to rootfs \\\"/var/lib/docker/231072.231072/btrfs/subvolumes/9a8dd48eec320f381e259e8640fb3414aa0baa4874c540c1334396d7a739bffc\\\" at \\\"/cargo\\\" caused \\\"stat /home/vorner/.cargo: permission denied\\\"\"".

Would it be viable to support these more paranoid modes of operation, or at least document this is not supported and why?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions