refactor: rename deployor to rig; canonical heavy-duty/rig URLs

This commit is contained in:
claude-hdb 2026-07-11 08:25:48 +00:00
parent 924090a427
commit df17851108
7 changed files with 55 additions and 55 deletions

View file

@ -9,6 +9,6 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: shellcheck - name: shellcheck
run: shellcheck install.sh bin/deployor commands/*.sh test/cli.sh run: shellcheck install.sh bin/rig commands/*.sh test/cli.sh
- name: cli tests - name: cli tests
run: bash test/cli.sh run: bash test/cli.sh

View file

@ -1,33 +1,33 @@
# deployor # rig
A CLI that turns a **pristine Debian server into a hardened, tailnet-joined A CLI that turns a **pristine Debian server into a hardened, tailnet-joined
node** — one curl, one command. A second command installs a version-pinned node** — one curl, one command. A second command installs a version-pinned
Coolify on a control-plane box. Coolify on a control-plane box.
Philosophy (shared with [claudebox](https://github.com/heavy-duty/claudebox)): Philosophy (shared with [claudebox](https://github.com/heavy-duty/claudebox)):
**public tool, private state**. deployor carries plumbing logic only — no **public tool, private state**. rig carries plumbing logic only — no
hostnames, no bindings, no secrets, nothing about *your* infrastructure. It hostnames, no bindings, no secrets, nothing about *your* infrastructure. It
takes arguments, does its work, and stores no credential, ever. takes arguments, does its work, and stores no credential, ever.
## Install ## Install
```sh ```sh
curl -fsSL https://raw.githubusercontent.com/claude-hdb/deployor/main/install.sh | bash curl -fsSL https://raw.githubusercontent.com/heavy-duty/rig/main/install.sh | bash
``` ```
Installs the tree to `~/.local/share/deployor` and links `deployor` onto your Installs the tree to `~/.local/share/rig` and links `rig` onto your
PATH (`/usr/local/bin` when root). Re-run any time to upgrade. PATH (`/usr/local/bin` when root). Re-run any time to upgrade.
## Commands ## Commands
### `deployor bootstrap <control-plane|workload>` ### `rig bootstrap <control-plane|workload>`
Run as root on the fresh box (over SSH). Convergent — safe to re-run; a Run as root on the fresh box (over SSH). Convergent — safe to re-run; a
second run changes nothing. second run changes nothing.
```sh ```sh
deployor bootstrap control-plane --hostname my-coolify-box rig bootstrap control-plane --hostname my-coolify-box
deployor bootstrap workload --hostname my-prod-box rig bootstrap workload --hostname my-prod-box
``` ```
- `--hostname <name>` — tailnet hostname (default: the role name) - `--hostname <name>` — tailnet hostname (default: the role name)
@ -40,28 +40,28 @@ tailscale and joins your tailnet.
**The pre-auth key:** provide it via the `TS_AUTHKEY` env var or type it at **The pre-auth key:** provide it via the `TS_AUTHKEY` env var or type it at
the interactive prompt. Use a **single-use, tagged, short-expiry** key. It the interactive prompt. Use a **single-use, tagged, short-expiry** key. It
lives in process memory only — deployor never writes a credential to disk. lives in process memory only — rig never writes a credential to disk.
The two roles are identical today except the default hostname; they exist The two roles are identical today except the default hostname; they exist
because control-plane and workload boxes diverge over time, and because the because control-plane and workload boxes diverge over time, and because the
next command applies to exactly one of them. next command applies to exactly one of them.
### `deployor coolify install --version <pin>` ### `rig coolify install --version <pin>`
Control-plane box only. Installs Coolify at exactly the pinned version with Control-plane box only. Installs Coolify at exactly the pinned version with
`AUTOUPDATE=false` — your deploy tooling is verified against an API surface; `AUTOUPDATE=false` — your deploy tooling is verified against an API surface;
the platform must never move underneath it on its own. Upgrading is an the platform must never move underneath it on its own. Upgrading is an
explicit re-run with a new pin. The pin is required; there is no default. explicit re-run with a new pin. The pin is required; there is no default.
## What deployor deliberately does NOT do ## What rig deliberately does NOT do
- **Provider firewalls** — Docker publishes ports past host firewalls, so - **Provider firewalls** — Docker publishes ports past host firewalls, so
the real boundary is your cloud provider's firewall, configured outside the real boundary is your cloud provider's firewall, configured outside
this tool. this tool.
- **Fetch your config** — boxes never receive repo credentials. Everything - **Fetch your config** — boxes never receive repo credentials. Everything
deployor needs arrives as arguments or an interactive prompt. rig needs arrives as arguments or an interactive prompt.
- **Manage deployments** — deploy manifests/executors are separate concerns. - **Manage deployments** — deploy manifests/executors are separate concerns.
(Planned: the `apply`/`diff` executor half joins deployor as commands that (Planned: the `apply`/`diff` executor half joins rig as commands that
run on operator machines, never on boxes.) run on operator machines, never on boxes.)
## Testing ## Testing

View file

@ -5,7 +5,7 @@ ROOT="$(cd "$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")/.." && pwd)"
usage() { usage() {
cat <<'EOF' cat <<'EOF'
usage: deployor <command> [args] usage: rig <command> [args]
commands: commands:
bootstrap <control-plane|workload> [--hostname <name>] [--ts-tag <tag>] bootstrap <control-plane|workload> [--hostname <name>] [--ts-tag <tag>]
@ -16,7 +16,7 @@ commands:
Pinned Coolify install (AUTOUPDATE=false). Control-plane box only. Pinned Coolify install (AUTOUPDATE=false). Control-plane box only.
install/upgrade: install/upgrade:
curl -fsSL https://raw.githubusercontent.com/claude-hdb/deployor/main/install.sh | bash curl -fsSL https://raw.githubusercontent.com/heavy-duty/rig/main/install.sh | bash
EOF EOF
} }
@ -45,7 +45,7 @@ case "$cmd" in
exit 2 exit 2
;; ;;
*) *)
printf 'deployor: unknown command: %s\n' "$cmd" >&2 printf 'rig: unknown command: %s\n' "$cmd" >&2
usage >&2 usage >&2
exit 2 exit 2
;; ;;

View file

@ -1,15 +1,15 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# deployor bootstrap — OS plumbing for a pristine Debian box. # rig bootstrap — OS plumbing for a pristine Debian box.
# Convergent: safe to re-run; a second run changes nothing. # Convergent: safe to re-run; a second run changes nothing.
set -euo pipefail set -euo pipefail
log() { printf 'deployor-bootstrap: %s\n' "$*"; } log() { printf 'rig-bootstrap: %s\n' "$*"; }
warn() { printf 'deployor-bootstrap: WARNING: %s\n' "$*" >&2; } warn() { printf 'rig-bootstrap: WARNING: %s\n' "$*" >&2; }
die() { printf 'deployor-bootstrap: ERROR: %s\n' "$1" >&2; exit "${2:-1}"; } die() { printf 'rig-bootstrap: ERROR: %s\n' "$1" >&2; exit "${2:-1}"; }
usage() { usage() {
cat <<'EOF' cat <<'EOF'
usage: deployor bootstrap <control-plane|workload> [--hostname <name>] [--ts-tag <tag>] usage: rig bootstrap <control-plane|workload> [--hostname <name>] [--ts-tag <tag>]
--hostname tailnet hostname (default: the role name) --hostname tailnet hostname (default: the role name)
--ts-tag tailnet tag to advertise (default: tag:server) --ts-tag tailnet tag to advertise (default: tag:server)
@ -75,7 +75,7 @@ APT::Periodic::Unattended-Upgrade "1";
EOF EOF
# --- sshd hardening (restart only when the drop-in actually changed) --------- # --- sshd hardening (restart only when the drop-in actually changed) ---------
DROPIN=/etc/ssh/sshd_config.d/99-deployor.conf DROPIN=/etc/ssh/sshd_config.d/99-rig.conf
TMP="$(mktemp)" TMP="$(mktemp)"
cat > "$TMP" <<'EOF' cat > "$TMP" <<'EOF'
PermitRootLogin prohibit-password PermitRootLogin prohibit-password
@ -104,5 +104,5 @@ fi
log "done — role ${ROLE}, hostname ${TS_HOSTNAME}" log "done — role ${ROLE}, hostname ${TS_HOSTNAME}"
if [ "$ROLE" = "control-plane" ]; then if [ "$ROLE" = "control-plane" ]; then
log "next: deployor coolify install --version <pin>" log "next: rig coolify install --version <pin>"
fi fi

View file

@ -1,15 +1,15 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# deployor coolify install — pinned Coolify install; AUTOUPDATE=false so the # rig coolify install — pinned Coolify install; AUTOUPDATE=false so the
# platform never self-updates underneath its operators. Upgrades are an # platform never self-updates underneath its operators. Upgrades are an
# explicit act. # explicit act.
set -euo pipefail set -euo pipefail
log() { printf 'deployor-coolify: %s\n' "$*"; } log() { printf 'rig-coolify: %s\n' "$*"; }
die() { printf 'deployor-coolify: ERROR: %s\n' "$1" >&2; exit "${2:-1}"; } die() { printf 'rig-coolify: ERROR: %s\n' "$1" >&2; exit "${2:-1}"; }
usage() { usage() {
cat <<'EOF' cat <<'EOF'
usage: deployor coolify install --version <pin> usage: rig coolify install --version <pin>
Installs Coolify at exactly <pin> (e.g. 4.1.2) with AUTOUPDATE=false. Installs Coolify at exactly <pin> (e.g. 4.1.2) with AUTOUPDATE=false.
Control-plane box only. The version pin is required — you state the floor Control-plane box only. The version pin is required — you state the floor

View file

@ -1,24 +1,24 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
# deployor installer — intended for: curl -fsSL .../install.sh | bash # rig installer — intended for: curl -fsSL .../install.sh | bash
# #
# Downloads the deployor repo tarball, installs the whole tree under $DEST, # Downloads the rig repo tarball, installs the whole tree under $DEST,
# and puts a `deployor` symlink on PATH via $BINDIR. Re-run any time to # and puts a `rig` symlink on PATH via $BINDIR. Re-run any time to
# upgrade. # upgrade.
REPO="${DEPLOYOR_REPO:-claude-hdb/deployor}" REPO="${RIG_REPO:-heavy-duty/rig}"
REF="${DEPLOYOR_REF:-main}" REF="${RIG_REF:-main}"
DEST="${DEPLOYOR_HOME:-$HOME/.local/share/deployor}" DEST="${RIG_HOME:-$HOME/.local/share/rig}"
if [ "$(id -u)" -eq 0 ]; then if [ "$(id -u)" -eq 0 ]; then
BINDIR="${DEPLOYOR_BIN:-/usr/local/bin}" BINDIR="${RIG_BIN:-/usr/local/bin}"
else else
BINDIR="${DEPLOYOR_BIN:-$HOME/.local/bin}" BINDIR="${RIG_BIN:-$HOME/.local/bin}"
fi fi
log() { printf 'deployor-install: %s\n' "$*"; } log() { printf 'rig-install: %s\n' "$*"; }
warn() { printf 'deployor-install: WARNING: %s\n' "$*" >&2; } warn() { printf 'rig-install: WARNING: %s\n' "$*" >&2; }
die() { printf 'deployor-install: ERROR: %s\n' "$*" >&2; exit 1; } die() { printf 'rig-install: ERROR: %s\n' "$*" >&2; exit 1; }
# --- prerequisites ----------------------------------------------------------- # --- prerequisites -----------------------------------------------------------
command -v curl >/dev/null 2>&1 || die "curl is required but was not found." command -v curl >/dev/null 2>&1 || die "curl is required but was not found."
@ -31,19 +31,19 @@ trap cleanup EXIT
URL="https://github.com/$REPO/archive/refs/heads/$REF.tar.gz" URL="https://github.com/$REPO/archive/refs/heads/$REF.tar.gz"
log "installing deployor ($REPO@$REF)" log "installing rig ($REPO@$REF)"
log "downloading $URL" log "downloading $URL"
curl -fsSL "$URL" -o "$TMPDIR/deployor.tar.gz" \ curl -fsSL "$URL" -o "$TMPDIR/rig.tar.gz" \
|| die "failed to download $URL" || die "failed to download $URL"
log "extracting archive" log "extracting archive"
tar -xzf "$TMPDIR/deployor.tar.gz" -C "$TMPDIR" \ tar -xzf "$TMPDIR/rig.tar.gz" -C "$TMPDIR" \
|| die "failed to extract archive" || die "failed to extract archive"
# GitHub archives extract to a single top-level dir like deployor-<ref>/ # GitHub archives extract to a single top-level dir like rig-<ref>/
EXTRACTED="$(find "$TMPDIR" -maxdepth 1 -type d -name 'deployor-*' | head -n1)" EXTRACTED="$(find "$TMPDIR" -maxdepth 1 -type d -name 'rig-*' | head -n1)"
[ -n "$EXTRACTED" ] || die "could not find extracted deployor-* directory in archive" [ -n "$EXTRACTED" ] || die "could not find extracted rig-* directory in archive"
[ -f "$EXTRACTED/bin/deployor" ] || die "archive does not contain bin/deployor — is $REPO@$REF correct?" [ -f "$EXTRACTED/bin/rig" ] || die "archive does not contain bin/rig — is $REPO@$REF correct?"
# --- atomically replace $DEST -------------------------------------------------- # --- atomically replace $DEST --------------------------------------------------
log "installing into $DEST" log "installing into $DEST"
@ -51,12 +51,12 @@ rm -rf "$DEST"
mkdir -p "$(dirname "$DEST")" mkdir -p "$(dirname "$DEST")"
mv "$EXTRACTED" "$DEST" mv "$EXTRACTED" "$DEST"
chmod +x "$DEST/bin/deployor" "$DEST"/commands/*.sh chmod +x "$DEST/bin/rig" "$DEST"/commands/*.sh
# --- put deployor on PATH ------------------------------------------------------ # --- put rig on PATH ------------------------------------------------------
mkdir -p "$BINDIR" mkdir -p "$BINDIR"
ln -sf "$DEST/bin/deployor" "$BINDIR/deployor" ln -sf "$DEST/bin/rig" "$BINDIR/rig"
log "linked $BINDIR/deployor -> $DEST/bin/deployor" log "linked $BINDIR/rig -> $DEST/bin/rig"
# --- PATH check ---------------------------------------------------------------- # --- PATH check ----------------------------------------------------------------
case ":$PATH:" in case ":$PATH:" in
@ -67,4 +67,4 @@ case ":$PATH:" in
;; ;;
esac esac
log "done — try: deployor --help" log "done — try: rig --help"

View file

@ -25,11 +25,11 @@ check() {
echo "ok: $desc"; PASS=$((PASS + 1)) echo "ok: $desc"; PASS=$((PASS + 1))
} }
check "no args shows usage, exit 2" 2 "usage:" "$ROOT/bin/deployor" check "no args shows usage, exit 2" 2 "usage:" "$ROOT/bin/rig"
check "--help exits 0" 0 "usage:" "$ROOT/bin/deployor" --help check "--help exits 0" 0 "usage:" "$ROOT/bin/rig" --help
check "help exits 0" 0 "usage:" "$ROOT/bin/deployor" help check "help exits 0" 0 "usage:" "$ROOT/bin/rig" help
check "unknown command exits 2" 2 "unknown command" "$ROOT/bin/deployor" frobnicate check "unknown command exits 2" 2 "unknown command" "$ROOT/bin/rig" frobnicate
check "bare coolify shows usage, exit 2" 2 "usage:" "$ROOT/bin/deployor" coolify check "bare coolify shows usage, exit 2" 2 "usage:" "$ROOT/bin/rig" coolify
check "bootstrap: role required, exit 2" 2 "role required" "$ROOT/commands/bootstrap.sh" check "bootstrap: role required, exit 2" 2 "role required" "$ROOT/commands/bootstrap.sh"
check "bootstrap: --help exits 0" 0 "usage:" "$ROOT/commands/bootstrap.sh" --help check "bootstrap: --help exits 0" 0 "usage:" "$ROOT/commands/bootstrap.sh" --help