Skip to main content
A Python agent is built from its folder into an image with the Python version you choose, your dependencies installed, and Onecortex’s shim beside your code. You do not write a Dockerfile.

What the build does

  1. Copies your dependency file, and installs from it. See Dependencies.
  2. Copies the whole agent folder into /app, which is the working directory when your agent runs.
  3. Compiles your code to bytecode, so it starts faster. A file that does not compile is left for the smoke test to report, with a real traceback.
  4. Runs your build.commands, if you have any.
Output is unbuffered, so print and logging lines reach your logs as they are written.

The architecture: 64 bit ARM Linux

Every agent runs on 64 bit ARM Linux (aarch64, also called arm64). Pure Python packages work as they are. A package with a native extension needs a wheel for manylinux aarch64, which most popular packages publish. A package that publishes none fails the build with:
followed by the installer’s own output. Upgrade to a release that ships an aarch64 wheel, or use an alternative. The build image has a C compiler, so a package that builds from source with no system libraries beyond the standard ones can still install.

System packages

Two system packages can be installed with systemPackages:
agent.yml
Anything else fails validation with `<package>` is not an available system package. To ask for another, email [email protected].

Build commands

build.commands runs shell commands after your code is copied in and your dependencies are installed, in the agent folder:
agent.yml
The commands run once, at build time, with no configuration or secrets available. A command that fails fails the build at Build image, with its output.
Last modified on September 28, 2026