Skip to content

Simplify local install: merge migrate into server, drop dead scripts#86

Merged
MiniMax-AI-Dev merged 1 commit into
mainfrom
chore/simplify-local-install
Jul 11, 2026
Merged

Simplify local install: merge migrate into server, drop dead scripts#86
MiniMax-AI-Dev merged 1 commit into
mainfrom
chore/simplify-local-install

Conversation

@RyanLee-Dev

Copy link
Copy Markdown
Collaborator

Summary

  • Merge the one-shot parsar-init container into parsar-server's own startup (parsar-migrate && exec parsar-server) — goose migrations are idempotent, so this is a safe no-op on every restart, and it drops a container from every install.
  • Rename docker-compose.local.ymldocker-compose.yml, now the only recommended install path and docker compose's default filename (docker compose up works without -f).
  • Fix a curl | bash bug in install.sh: docker compose exec in the health-check loop inherited stdin from the same pipe still delivering the unparsed tail of the script, silently swallowing the closing "Open: http://..." banner. All docker invocations now redirect from /dev/null.
  • Drop dead scripting surface found while auditing the install flow: make docker-image-info (never referenced), make seed-dev / CLI seed-dev subcommand (wrote an inert JSON file nothing reads — the real dev seed path is server/internal/dev/fixtures.go), scripts/parsar-paths.sh (absorbed into scripts/setup.sh via a paths mode flag).
  • docs/deploy/lan-deploy.md: sync container topology/filenames, and fix a pre-existing inaccuracy (doc claimed parsar-init auto-generates PARSAR_MASTER_KEY and prints it to logs — no such code path exists; operators must generate it themselves).

Test plan

  • ./install.sh against a fully empty Postgres volume — confirmed cold-start migrations apply (goose_db_version populated), /healthz and /api/v1/bootstrap/status respond correctly, only 2 containers (postgres, parsar-server)
  • Created a real owner via POST /api/v1/bootstrap, restarted parsar-server, confirmed the owner survives and the restart+migrate no-op completes in ~2s
  • curl | bash-style piped run of install.sh prints the closing banner correctly
  • bash -n on install.sh/scripts/setup.sh, docker compose config --quiet on docker-compose.yml, tsc --noEmit on packages/cli all pass
  • Repo-wide grep confirms no leftover references to docker-compose.local.yml, parsar-init, seed-dev, docker-image-info, or parsar-paths.sh

🤖 Generated with Claude Code

… rename compose file

- docker-compose.local.yml -> docker-compose.yml (this is now the only
  recommended install path, so it gets the name docker compose looks
  for by default)
- Merge the one-shot parsar-init container into parsar-server's own
  startup (parsar-migrate && exec parsar-server); goose migrations are
  idempotent so re-running them on every restart is a cheap no-op.
  Drops a container from every install and removes a depends_on hop.
- install.sh: fix a curl-pipe-to-bash bug where `docker compose exec`
  in the health-check loop inherited stdin from the same pipe still
  delivering the unparsed tail of the script, silently swallowing the
  closing "Open: http://..." banner. Redirect all docker invocations
  from /dev/null.
- Makefile: drop `docker-image-info` (never referenced anywhere) and
  `seed-dev` (wrote an inert JSON file nothing reads; the real dev
  seed path is server/internal/dev/fixtures.go)
- packages/cli: remove the now-orphaned `seed-dev` subcommand
- scripts/setup.sh absorbs scripts/parsar-paths.sh via a `paths` mode
  flag, since the latter was a pure read-only wrapper with no other
  consumers
- docs/deploy/lan-deploy.md: sync container topology + filenames, and
  fix a pre-existing inaccuracy (claimed parsar-init auto-generates
  PARSAR_MASTER_KEY and prints it to logs; no such code path exists —
  operators must generate it themselves)

Verified end-to-end via ./install.sh against a fresh Postgres volume:
migrations apply on cold start, survive container restarts without
touching existing data, and the closing banner now prints correctly
under curl | bash.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@MiniMax-AI-Dev MiniMax-AI-Dev merged commit a08aa81 into main Jul 11, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants