> For the complete documentation index, see [llms.txt](https://docs.eyepop.ai/developer-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.eyepop.ai/developer-documentation/deployment/eyepop-on-premise-ai-runtime/nvidia-jetson-orin-nx.md).

# NVIDIA Jetson Orin NX

## Jetson Orin Runtime

Run the EyePop runtime on an NVIDIA Jetson Orin with Docker.

### Requirements

* NVIDIA Jetson Orin with JetPack installed
* Docker
* NVIDIA container runtime
* EyePop dashboard access
* [Python3.12 installed on Jetson Orin NX](#install-python-3.12-from-the-deadsnakes-ppa)

### 1. Get The Server Files From The Dashboard

Open `https://dashboard.eyepop.ai`, go to **My Servers**, and click **Add Server**.

The dashboard provides:

* `eyepop-instance.yml`
* a Docker registry login command

Save `eyepop-instance.yml` on the Jetson, for example in `~/eyepop/eyepop-instance.yml`.

The file should look similar to this:

```yaml
eyepop-account-uuid: <your EyePop account UUID>
eyepop-api-key: <your EyePop API key>
instance-name: <your server name>
```

Use the dashboard-provided values as the source of truth.

Make the file readable by Docker:

```sh
chmod 644 eyepop-instance.yml
```

### 2. Log In To The Registry

Run the Docker login command shown in the dashboard on the Jetson.

It will look like this:

```sh
printf '%s' '<registry key secret>' | docker login registry.eyepop.ai \
  -u '<registry key username>' \
  --password-stdin
```

The registry key secret is sensitive. Do not paste it into support tickets or logs.

### 3. Start The Runtime

From the directory containing `eyepop-instance.yml`, run:

```sh
docker run -d \
  --name eyepop-runtime \
  --restart unless-stopped \
  --runtime nvidia \
  -p 8080:8080 \
  -e NVIDIA_VISIBLE_DEVICES=all \
  -e NVIDIA_DRIVER_CAPABILITIES=compute,utility \
  -v "$PWD/eyepop-instance.yml:/etc/eyepop-instance.yml:ro" \
  registry.eyepop.ai/ai/runtime-cuda-jetson:latest
```

Use the Jetson runtime image:

```
registry.eyepop.ai/ai/runtime-cuda-jetson:<tag>
```

Do not mount host CUDA libraries into the container, and do not set `NVIDIA_DISABLE_REQUIRE`.

### 4. Verify

Check health:

```sh
curl http://127.0.0.1:8080/health
```

Check readiness:

```sh
curl http://127.0.0.1:8080/ready
```

Follow logs:

```sh
docker logs -f eyepop-runtime
```

The first run can take a minute while the runtime registers. The first model run can also take longer while the model is downloaded and cached.

### Local Webcam Access

Runtime release `v3.46.0` adds local V4L2 webcam access.

To allow local webcam sources, add this to `eyepop-instance.yml`:

```yaml
allow-v4l2: true
```

Mount the camera device by adding this flag to `docker run`:

```sh
--device /dev/video0:/dev/video0
```

Use a source URL like:

```
v4l2:///dev/video0
```

The camera device path can vary by system. Check available devices with:

```sh
ls /dev/video*
```

### Stop Or Update

Stop the runtime:

```sh
docker stop eyepop-runtime
docker rm eyepop-runtime
```

Update to a newer runtime tag:

```sh
docker pull registry.eyepop.ai/ai/runtime-cuda-jetson:<tag>
docker stop eyepop-runtime
docker rm eyepop-runtime
```

Then run the start command again with the new tag.

### Install Python 3.12 from the deadsnakes PPA

Install the prerequisite for adding custom PPAs,

```
apt install software-properties-common -y
```

Add deadsnakes PPA,

```
add-apt-repository ppa:deadsnakes/ppa
```

Update the package lists to include packages from the newly added PPA,

```
apt update -y
```

Now, you can install Python 3.12 using the `apt` package manager.

```
apt install python3.12
```

Verify Installation,

```
python3.12 --version
```

Output:

```
root@vps:~# python3.12 --version
Python 3.12.0
root@vps:~# 
```

Once installed Python 3.12 using the APT package manager, the PIP will not be installed by default. Install PIP, run the following command,

```
curl -sS https://bootstrap.pypa.io/get-pip.py | python3.12
```

Now check the PIP version using the below command,

```
pip3.12 -V
```

Output:

```
root@vps:~# pip3.12 -V
pip 24.0 from /usr/local/lib/python3.12/dist-packages/pip (python 3.12)
root@vps:~#
```
