Software Stack
DepthAI

ON THIS PAGE

  • OAK Apps Overview
  • What are OAK Apps?
  • Creating Your OAK App
  • Deploying with oakctl
  • OS Compatibility Chart
  • Building and Running Apps
  • App Management
  • Device Management
  • The oakapp.toml Configuration

OAK Apps Overview

OAK Apps provide a streamlined way to develop, deploy, and manage computer vision applications across Luxonis OAK devices. Whether you're deploying to a single OAK device or managing a fleet of devices in the field, OAK Apps simplify the entire workflow from development to production.Note that OAK Apps run on top of the oak-agent service that is pre-installed on OAK4 devices (it's baked into the Luxonis OS), so you can start developing and deploying apps right away.

What are OAK Apps?

OAK Apps are containerized computer vision applications built on the DepthAI framework that run directly on OAK devices. They provide:
  • Consistent development environment - Build once, deploy anywhere
  • Simplified deployment - Package everything your app needs
  • Fleet management - Deploy to multiple devices simultaneously
  • Integration with Luxonis Hub - Monitor and manage devices remotely
It's important to mention that once the app is built (ie. .oakapp file is generated) you can move and install it to other devices as well without needing to rebuild or require an internet connection.

Creating Your OAK App

Project Structure
App Development

Project Structure

A basic OAK App project structure:
Text
1my-oak-app/
2├── main.py            # Your primary application code
3├── requirements.txt   # Python dependencies
4└── oakapp.toml        # App configuration
The oakapp.toml file is required and contains app metadata and build instructions.

Deploying with oakctl

oakctl is a command-line tool that allows you to interact with your OAK4 cameras. It can be used to create, deploy, and manage apps on devices that are running the oak-agent service.
Linux/MacOS
Windows

Linux/MacOS

On 64bit system, run:
Command Line
1bash -c "$(curl -fsSL https://oakctl-releases.luxonis.com/oakctl-installer.sh)"

OS Compatibility Chart

RVC4 OS version oakctl version Command
OS 1.14.10.11.0 oakctl self-update -v 0.11.0 (current stable)
OS 1.110.9.0 oakctl self-update -v 0.9.0
OS 1.80.4.2oakctl self-update -v 0.4.2
OS 1.60.2.11oakctl self-update -v 0.2.11

Building and Running Apps

Building and running OAK Apps is straightforward with oakctl:
Command Line
1# Run an app directly from source
2oakctl app run ./my-oak-app
3
4# Build the app into a distributable package
5oakctl app build ./my-oak-app
6
7# Install a built app
8oakctl app install my-oak-app.oakapp

App Management

You can manage apps with the following commands:
Command Line
1# List installed apps
2oakctl app list
3
4# Start an app
5oakctl app start <container-id>
6
7# View app logs
8oakctl app logs <container-id>
9
10# Stop an app
11oakctl app stop <container-id>
12
13# Enable auto-start
14oakctl app enable <container-id>

Device Management

Command Line
1# List connected devices
2oakctl list
3
4# Connect to a specific device
5oakctl connect <device-ip>

The oakapp.toml Configuration

The oakapp.toml file defines your app's build and runtime configuration:
Toml
1identifier = "com.luxonis.python_demo"
2entrypoint = ["bash", "-c", "python3 /app/main.py"]
3
4# (Required) Prepare container commands
5# Here is the place where you can install all the dependencies that are needed at run-time
6prepare_container = [
7    # You can use COPY command to copy files from the host to the container
8    # { type = "COPY", source = "requirements.txt", target = "requirements.txt" }
9    # { type = "RUN", command = "pip3 install -r /app/requirements.txt --break-system-packages" }
10    { type = "COPY", source = "requirements.txt", target = "requirements.txt" },
11    { type = "RUN", command = "apt-get update" },
12    { type = "RUN", command = "apt-get install -y python3-pip" },
13    { type = "RUN", command = "pip3 install -r /app/requirements.txt --break-system-packages" },
14]
15
16# (Required) Prepare build dependencies
17# Here is the place where you can install all the dependencies that are needed at build-time
18prepare_build_container = [
19    # Example: npm, gcc, ...
20]
21
22# (Required) Additional commands after all the app files are copied to the container
23build_steps = []