Name the server OMARCHY_REPO_HOST, not OMARCHY_BUILD_HOST
Builds now happen wherever the operator likes, so naming the destination after building described the old arrangement rather than the current one. What the push and deploy commands reach is the machine that serves pkgs.omarchy.org and holds the signing key: the repository host. It also runs the scheduled builds, which is why the trigger in omarchy-pkgs release points at the same place. Resolution moves into helpers/host-helpers.sh, which all three commands now share instead of repeating: --host, then OMARCHY_REPO_HOST, then .repo-host. OMARCHY_BUILD_HOST and .build-host keep working as fallbacks, so existing environments and checkouts are unaffected. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
fd9c078bf2
commit
34326295e9
7 files changed
+101
-57
No files matched your search
+7
-8
@@ -15,6 +15,7 @@ set -e
|
||||
|
||||
BUILD_ROOT=$(realpath "${BASH_SOURCE[0]%/*}/..")
|
||||
source "$BUILD_ROOT/helpers/message-helpers.sh"
|
||||
source "$BUILD_ROOT/helpers/host-helpers.sh"
|
||||
|
||||
UPSTREAM_URL="${OMARCHY_UPSTREAM_URL:-https://github.com/basecamp/omarchy.git}"
|
||||
EDGE_DB_URL="${OMARCHY_EDGE_DB_URL:-https://pkgs.omarchy.org/edge/x86_64/omarchy.db.tar.zst}"
|
||||
@@ -43,8 +44,8 @@ Options for release:
|
||||
--commit <sha> (rc) Upstream commit to pin (default: tip of --ref)
|
||||
--ref <branch> (rc) Upstream branch whose tip to pin (default: $DEFAULT_RC_REF)
|
||||
--yes Skip confirmation prompts
|
||||
--host <host> ssh destination of the build host to trigger, overriding
|
||||
\$OMARCHY_BUILD_HOST and .build-host
|
||||
--host <host> ssh destination of the repository host to trigger,
|
||||
overriding \$OMARCHY_REPO_HOST and .repo-host
|
||||
--no-push Rewrite and commit locally; skip push and build trigger
|
||||
--pr When releasing from a non-master branch, open a GitHub PR
|
||||
to master with gh after pushing
|
||||
@@ -314,11 +315,9 @@ regenerate_checksums() {
|
||||
# --- trigger -----------------------------------------------------------------
|
||||
|
||||
trigger_build_host() {
|
||||
local host="${BUILD_HOST_OVERRIDE:-}"
|
||||
[[ -z "$host" ]] && host="${OMARCHY_BUILD_HOST:-}"
|
||||
[[ -z "$host" && -f "$BUILD_ROOT/.build-host" ]] && host=$(<"$BUILD_ROOT/.build-host")
|
||||
if [[ -z "$host" ]]; then
|
||||
print_info "No build host configured (set OMARCHY_BUILD_HOST or $BUILD_ROOT/.build-host)."
|
||||
local host
|
||||
if ! host=$(resolve_repo_host "${REPO_HOST_OVERRIDE:-}"); then
|
||||
print_info "No repository host configured (set OMARCHY_REPO_HOST or $BUILD_ROOT/.repo-host)."
|
||||
print_info "The 6-hourly auto-release timer will pick this up, or trigger manually:"
|
||||
echo " ssh <build-host> 'git -C /root/omarchy-pkgs pull --ff-only && touch /root/.state/.sync-needed-edge && systemctl start omarchy-auto-release-edge.service'"
|
||||
return 0
|
||||
@@ -344,7 +343,7 @@ cmd_release() {
|
||||
--force) force=true; shift ;;
|
||||
--commit) commit_arg="$2"; shift 2 ;;
|
||||
--ref) ref="$2"; shift 2 ;;
|
||||
--host) BUILD_HOST_OVERRIDE="$2"; shift 2 ;;
|
||||
--host) REPO_HOST_OVERRIDE="$2"; shift 2 ;;
|
||||
--yes) assume_yes=true; shift ;;
|
||||
--dry-run) dry_run=true; shift ;;
|
||||
-h | --help) show_usage; exit 0 ;;
|
||||
|
||||
Reference in new issue
Block a user