feat(cutover): platform services build from ../mana, not from this repo

Part of the 8-Doppel-Cutover (2026-05-08, plan
~/.claude/plans/floating-swinging-flurry.md):

- docker-compose.{macmini,dev,test}.yml: build context for
  mana-{auth,credits,media,llm,notify} switched to ../mana/services/...
  so the Mac Mini stack pulls platform services from the platform repo
  (sibling clone), not from services/ in this monorepo.
- .npmrc + apps/api/{Dockerfile,package.json}: @mana/media-client now
  resolved from Verdaccio (npm.mana.how, ^0.1.0) instead of as a
  workspace COPY from services/mana-media/packages/client. Build-arg
  NPM_TOKEN flows through .npmrc for pnpm install auth. Required
  before services/mana-media/ can be deleted.
- .github/workflows/{ci,cd-macmini,daily-tests}.yml: removed the
  detect-/build-/test-jobs that targeted services/mana-{auth,credits,
  notify,media}/. Those services build out of the platform repo now —
  CI for them belongs in mana/-repo (open). cd-macmini's
  workflow_dispatch can still rebuild any of them on demand;
  auto-detect on path-change is gone for these five.
- scripts/{mac-mini/push-schemas.sh,run-integration-tests.sh}:
  rewritten to look in ../mana/ for the platform services.
- package.json dev:{auth,credits,notify,media}: paths point at
  ../mana/services/... so local dev still works post-cutover.

What this commit does NOT do: delete services/mana-{auth,credits,...}
from this repo. That waits for Phase 7 once the Mac Mini stack has
booted cleanly from the new build paths.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Till JS 2026-05-08 18:40:08 +02:00
parent 7b362066bb
commit 774852ba2d
12 changed files with 76 additions and 363 deletions

View file

@ -29,8 +29,11 @@ push_schema() {
}
echo "Core Services:"
push_schema "mana-auth" "services/mana-auth"
push_schema "mana-credits" "services/mana-credits"
# Plattform-Services bauen ab dem 2026-05-08-Cutover aus dem
# Schwester-Repo `../mana/`. Auf dem Mac Mini liegt das als
# `/Users/mana/projects/mana/`, parallel zu `mana-monorepo`.
push_schema "mana-auth" "../mana/services/mana-auth"
push_schema "mana-credits" "../mana/services/mana-credits"
push_schema "mana-user" "services/mana-user"
push_schema "mana-subscriptions" "services/mana-subscriptions"
push_schema "mana-analytics" "services/mana-analytics"

View file

@ -50,14 +50,18 @@ trap cleanup EXIT
echo "==> Building & starting test stack"
$DOCKER compose -f "$COMPOSE_FILE" up -d --build --wait
# Plattform-`mana-auth` lebt seit dem 2026-05-08-Cutover im Schwester-
# Repo `../mana/`. Schema-Push und SQL-Migrationen kommen von dort.
MANA_PLATFORM_DIR="${MANA_PLATFORM_DIR:-$REPO_ROOT/../mana}"
echo "==> Pushing mana-auth Drizzle schema into test postgres"
DATABASE_URL="postgresql://mana:testpassword@localhost:5443/mana_platform" \
pnpm --filter @mana/auth db:push --force >/dev/null
( cd "$MANA_PLATFORM_DIR" && DATABASE_URL="postgresql://mana:testpassword@localhost:5443/mana_platform" \
pnpm --filter @mana/auth db:push --force >/dev/null )
echo "==> Applying encryption-vault SQL migrations (002, 003)"
$DOCKER cp "$REPO_ROOT/services/mana-auth/sql/002_encryption_vaults.sql" \
$DOCKER cp "$MANA_PLATFORM_DIR/services/mana-auth/sql/002_encryption_vaults.sql" \
mana-test-postgres:/tmp/002.sql
$DOCKER cp "$REPO_ROOT/services/mana-auth/sql/003_recovery_wrap.sql" \
$DOCKER cp "$MANA_PLATFORM_DIR/services/mana-auth/sql/003_recovery_wrap.sql" \
mana-test-postgres:/tmp/003.sql
$DOCKER exec mana-test-postgres psql -U mana -d mana_platform -f /tmp/002.sql >/dev/null
$DOCKER exec mana-test-postgres psql -U mana -d mana_platform -f /tmp/003.sql >/dev/null