forked from heavy-duty/rig
Issue #25 named this consumer when it introduced /etc/rig/role: 'rig <cmd> sanity warnings later (e.g. coolify install on a non-control-plane box)'. Both coolify verbs now read the marker through the lib's read_role_marker (RIG_ROLE_MARKER overrides the path for fixtures, repo precedent) and warn when it names any role but control-plane — the likeliest story is the wrong SSH session about to put a control plane on a workload box. The marker stays advisory: it may be absent (pre-marker boxes, hand-built boxes) and absence stays silent — warning there would nag every legitimate run — and a present-but-different marker warns and proceeds, because an advisory file must never outrank the operator (contrast close-root, where the marker IS the gate: shutting the root door blind is irreversible in a way an extra Coolify is not). The check sits after arg validation and before the root check, so exit codes are untouched (usage stays 2, the root refusal stays 1) and the harness proves it non-root. Tests drive the live matrix through fixture markers (warns on workload, silent on control-plane and on absence, still exits 1 at the root check) and pin the warning's presence in both shipped scripts for root-run environments. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| lib | ||
| bootstrap.sh | ||
| coolify-backup-install.sh | ||
| coolify-install.sh | ||
| db.sh | ||
| runner-install.sh | ||
| runner-remove.sh | ||
| runner-repoint.sh | ||
| runner-status.sh | ||
| users-apply.sh | ||
| users-close-root.sh | ||
| users-status.sh | ||