Skip to content

Rosepetal Controller Installer ​

rosepetal-cli is an interactive installer, a single binary, that turns a vanilla Ubuntu machine into a Rosepetal Controller: it installs the packages the controller needs, enrolls the machine with an enrollment token and starts the controller's containers.

Install ​

To install the latest release of the CLI on the machine:

bash
curl -fsSL https://storage.googleapis.com/rosepetal-cli-dist/install.sh | sudo bash

This downloads rosepetal-cli to /usr/local/bin/ and makes it executable. Re-run the same command any time to update to the latest release.

Then start it and choose Install controller:

bash
sudo rosepetal-cli

Installation describes every step.

Requirements ​

  • Ubuntu 22.04 (jammy) or 24.04 (noble). The CLI does not check the release, but the install uses apt and adds Docker's apt repository for the release's code name, so the release has to be one that Docker publishes packages for.
  • A 64-bit x86 (amd64) machine: the released binary is built for that architecture.
  • Root access through sudo, from an interactive terminal (the console or an SSH session).
  • Outbound internet access to storage.googleapis.com (the download of the CLI and its update check), to the apt repositories (Ubuntu, Docker, NVIDIA), to Tailscale (its install script and its control plane), to the Rosepetal API and to the Artifact Registry host that the API returns for the container images. The firewall rules of a controller in operation are in IT configuration for remote access.
  • An enrollment token (RPC1-XXXX-YYYY) for the controller, or a Rosepetal account that is allowed to create the enrollment during the install. It is needed for Phase 2 only; Phase 1 runs without it.
  • An NVIDIA GPU is optional: a machine without one is installed as a CPU-only controller.

Guides ​

PageContents
InstallationThe install step by step: host check, Phase 1 (packages), the reboot after the NVIDIA driver, Phase 2 (enrollment, Tailscale, containers), installing over SSH, machines without a GPU, reinstalling, the installer USB
UpdatesUpdating the CLI, refreshing the Tailscale proxy of an installed controller, upgrading its modules
BackupsRunning a backup, restoring a controller from a backup file or from the cloud, clearing a controller's data
TroubleshootingThe messages of the installer, what they mean and how to recover

Flow at a glance ​

                vanilla Ubuntu
                       │
                       ▼
              sudo rosepetal-cli            [Install controller]
                       │
                  host check
                       │
       ┌───────────────┴──────────────┐
       ▼                              ▼
   PHASE 1: apt installs        PHASE 2: configure + enroll + install
   - baseline tools             - create user 'rosepetal'
   - OpenSSH                    - delete every other UID≥1000 login user
   - NVIDIA driver (if a GPU)   - enrollment token (pasted or created) + redeem
   - Docker + nvidia-docker2
   - Tailscale binary           from here on, as a background systemd unit:
                                - wipe of a previous install (if confirmed)
   (no token needed yet)        - set hostname to the device name
                                - disable unattended-upgrades / apport
   if nvidia-smi fails          - install rosepetal-network systemd unit
       → ask reboot, exit       - tailscaled syslog override + restart
                                - tailscale up
                                - write /opt/rosepetal/{docker-compose.yml,.env,proxy.sh}
                                - docker login + docker compose pull
                                - pre-pull auxiliary node-red images
                                - docker compose up -d
                                - run /opt/rosepetal/proxy.sh (tailnet serves)
                                - mark the install complete on the API
                                  → install complete, reboot

The phase selection is automatic. On every run the CLI inspects the machine (installed commands and packages, nvidia-smi, the PCI bus, traces of a previous install) and continues from what it finds: nothing is kept between runs, so the same command is used after a reboot or after an interrupted run.

Running Install controller on a machine that already is a controller is a reinstall, not an update: after an explicit confirmation it wipes the previous install, the controller's data in /opt/storage included. See Reinstalling a controller. To update a controller, see Updates; to erase its data but keep its identity, see Clear controller.

sudo rosepetal-cli opens a menu grouped in sections. Move with the arrow keys and confirm with Enter. An entry that cannot run in the current context is shown in red with the reason (needs sudo, not a controller) and cannot be selected.

Without signing in, the menu lists:

SectionEntryNeedsPurpose
CONTROLLERInstall controllersudoInstall the controller on this machine, or reinstall it. See Installation
CONTROLLERRefresh Tailscale proxysudo, an installed controllerRewrite /opt/rosepetal/proxy.sh from the copy inside the CLI and apply the Tailscale serves again. See Updates
CONTROLLERRestore backupsudo, an installed controllerRestore the controller from a backup file or from a backup in the cloud. See Backups
CONTROLLERClear controllersudo, an installed controllerErase the controller's data and recreate its containers, keeping its identity and its module versions. A safety backup is taken first, and the controller's name has to be typed to confirm. See Backups
CONTROLLERRun a backupAn installed controllerRun one of the backup jobs configured on the controller and follow it to the end. See Backups
ACCOUNTSign inSign in with the email and password of a Rosepetal account
TOOLSCreate installer USBsudoBuild the Rosepetal installer image and write it to a USB drive chosen on screen. See Creating an installer USB
QuitLeave the CLI

The session of Sign in is kept in memory only and ends when the CLI exits or with Sign out. Once signed in, the menu also lists the entries that the account has permission for:

SectionEntryShown toPurpose
CONTROLLERUpgrade modulesPlatform administratorsChange the versions of the controller's modules. See Updates
ACCOUNTCreate enrollmentPlatform administratorsCreate an enrollment and show its token, to install a controller elsewhere
ACCOUNTSign outEveryone signed inEnd the session
OTHERPull & run a serviceAccounts with the permission to pull servicesPrint the commands that download and start a service of the Rosepetal catalog, or start it on this machine
OTHERInstall a private npm packageAccounts with the permission to install packagesPrint the configuration and the commands that install a private Rosepetal npm package
OTHERRenew project expiryPlatform administratorsSet the date until which a project is licensed
OTHERGet license tokenAccounts with access to a projectShow a license token of a project, to paste into the License screen of its devices
DATASETSTransfer datasetAccounts allowed to transfer dataCopy a dataset from one project to another
MODELSTransfer modelAccounts allowed to transfer dataCopy a trained model from one project to another
USERSManage usersAccounts that administer membersCreate the users of a partner, assign their roles, edit the roles and the access to projects
SuperAdminBackfill de identidad, Enable gateway, Decommission controllerPlatform administratorsMaintenance of controllers by Rosepetal staff

If the CLI cannot read the permissions of the account after signing in, it shows every entry and the Rosepetal API refuses the ones the account is not allowed to use.

What the Install Changes ​

ItemAfter the install
Packagesgit, vim, wget, curl, net-tools, ethtool and gnupg, plus what the host check finds missing: the OpenSSH server, Docker Engine with the compose plugin and nvidia-docker2, Tailscale and, on a machine with an NVIDIA GPU, the kernel headers and the driver that ubuntu-drivers autoinstall picks
Usersrosepetal, in the groups sudo and docker, with the password the installer sets. Every other login user (UID 1000 or higher) is deleted with its home directory
HostnameThe device name of the enrollment
Automatic updatesunattended-upgrades removed, the periodic apt runs and the release-upgrade prompt disabled, apport disabled
Network tuningrosepetal-network.service runs /opt/rosepetal/rosepetal-network.sh at the install and at every boot. On every network interface whose name starts with enp or enx it sets the MTU to 9000 (jumbo frames), the receive ring to 4096 entries and the interrupt coalescing delays to 0, and turns off receive hashing and Energy-Efficient Ethernet; it also sets larger kernel network buffers and connection backlogs, and selects the performance CPU governor when cpupower is installed
TailscaleJoined to Rosepetal's Tailscale network (tailnet) with the device name as hostname, the tags tag:prod and tag:maintenance, Tailscale SSH enabled and rosepetal as operator. The serves that /opt/rosepetal/proxy.sh configures are reachable from the tailnet only: no public funnels
Install directory/opt/rosepetal/: docker-compose.yml, .env, proxy.sh, rosepetal-network.sh and the controller's identity and license files
Data directory/opt/storage/, where the modules keep their data and the backups are stored (/opt/storage/backups)
ContainersThe modules of the controller, started with docker compose up -d from /opt/rosepetal/
Servicesrosepetal-network.service. During the install, the transient unit rosepetal-install; when the install was started from another account, the one-time rosepetal-user-cleanup.service, which removes that account at the next boot and then deletes itself
Log/var/log/rosepetal-install.log, the output of the background part of the install