GithubHelp home page GithubHelp logo

PX4 Docker containers about px4-devguide HOT 11 OPEN

px4 avatar px4 commented on July 28, 2024
PX4 Docker containers

from px4-devguide.

Comments (11)

hamishwillee avatar hamishwillee commented on July 28, 2024

G'day, I just followed the instructions on this too (my they assume you know a lot about docker) - running inside a Ubuntu 16.04 VM on Windows.

When you say that the makefile directory was present - you mean that you can see it within docker?

I entered near-identical instructions - the main difference being use of sudo and also specified the source tree:

xhost +
sudo docker run -it --privileged \
-v ~/src/Firmware:/src/firmware/:rw \
-v /tmp/.X11-unix:/tmp/.X11-unix:ro \
-e DISPLAY=:0 \
-p 14556:14556/udp \
--name=px4_ros_sim px4io/px4-dev-ros:2017-05-31 bash

When I try build anything I don't get missing Makefile errors ...

make posix_sitl_default gazebo

Instead I get permission denied errors when make tries to create the build directories (followed by recipe fails). Any ideas on that?

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

PS Just some notes on docs for when/if I come to document this:

  1. "Pull one of the tagged images if you're after a container that just works" - how do I get a list of tagged images? Link to an example list
  2. The list of containers in our docs does not match github - ie hierarchy here
    • In particular, our docs refer to px4io/px4-dev , but heirarchy does not list this ... e.g. it has px4-dev-nuttx
  3. A real example using the normal ~/src/Firmware/ cloning/installation would not hurt. Even a bash script to do everything/set this up.
  4. For Linux the docker instructions say that you have to use sudo for all instructions from host. Need to make that clear.

from px4-devguide.

Stifael avatar Stifael commented on July 28, 2024

@hamishwillee

When you say that the makefile directory was present - you mean that you can see it within docker?

Yes. If I am within the docker container px4_ros_sim and go to the directory /src/firmware then I basically can see the normal px4 Firmware directory (including the Makefiel). But I cannot build anything...

Not sure why you get permission denied or even why you should be root.

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

Not sure why you get permission denied or even why you should be root.

From docker install guide: "You need to use sudo to run Docker commands. Continue to Linux postinstall to allow non-privileged users to run Docker commands and for other optional configuration steps."

Either way, clearly docs broken.

from px4-devguide.

Stifael avatar Stifael commented on July 28, 2024

but make is not a docker command

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

Sorry, I was unclear. I ran docker itself using sudo (i.e. sudo docker run -it ... - your example doesn't. I think may try to add a group as per docs and see if that changes effect of permissions

from px4-devguide.

Stifael avatar Stifael commented on July 28, 2024

true: this is needed
https://docs.docker.com/engine/installation/linux/linux-postinstall/

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

Actually it wasn't enough - I still got permission errors. I've just used chmod to give full access to my current user over the host folder (not clear why they didn't have it). Everything building now. Things would probably go smoother if I was better at linux.

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

Sorry, didn't mean to close! Also, I don't appear to have got closer to helping you.

from px4-devguide.

Stifael avatar Stifael commented on July 28, 2024

@hamishwillee
with sudo docker run ... I also get the permission denied error

from px4-devguide.

hamishwillee avatar hamishwillee commented on July 28, 2024

@Stifael Don't know if you saw, but Daniel's scripts for CI might be helpful: PX4/PX4-containers#65 (comment)

from px4-devguide.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.