Deployment check: the CMS host must offer Offerings and Hero (the site uses them)
The old rule said Offerings must be off for ASF; since the packages feature the site needs it. The check was never run in CMS mode on ASF-test before. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -11,7 +11,7 @@
|
|||||||
# headers staan met de exacte waarde op elk antwoord (pagina, asset,
|
# headers staan met de exacte waarde op elk antwoord (pagina, asset,
|
||||||
# 301, 404, robots.txt), cachebeleid, alleen gzip (nooit br), een
|
# 301, 404, robots.txt), cachebeleid, alleen gzip (nooit br), een
|
||||||
# procentgecodeerd pad blijft gecodeerd, en /admin, /health en
|
# procentgecodeerd pad blijft gecodeerd, en /admin, /health en
|
||||||
# /api/v1/System/capabilities (zonder Offerings) antwoorden.
|
# /api/v1/System/capabilities (met Offerings en Hero) antwoorden.
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
if [ "$#" -lt 2 ] || [ "$#" -gt 4 ]; then
|
if [ "$#" -lt 2 ] || [ "$#" -gt 4 ]; then
|
||||||
@@ -272,7 +272,7 @@ if [ "$cms_mode" -eq 1 ]; then
|
|||||||
fail "POST /: status $status, verwacht 405"
|
fail "POST /: status $status, verwacht 405"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# De CMS-routes: health, admin, API (zonder Offerings), onbekend API-pad
|
# De CMS-routes: health, admin, API (met Offerings en Hero), onbekend API-pad
|
||||||
fetch /health
|
fetch /health
|
||||||
if [ "$status" != "200" ]; then fail "/health: status $status, verwacht 200"; fi
|
if [ "$status" != "200" ]; then fail "/health: status $status, verwacht 200"; fi
|
||||||
|
|
||||||
@@ -301,8 +301,13 @@ if [ "$cms_mode" -eq 1 ]; then
|
|||||||
fetch /api/v1/System/capabilities
|
fetch /api/v1/System/capabilities
|
||||||
if [ "$status" != "200" ]; then
|
if [ "$status" != "200" ]; then
|
||||||
fail "/api/v1/System/capabilities: status $status, verwacht 200"
|
fail "/api/v1/System/capabilities: status $status, verwacht 200"
|
||||||
elif grep -qi 'offerings' "$work/body"; then
|
else
|
||||||
fail "/api/v1/System/capabilities noemt Offerings; die module hoort voor ASF uit te staan"
|
# De site haalt pakketten, banners en de hero uit deze modules
|
||||||
|
for module in Offerings Hero; do
|
||||||
|
if ! grep -qi "\"$module\"" "$work/body"; then
|
||||||
|
fail "/api/v1/System/capabilities noemt $module niet; de site heeft die module nodig"
|
||||||
|
fi
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Een onbekend API-pad is een API-404, nooit de website
|
# Een onbekend API-pad is een API-404, nooit de website
|
||||||
|
|||||||
Reference in New Issue
Block a user