Skip to content

Barn 0.4.0: one command, working data disks, one voice

A first run that is one command, a default data disk that works on every image, readiness failures that name the cause, and one output style across the CLI.
Note

Historical release record (0.4.0). Old release downloads are retired; use the installation guide for the current release.

Barn 0.4.0 turns the first run into a single command, makes default data disks work out of the box on Debian and Ubuntu images, and unifies output formatting across all CLI commands while keeping the Pigsty inventory format, fixed-IP deployment model, state layout, and embedded catalog revision 2026082903.

What changed

  • Single-command first run. When run in an interactive terminal on a host where the fixed-IP network has not been installed yet, barn up automatically invokes barn setup: it prints the host preparation plan, asks for confirmation before the privileged step, and continues directly into VM startup. barn init now points to barn up as the next command.
  • vm_disks[].fs defaults to auto. Blank data disks are formatted as XFS when the guest has mkfs.xfs and fall back to ext4 otherwise, matching Pigsty’s Vagrant workflow. Previously, the xfs default failed on upstream Debian and Ubuntu cloud images that shipped without xfsprogs. Existing deployments created under the old default are not flagged as configuration drift and keep their persistent disks intact.
  • Clearer guest bootstrap errors. Guest failure markers now capture the failing command’s last output line, so up reports guest bootstrap failed during data-disks: xfs requested but mkfs.xfs is unavailable rather than a bare exit status.
  • Unified CLI output. Lifecycle commands and status print a consistent node table and, after up, a next: barn ssh <node> hint. plan and validate print a single summary line when no changes are needed, while image list, network status, doctor, and preflight errors use plain prose without internal error codes (spec hash and internal metadata remain available via --json). Unknown-node errors list the available node names.
  • Standard SSH command pass-through. barn ssh <node> -- 'df -h /data; id' forwards the remote command string to OpenSSH unchanged.

Upgrading

If a Debian 12/13 or Ubuntu node created with 0.3.0 or earlier failed to mount /data, run barn recreate <node> once so the disk formats as ext4. Non-interactive automation running up on an unprepared host without a TTY should still run barn setup --yes beforehand.

Validation

Source commit 8ecb8476c7dbc934d8cbbee935ac53884d00fcdb passed the full local source gate—unit and race tests, go vet, Staticcheck, deadcode, errcheck, govulncheck, shell and module checks, four-target cross-builds, image-pipeline and installer tests, and dependency-license verification—and the tag workflow built and verified every archive, native package, SBOM, and installer script. Dated macOS arm64/HVF and Ubuntu amd64/KVM acceptance records are listed in the validation history.

Install or upgrade

Download the installer and assets from the Barn 0.4.0 GitHub Release:

curl -fLO https://github.com/pgsty/barn/releases/download/v0.4.0/install.sh
chmod +x install.sh
BARN_VERSION=0.4.0 ./install.sh
barn version
barn doctor

The release includes the Homebrew formula and amd64/arm64 DEB and RPM packages.