Files
computer-playbook/scripts/tests/workspace/compose/01_minimal.sh
kevinveenbirkenbachandClaude Opus 5.5 ba9e51ae85 fix(tests): keep the workspace minimal deploy off the public asset host
compose/01_minimal.sh disabled every variable service of the dashboard,
asset included, and ran both matrix rounds; round 1 of web-app-dashboard
pins the asset provider off as well. Without web-svc-asset the dashboard
renders its logo and favicon from the public
https://file.infinito.nexus/assets, so the workspace test depended on
that host: while it does not answer, Playwright's no-console-noise spec
fails on `net::ERR_CONNECTION_REFUSED` for the logo (main run
39684179395, ubuntu and centos).

The test now keeps the asset provider out of the disable set and pins
round 0, so the dashboard serves its branding from the deployment's own
file service. Round 1 stays covered by the regular dashboard matrix.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-22 10:31:15 +02:00

38 lines
1.8 KiB
Bash
Executable File

#!/usr/bin/env bash
# Deploy on minimal hardware — disable non-essential services to save resources.
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
# shellcheck source=scripts/tests/workspace/utils/common.sh
source "${SCRIPT_DIR}/../utils/common.sh"
# shellcheck source=scripts/tests/workspace/utils/cache.sh
source "${SCRIPT_DIR}/../utils/cache.sh"
echo "Snapshotting cache counters before the deploy."
CACHE_BEFORE="$(cache_snapshot)"
echo "Deploying dashboard with all variable (group-conditional) services disabled, except the asset provider, to speed up the deploy and verify disable= suppresses them from the inventory."
# Exception: without the asset provider the dashboard loads its logo from the public file.infinito.nexus, which ties this test to that host's uptime; variant 1 pins the provider off, so only round 0 runs here.
make compose-deploy mode=reinstall apps="${DASHBOARD_APP}" variant=0 disable="$(variable_services dashboard javascript asset)"
inspect
echo "Actively probing both caches to confirm pull-through works end-to-end."
probe_caches
echo "Probing the DiD inner-build cache path (frontend hijack + apt rewrite)."
probe_did_inner_build
echo "Verifying that BOTH local caches saw real pull-through traffic."
CACHE_AFTER="$(cache_snapshot)"
assert_caches_used "${CACHE_BEFORE}" "${CACHE_AFTER}"
echo "Trusting the local CA certificate so HTTPS endpoints are reachable from the host."
make network-trust-ca
echo "Verifying the dashboard is reachable (matomo was disabled, not the dashboard itself)."
assert_http_status 200 "${DASHBOARD_URL}"
echo "Verifying matomo is not reachable because it was excluded from the inventory."
# Exception: Expect 000 because curl aborts in TLS before HTTP when the excluded hostname is missing from the certificate SANs.
assert_http_status 000 "${MATOMO_URL}"