pushing stuff that was worked on

This commit is contained in:
twooey committed 2026-08-28 15:17:46 -04:00
1 parent 773883a0f3
commit 197938f482
22 files changed
+1251 -124

No files matched your search

+20 -3
View File
@@ -68,8 +68,9 @@ printf '%s' "$DB_ROOT_PASSWORD_VALUE" > "$SECRETS_DIR/db_root_password"
HARDCOVER_API_TOKEN_VALUE="$(env_get "$ENV_FILE" HARDCOVER_API_TOKEN)"
printf '%s' "$HARDCOVER_API_TOKEN_VALUE" > "$SECRETS_DIR/hardcover_api_token"
# Same reasoning/pattern as Hardcover above — optional, written unconditionally.
# Payments\HelcimConfig::is_configured() is false (and the gateway stays
# unconfigured) until a real sandbox token lands in HELCIM_API_TOKEN.
# Payments\HelcimGatewayConfig::is_configured() is false (and the
# gateway falls back to fake mode — see HelcimClient) until a real
# sandbox token lands in HELCIM_API_TOKEN.
HELCIM_API_TOKEN_VALUE="$(env_get "$ENV_FILE" HELCIM_API_TOKEN)"
printf '%s' "$HELCIM_API_TOKEN_VALUE" > "$SECRETS_DIR/helcim_api_token"
if [[ -z "$HELCIM_API_TOKEN_VALUE" ]]; then
@@ -117,11 +118,27 @@ if ! $WP core is-installed; then
--skip-email
fi
# WordPress defaults to plain "?p=123" permalinks on a fresh install,
# which silently breaks routing for /my-account/, the Store API
# (/wp-json/wc/store/v1/...), and any other pretty-URL path — confirmed
# directly (my-account fell through to the homepage instead of 404ing,
# which made the problem non-obvious). "Rewrite rules are empty" further
# down in this script was this same root cause going unfixed on every
# deploy until now.
echo "==> setting pretty permalinks (required for Store API / my-account routing)"
$WP rewrite structure '/%postname%/'
$WP rewrite flush --hard
echo "==> installing/activating theme (Blocksy — free; Book Store starter site needs a manual license + import, see README)"
$WP theme install blocksy --activate
echo "==> installing/activating required plugins"
$WP plugin install woocommerce redis-cache blocksy-companion helcim-commerce-for-woocommerce --activate
# helcim-commerce-for-woocommerce (the off-the-shelf, immediate-charge-
# only plugin) is deliberately NOT installed here anymore — Payments\
# HelcimGateway (shipped inside bookstore-core) replaces it with a
# preauth-then-capture flow built directly against HelcimPay.js. See
# design doc Appendix B's revised decision.
$WP plugin install woocommerce redis-cache blocksy-companion --activate
$WP plugin activate bookstore-core
$WP redis enable || true