No description
  • TypeScript 93.4%
  • Shell 5.1%
  • PowerShell 1.5%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Oliver Maklott be7bfb8d64
All checks were successful
check / check (push) Successful in 12s
release / release (push) Successful in 27s
Merge pull request 'RotoStudio: new names; legacy instances keep working (0.3.0)' (#6) from rotostudio into main
2026-11-23 22:21:49 +01:00
.forgejo RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
.githooks RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
docs RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
scripts RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
src RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
tests RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
.gitignore Initial commit: license 2026-11-15 20:05:47 +00:00
CLAUDE.md RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
deno.json RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
deno.lock rotocmd: operator CLI for Rotoscopia Docker instances 2026-11-15 20:05:50 +00:00
install.ps1 rotocmd: operator CLI for Rotoscopia Docker instances 2026-11-15 20:05:50 +00:00
install.sh rotocmd: operator CLI for Rotoscopia Docker instances 2026-11-15 20:05:50 +00:00
LICENSE.md Initial commit: license 2026-11-15 20:05:47 +00:00
main.ts RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00
README.md RotoStudio: new package, image and setting names; legacy instances keep working (0.3.0) 2026-11-22 21:27:48 +00:00

rotocmd

The operator CLI for RotoStudio. It bootstraps, updates and runs RotoStudio instances on Docker, renders projects with the headless renderer on a GPU server, and updates itself. It is a single executable; the only host requirement is Docker with the compose plugin (for render: Docker with the NVIDIA Container Toolkit).

Install

# Linux, macOS
curl -fsSL https://git.belowtoxic.cloud/api/packages/belowtoxic.eu/generic/rotocmd/latest/install.sh | sh
# Windows (Docker Desktop)
irm https://git.belowtoxic.cloud/api/packages/belowtoxic.eu/generic/rotocmd/latest/install.ps1 | iex

Both scripts check the binary against its .sha256 file and release-trust.json. ROTOCMD_VERSION installs a given version; ROTOCMD_INSTALL_DIR changes the target directory (default ~/.local/bin).

Use

rotocmd bootstrap                 # asks for a directory (./rotostudio) and port (8080), starts it
rotocmd status                    # containers, pinned image, health and running version
rotocmd update --check            # what an update would change
rotocmd update                    # back up, update, restart, wait for health
rotocmd logs --follow
rotocmd down | up
rotocmd self-update

# Track and export a project prepared in the browser app (headless renderer, NVIDIA GPU)
rotocmd render shot.rsproj --video shot.mp4 --out renders/
rotocmd render shot.rsproj --video shot.mp4 --out renders/ -- --export exr,rgba --from 100 --to 250
Command What it does
bootstrap [--dir] [--version <v>|latest|edge] [--port] [--bind] [--image] [--force] [--no-start] Downloads and checks the deploy bundle of a release, writes docker-compose.yml, env.example, README.md and .env with the image pinned to <repo>:<tag>@sha256:…, pulls, starts, waits for /api/health.
update [--check] [--version] [--image] [--yes] A release moves to latest (never back); edge stays on edge. Checks that the image exists, shows the plan (image, changed files, new settings in env.example), backs up .env and changed files to .rotocmd-backup/update-<time>/, writes, pulls, restarts. The health check decides; on failure it prints the rollback.
list, use [<id>|<path>] | --clear Instances on this host (* = selected) and the selection.
up, down, status, logs [--follow] [--tail] docker compose for the instance.
render <project> --video <file> --out <dir> [--version] [--cpu] [-- <renderer options>] Runs the headless renderer image (rotostudio-headless) on a project: checks its release-trust.json, checks that Docker has NVIDIA GPU support (unless --cpu), pulls the image by digest, and runs it with the project and video mounted read-only and --out writable. Progress streams to stderr; Ctrl-C stops the container. The version defaults to the installed instance's (else latest). See rotocmd help render.
version [--check], self-update [--check] [--version] rotocmd itself.

Every command supports --json, which prints one object: {ok, command, id, message, messages, data}. Exit codes: 0 ok, 1 failed, 2 wrong usage.

Which instance

An instance is a directory with docker-compose.yml and .env. The directory's name is the instance id and the compose project name. A command works on:

  1. -i/--instance <id|path>;
  2. otherwise ROTOSTUDIO_DEPLOY_DIR;
  3. otherwise the instance selected with rotocmd use;
  4. otherwise the current directory, if it is an instance;
  5. otherwise the only instance on the host.

rotocmd list finds instances in four places:

  • the ones rotocmd set up or was pointed at;
  • the ones Docker runs;
  • directories one level below ROTOCMD_INSTANCE_SEARCH (default /opt /srv $HOME);
  • the current directory.

Instances from before the rename

RotoStudio was called Rotoscopia up to 0.13 (legacy name). rotocmd still works with what those versions left behind (D006):

  • An instance whose docker-compose.yml and .env use the legacy ROTOSCOPIA_IMAGE is found, listed and run as before; its /api/health may still answer with the legacy app id.
  • rotocmd update moves it to the rotostudio package and image. It writes the new docker-compose.yml, renames the legacy ROTOSCOPIA_IMAGE= line of .env to ROTOSTUDIO_IMAGE= and leaves every other byte of .env as it is. The plan shows the rename; the backup and the rollback cover the old docker-compose.yml too.
  • The legacy variable ROTOSCOPIA_DEPLOY_DIR is used when ROTOSTUDIO_DEPLOY_DIR is not set.
  • render takes legacy .rotoscopia projects as well as .rsproj ones. For an instance still on 0.13 or older, it runs that version's renderer from the legacy rotoscopia-headless package.

A docker-compose.override.yml next to docker-compose.yml is passed to compose last. rotocmd never writes it.

Environment

Variable Default
ROTOCMD_PACKAGES_URL https://git.belowtoxic.cloud/api/packages/belowtoxic.eu/generic Registry (deploy bundles and rotocmd)
ROTOCMD_VERIFY_SIGNATURES warn off, warn, enforce. Releases are not signed yet (D003).
ROTOCMD_STATE_DIR $XDG_STATE_HOME/rotocmd Instance registry and selection
ROTOCMD_INSTANCE_SEARCH /opt /srv $HOME Where list looks for instances
ROTOCMD_HEALTH_TIMEOUT_SECS 120 How long bootstrap/update/up wait for /api/health
ROTOCMD_HEARTBEAT_SECS 15 "still running" interval for long Docker steps (0: off)
ROTOCMD_PIN_IMAGE_DIGEST 1 0 writes the tag without digest
ROTOCMD_DOCKER docker Docker CLI to call (e.g. podman with a compose provider)
ROTOCMD_ALLOW_INSECURE_URL — 1 allows a plain-HTTP registry mirror
ROTOSTUDIO_DEPLOY_DIR — Instance to work on (like -i)

Develop

git config core.hooksPath .githooks
deno task check          # fmt, lint, type check, tests
tests/install_sh_test.sh # install.sh against a local registry
scripts/check-naming.sh  # the old app name only on legacy lines (D006)
deno task compile        # dist/rotocmd

Releases: see docs/ci.md. Decisions: docs/decisions.md.

License: FSL-1.1-ALv2.