Skip to content

Captua 0.0.0-pre.3

Pre-release
Pre-release

Choose a tag to compare

@juancobo juancobo released this 24 Jul 23:27
· 2485 commits to main since this release
1d798c2

The first release under the software's name, Captua, and the first validated end-to-end on real hardware: a fresh Raspberry Pi 5 was provisioned from the written documentation and taken through both camera backends, power-cut recovery, and the full update and rollback cycle on the bench (July 23–24). Everything integrated since 0.0.0-pre.2 is included. Captua remains pre-alpha.

Added

A name and a visual identity
The software is now Captua. The release completes the renaming throughout the interface and ships the new identity: the Captua logo and wordmark, light and dark favicons, and Mulish as the interface typeface.

Per-unit secrets at first boot
Captua ships as a cloned SD card, and anything on the card at imaging time is copied bit-for-bit onto every unit — including credentials. A new first-boot service detects placeholder or cloned secrets before the application starts, generates a per-unit signing key and database password, rotates the live Postgres password crash-safely, and records the Pi's hardware serial so a card moved to a new machine regenerates on its own. Imaging a test-booted master is now safe.

Safe updates, with a way back
The update script now dumps the database before migrating, does all its network work before stopping the service, refuses to run unattended when it cannot confirm the update is offline-safe, and verifies the stack came back up. A companion rollback script restores the pre-update dump and returns the code to the last recorded deployment — never blindly to the current tip.

Storage on removable media
External drives can be mounted, activated as the projects storage root, and safely unmounted from the interface. The privileged operations run through a scoped helper with a single sudoers entry, replacing the previous open-ended mount permissions; unmounting a drive that is the active storage automatically reverts to internal storage.

A firewall, and kiosk escape hatches
Provisioning now closes the appliance's LAN surface to the web interface, SSH, and mDNS only. The kiosk gets two documented recovery paths out of the box: Ctrl+Alt+F2 drops to a terminal (Ctrl+Alt+F1 returns), and a dtk-no-kiosk file on the boot partition skips the kiosk for a session.

Interface in Spanish and English
The interface now runs from a full bilingual catalog, selected at login; the choice persists across reboots.

Integrity checking
Administrators can reconcile the database, the files on disk, and the capture manifests from a single endpoint. The check is strictly read-only — it reports discrepancies and never deletes or moves anything. The backend also refuses to start on an unmigrated database, failing visibly instead of running against a wrong schema.

Honest clocks
The Pi has no battery-backed clock, so a power cut used to scramble capture timestamps. Setup now installs fake-hwclock and chrony: time persists across reboots and corrects itself whenever the unit is online.

Fixed

Provisioning survives a fresh start
A verbatim run of the documented setup previously failed several ways: the setup script had lost its executable bit, nothing created the environment file (leaving the database half-initialized with wrong credentials), and the nginx image was never pulled — so a card shipped offline crash-looped on first boot. All fixed; setup also now installs the camera system packages explicitly and adds the operator to the docker group.

Cameras work against the pinned environment
The locked Python environment was ABI-incompatible with the system camera stack, so the ArduCam backend reported no cameras on a fresh install; the DSLR backend's bundled USB library detected nothing even when the command-line tools saw both bodies. The environment now pins numpy below 2 and builds python-gphoto2 from source against the system library. Camera import failures also now report the real error instead of a misleading claim about the operating system.

Capture and display
Collections over one hundred records display in full. The thumbnail strip keeps a stable order under rapid consecutive captures. The collection hierarchy endpoint no longer errors on nested collections. Uploads are size-capped with orphaned files cleaned up on failure. Renaming a project moves its file tree along with it. Storage-override writes are atomic, and a corrupt override file now fails loudly instead of silently falling back.

Sessions and permissions
Session handling got a guard against expired tokens, camera status checks are auth-aware, camera controls are admin-only, annotation deletion is properly guarded, and authentication failures return explicit 401s.

Known limitations

Updating an existing unit requires a current pixi (the lockfile is now format v7) — check pixi --version on target hardware first. The in-backend guard against placeholder secrets is not yet implemented; the systemd ordering is the operative protection. ArduCam dual capture runs seven to eight seconds per pair at medium resolution (DSLR: about four) — optimization is tracked. The frontend is pinned at the bench-tested state; the volume workflow and bug-report panel land next cycle.

Documentation

Acknowledgments

Captua is developed by Adelaida Ávila, Juan Cobo Betancourt (grant PI), Jairo Melo Flórez, Santiago Muñoz Arbeláez (grant co-PI), Lucrezia Pograri, and Catalina Salguero at the Archives, Memory, and Preservation Lab of the University of California, Santa Barbara and at the University of Texas at Austin.

Captua has been made possible in part by a major grant from the National Endowment for the Humanities: Democracy demands wisdom. (NEH Award HAA-304052-25: "Digitization Toolkit: a Blueprint for Egalitarian Access to Technology in Low-Resource Environments".)

Any views, findings, conclusions, or recommendations expressed in this software do not necessarily represent those of the National Endowment for the Humanities.

National Endowment for the Humanities