The upstream compose.host-ports.yml exists only from v1.0.0+, but the upgrade-tier base deploy is the previous published version (0.2.0+), which predates it — so EXTRA_ENV's COMPOSE_FILE failed to resolve on the base deploy (config --images rc=14, deploy FATA). install_steps.sh now copies a cc-ci-owned identical overlay into the recipe checkout when absent, so 64738 is host-published for every version (base + upgrade) and on-host protocol tests reach 127.0.0.1:64738. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
30 lines
1.6 KiB
Bash
30 lines
1.6 KiB
Bash
#!/usr/bin/env bash
|
|
# mumble — INSTALL-TIME hook (Phase 2 Q4.2). Runs during the install tier AFTER `abra app new` +
|
|
# EXTRA_ENV + `abra app secret generate` and BEFORE the single `abra app deploy`
|
|
# (lifecycle.py::_run_install_steps), with CCCI_RECIPE / CCCI_APP_DOMAIN / CCCI_APP_ENV in env.
|
|
#
|
|
# Purpose: guarantee `compose.host-ports.yml` exists in the recipe checkout for EVERY version under
|
|
# test. mumble's voice server speaks a non-HTTP TLS protocol on 64738; cc-ci's tests run on-host
|
|
# (cc-ci-run) and reach it at 127.0.0.1:64738 via a host-published port. The upstream recipe ships
|
|
# compose.host-ports.yml only from version 1.0.0+, but the upgrade tier's base deploy is the previous
|
|
# published version (0.2.0+), which predates it — so EXTRA_ENV's COMPOSE_FILE (which references the
|
|
# overlay) would fail to resolve on that base deploy. We provide an identical overlay here so the
|
|
# overlay is present whether the checked-out version ships it natively (no-op) or not (copied).
|
|
set -euo pipefail
|
|
|
|
: "${CCCI_RECIPE:?missing CCCI_RECIPE}"
|
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
RECIPE_DIR="${HOME}/.abra/recipes/${CCCI_RECIPE}"
|
|
|
|
if [ ! -d "$RECIPE_DIR" ]; then
|
|
echo " mumble install_steps: recipe dir $RECIPE_DIR missing — cannot provide host-ports overlay" >&2
|
|
exit 1
|
|
fi
|
|
|
|
if [ -f "$RECIPE_DIR/compose.host-ports.yml" ]; then
|
|
echo " mumble install_steps: compose.host-ports.yml already present (native to this version)"
|
|
else
|
|
cp "$SCRIPT_DIR/compose.host-ports.yml" "$RECIPE_DIR/compose.host-ports.yml"
|
|
echo " mumble install_steps: provided compose.host-ports.yml to recipe checkout (${CCCI_RECIPE})"
|
|
fi
|