Ocre is a container runtime for constrained devices. It leverages WebAssembly and Zephyr to support OCI-type application containers in a footprint up to 2,000 times smaller than traditional Linux-based container runtimes. Our mission is to modernize the embedded applications by making it as easy to develop and securely deploy apps on constrained edge devices as it is in the cloud.
This guide walks you through building and running Ocre on a simulated device using Zephyr's native_sim
target. For instructions on building and flashing Ocre to physical hardware, please refer to our documentation.
The application in ./src/main.c
demonstrates basic Ocre runtime usage by writing a hello world application to flash and executing it.
- Install Dependencies and Zephyr SDK
Complete the Install dependencies and the Install the Zephyr SDK sections for your host operating system from the Zephyr (v3.7.0) Getting Started Guide.
- Install WEST
Install the west CLI tool, which is needed to build, run and manage Zephyr applications.
$ pip install west
- Initialize the workspace
This will checkout the project code and configure the Zephyr workspace.
$ mkdir runtime
$ cd runtime
$ west init -m [email protected]:project-ocre/ocre-runtime.git
$ west update
- Install Additional Zephyr (pip) requirements
In order to build the Ocre runtime properly, you'll need to install a few remaining requirements for Zephyr.
pip install -r zephyr/scripts/requirements.txt
- Build the application
The following will build the firmware for the virtual, native_sim
target which will allow you to run the Ocre runtime on a simulated device, rather than a physical board.
$ west build -b native_sim ./application -d build -- -DMODULE_EXT_ROOT=`pwd`/application
- Run the application
Run the following command:
$ ./build/zephyr/zephyr.exe
Distributed under the Apache License 2.0. See LICENSE for more information.
- Website: For a high-level overview of the Ocre project, and its goals visit our website.
- Docs: For more detailed information about the Ocre runtime, visit Ocre docs.
- Wiki: For a full project overview, FAQs, project roadmap, and governance information, visit the Ocre Wiki.
- Slack: If you need support, or simply want to discuss all things Ocre head on over to our Slack channel (
#ocre
) on LFEdge's Slack org.