Replacement for comma.ai backend and useradmin dashboard. Bundled with a modified version of comma's cabana to allow viewing & analyzing drives.
If you don't want to host your own instance, check out https://api.retropilot.org/useradmin for a hosted version of the backend, useradmin and cabana.
The server consists of 2 node scripts.
src/server
is using expressjs and runs the backend (file upload / communication with openpilot) and the useradmin dashboard to manage / view / download drives & logs.src/worker
is a background worker that is processing drives (analyzing video files & logs) to prepare drives for playback in cabana and to gather statistics. It automatically terminates itself after 60 minutes to make sure the video/log libraries do not cause memory leaks.Attention: Minimum required node version is node 10.
TODO: write instructions for PostgreSQL database
npm install
cp config.sample.js config.js
cp database.empty.sqlite database.sqlite
> EDIT config.js
node -r esm src/server
node -r esm src/worker
A compiled version of a custom cabana fork (https://github.com/RetroPilot/cabana) is directly bundled in the cabana/
subdirectory and will be served by the express app. After starting index.js
, cabana is ready to use.
On the device or in your fork's code, replace all API endpoints with your own server endpoint.
This could be executed directly on the device in the shell to use https://api.retropilot.org
as backend:
find /data/openpilot -type f -exec sed -i 's/https:\/\/api.commadotai.com/https:\/\/api.retropilot.org/g' {} +
TODO: add git patch instructions
To switch a device between different servers, you have to remove the old DongleId
and reboot:
rm /data/params/d/DongleID
reboot
There is no need to backup the DongleId
, as the new server will identify your device based on its imei, serial and public key.
If that doesn't help or the option is not available, try:
echo "1" > /data/params/d/IsUploadRawEnabled
echo "1" > /data/params/d/UploadRaw
reboot
OpenPilot before 0.8.3 will not display any statistics or pairing status in the dashboard.
The reason is that pre 0.8.3, the offroad.apk
with react and comma-api would require recompilation to accept the new endpoints.
The athena websockets interface is not implemented yet, so the comma app and athena specific remote control commands (including "upload on demand") are not functional as of now.
For deployment instructions and configuration, take a look at the environment
directory.
https://github.com/RetroPilot/.github/blob/main/profile/CODE_OF_CONDUCT