Skip to content
This repository was archived by the owner on Feb 3, 2019. It is now read-only.
This repository was archived by the owner on Feb 3, 2019. It is now read-only.

Docker image: problems with permissions on OS X #10

@ravicious

Description

@ravicious

First I want to say that I tried many different ways to cross-compile Rust code to RasPi 3B and this one seems to be the most promising so far.

I'm on OS X 10.11.3, Docker 1.10.2, Rust 1.7.0. I have successfully built the Docker image, but I ran into some permission problems as I tried to cross-compile my project.

If I run cargo build on host environment and then try to run the image, I get the following error:

$ docker run -v /Users/rav/Projects/rust/guessing_game:/home/cross/project rust-17-pi-cross build 
*** Extracting target dependencies ***

*** Cross compiling project ***
could not remove build directory

To learn more, run the command again with --verbose.

If I run cargo clean first, then I get this error:

$ docker run -v /Users/rav/Projects/rust/guessing_game:/home/cross/project rust-17-pi-cross build --verbose
*** Extracting target dependencies ***

*** Cross compiling project ***
    Updating registry `https://github.com/rust-lang/crates.io-index`
couldn't prepare build directories

Caused by:
  Permission denied (os error 13)

I looked for ways to solve it on Docker level, but none of them helped (like adding :z to the end of the volume path). Also, I believe most of them assume the image is running SELinux, while this Dockerfile uses Debian.

Pinging @schnupperboy, as from the issue tracker I see he's the one who added Docker support, so maybe he knows something that I don't. 😉

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions