Register your first device
The OTA agent (soc-ota-agent) runs on your target device. It polls the OTA-Pulse backend for pending deployments, downloads firmware artifacts, writes them to the inactive partition, and reboots into the new image. This page explains how to build or obtain the agent, deploy it to a device, and confirm registration.
System requirements
| Requirement | Minimum |
|---|---|
| CPU | ARM or x86_64 |
| RAM | 512 MB |
| Storage | Dual root partitions (A/B layout) |
| OS | Linux with systemd and kernel 4.x+ |
| Network | IP connectivity to the OTA-Pulse backend |
Steps
-
Build the agent
The agent is written in Go. Build it from the
soc-ota-agent/directory in the repository:Terminal window cd ota-pulse/soc-ota-agentmake buildThis produces a statically linked
otapulsebinary in the project root. Alternatively, if you use Yocto, the agent is already packaged as a recipe:Terminal window # In your Yocto build environmentIMAGE_INSTALL:append = " soc-ota-agent"bitbake soc-monitoring-imageThe Yocto path bakes the agent, its config directory, and the systemd service unit directly into your image — skip steps 2–4 below if you take that route.
-
Copy the agent to the device
Copy the binary over SSH:
Terminal window scp otapulse user@<device-ip>:/tmp/soc-ota-agentssh user@<device-ip> "sudo install -m 0755 /tmp/soc-ota-agent /usr/bin/soc-ota-agent" -
Write the configuration
Create the config directory and write
/etc/otapulse/otapulse.confon the device:Terminal window ssh user@<device-ip> "sudo mkdir -p /etc/otapulse"Then place the following JSON at
/etc/otapulse/otapulse.conf, filling in your values:{"ServerURL": "http://<your-server-ip>:8000/api/devices","RootfsPartA": "/dev/disk/by-partlabel/rootfs_a","RootfsPartB": "/dev/disk/by-partlabel/rootfs_b","UpdatePollIntervalSeconds": 1800,"InventoryPollIntervalSeconds": 28800,"RetryPollIntervalSeconds": 300,"RetryPollCount": 10,"StateScriptTimeoutSeconds": 600,"ModuleTimeoutSeconds": 14400,"SkipVerify": false,"UseSoCMonitoring": true,"SoCAPIKey": "<paste-from-console>","SoCDeviceID": "<your-device-id>","ArtifactVerifyKeys": ["/etc/soc-monitoring/signing-keys/active/production-rsa-public.pem","/etc/soc-monitoring/signing-keys/active/production-ecdsa-public.pem"]}Optional fields shown in
examples/soc-monitoring-otapulse.confcan be added if you need them.Field What to put here ServerURLThe URL of the OTA-Pulse backend, including /api/devicesRootfsPartA/RootfsPartBBlock device paths for your A and B root partitions SoCAPIKeyAn API key generated in the console under Settings → API Keys SoCDeviceIDA stable unique identifier for this device (e.g. MAC address or hardware serial) -
Install the systemd service
Copy the unit file from the repository:
Terminal window scp ota-pulse/soc-ota-agent/support/soc-ota-agent.service \user@<device-ip>:/tmp/ssh user@<device-ip> \"sudo cp /tmp/soc-ota-agent.service /etc/systemd/system/ && \sudo systemctl daemon-reload && \sudo systemctl enable soc-ota-agent && \sudo systemctl start soc-ota-agent" -
Verify the device appears in the console
Navigate to http://localhost:3000/devices in the console. Within about 30 seconds of starting the agent, your device should appear with an online status badge.
You can also check from the command line:
Terminal window curl -s http://localhost:8000/health
Quick troubleshooting
If the device does not appear online after 60 seconds, check these first:
- Service not running:
sudo systemctl status soc-ota-agenton the device — look for config file errors. - Network blocked: Run
curl http://<server-ip>:8000/healthfrom the device to confirm the backend is reachable. Check any firewalls between the device and the server. - Clock skew: JWT tokens carry timestamps. If the device clock is more than a few minutes off, authentication will fail. Ensure NTP is running:
sudo systemctl start systemd-timesyncd. - Agent logs:
sudo journalctl -u soc-ota-agent -fshows real-time output.
Next: Ship your first update
With a device registered and online, you’re ready to upload firmware and deploy it.