Docker image suitable for development, similar to what we have in CI
Branch: master
Clone or download
nashif python: set locale before python module install
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Latest commit c795210 Jan 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.shippable.yml ci: build docker image in CI Nov 13, 2018
Dockerfile python: set locale before python module install Jan 13, 2019
LICENSE Initial commit Nov 10, 2018
README.md doc: Updated documentation on display use Jan 7, 2019
entrypoint.sh Added 32-bit SDL2 library Dec 28, 2018

README.md

docker-image

Docker image suitable for development, similar to what we have in CI.

This docker image can be built with

docker build -t zephyr_doc:v<tag> .

and can be used for development and building zephyr samples and tests, for example:

docker run -ti -v <path to zephyr tree>:/workdir zephyr_doc:v<tag>

Then, follow the steps below to build a sample application:

cd samples/hello_world
mkdir build
cd build
cmake -DBOARD=qemu_x86 ..
make run

The image is also available on docker.io, so you can skip the build step and directly pull from docker.io and build:

docker run -ti -v $HOME/Work/github/zephyr:/workdir \
docker.io/zephyrprojectrtos/zephyr-build:latest

The environment is set and ready to go, no need to source zephyr-env.sh.

We have two toolchains installed:

  • Zephyr SDK
  • GNU Arm Embedded Toolchain

To switch, set ZEPHYR_TOOLCHAIN_VARIANT.

Further it is possible to run native POSIX samples that require a display and check the display output via a VNC client. To allow the VNC client to connect to the docker instance port 5900 needs to be forwarded to the host, for example:

docker run -ti -p 5900:5900 -v <path to zephyr tree>:/workdir zephyr_doc:v<tag>

Then, follow the steps below to build a display sample application for the native POSIX board:

cd samples/display/cfb
mkdir build
cd build
cmake -DBOARD=native_posix -GNinja ..
ninja run

The result can be observed by connecting a VNC client to localhost at port 5900, the default VNC password is zephyr.

For example on a Ubuntu host system:

vncviewer localhost:5900