Skip to content

feat(desktop): add and start catalog services through the CLI - #1227

Merged
roodboi merged 27 commits into
nextfrom
codex/desktop-v5-catalog-add
Nov 24, 2026
Merged

roodboi merged 27 commits into
nextfrom
codex/desktop-v5-catalog-add

Conversation

@roodboi

@roodboi roodboi commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

@/home/dimitrikennedy/.local/state/machine/agent-runs/20261123-105514-omarchy-codex-hd-bfbb/handoff/1227-sync-364b753-pr.md

…t-changes

# Conflicts:
#	apps/desktop/app/src/main.rs
#	apps/desktop/app/src/screenshots.rs
#	apps/desktop/app/src/view.rs
#	apps/desktop/core/src/fixtures.rs
#	docs/versions/v5/guides/parallel-work.md
…vice-catalog

# Conflicts:
#	apps/desktop/app/src/main.rs
#	apps/desktop/app/src/view.rs
#	apps/desktop/core/src/fixtures.rs
…ice-catalog

# Conflicts:
#	apps/desktop/app/src/changes_view.rs
#	apps/desktop/app/src/env_view.rs
#	apps/desktop/app/src/main.rs
#	apps/desktop/app/src/screenshots.rs
#	apps/desktop/app/src/view.rs
#	apps/desktop/core/src/fixtures.rs
#	apps/desktop/core/src/git_changes.rs
#	docs/versions/v5/getting-started.md
#	docs/versions/v5/guides/parallel-work.md
@vercel

vercel Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
hack-docs Ready Ready Preview Nov 24, 2026 9:18pm UTC

Request Review

@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: 3d6a3e7

Stack order is next → #1155 → #1227. #1227 targets next and carries #1155 until it lands.

Search for Redis, choose Add to project, review the diff, save, then choose Start redis. The desktop reports the file as saved locally and uncommitted. CLI and app share the curated recipes.

Linux desktop tests (441 passed, one skipped), Rust formatting, both warnings-denied Clippy configurations, repository check, CLI typecheck, and 124 focused tests passed. An isolated live Compose smoke test added Redis and verified the targeted hack up redis start. macOS CI is pending. The feature has no Linux-only code.

Light flow · Dark flow

…log-add

# Conflicts:
#	apps/desktop/app/src/service_catalog.rs
#	apps/desktop/app/src/view.rs
#	apps/desktop/core/src/fixtures.rs
#	docs/versions/v5/getting-started.md
@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: 048f32c

Stack order is next → #1227. Merged origin/next at 364b75327, which includes #1155.

The service catalog now works with Compose-file projects on either backend. Projects authored in .hack/hack.project.json get workload-editing guidance. The native CLI rejects targeted hack up redis before launching the runtime, so the app disables that button and explains how to start the whole project. The Compose backend retains the targeted Start action.

Linux desktop gates, Rust formatting, both Clippy configurations with warnings denied, repository check, CLI typecheck, and 125 focused tests passed. macOS CI is pending for this head. I inspected both themes of the native saved and authored project screens.

Native light · Native dark

@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: b0bd021

Stack order is next → #1227. The missing-project contract now pins hack service add --path … --json to the same E_PROJECT_NOT_FOUND envelope as its peers. All 57 cases passed, as did root bun run typecheck, bun run check, and the Linux desktop gates. Hosted checks are pending for this head.

@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: 574b495

HACK-2636. Stack order is next → #1227.

The catalog now adds a named mount and a top-level volume declaration for each image-declared path. That covers Redis, PostgreSQL, MySQL, both MongoDB paths, and MinIO. Mailpit declares no volumes. The desktop preview and copy include the same declarations as the CLI. Existing top-level block mappings keep their entries and comments. A name collision refuses the edit.

The regression inventory comes from Linux arm64 and amd64 image configs, with MinIO's /data taken from the upstream release Dockerfile because its registry config was unavailable. All 21 focused tests, root typecheck, repository check, and Linux desktop gates passed. I also checked that dry-run diffs apply to the same bytes as Save across five layouts. Live native VM startup and hosted macOS verification remain pending.

Light add flow · Dark add flow

…log-add

# Conflicts:
#	apps/desktop/core/src/fixtures.rs
#	apps/desktop/core/src/source.rs
@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: 432ada2

Stack order is next → #1227. Merged next at 7e1cfe912. Kept #1208 and moved the catalog Start button onto the updated service action path. HACK-2636 remains included.

Linux desktop gates, root check and typecheck, and 189 focused tests passed. Live Compose Redis started via the updated CLI invocation and mounted the generated named volume at /data. The disposable container, network, volume, and scratch were removed. Native VM and hosted macOS verification are pending.

Light · Dark

@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Real-VM check at 574b4956d90abdfb77f111b0ff6706699909cffe (Apple Silicon, native backend, SmolVM 1.35.4). I built the bundle from this head and checked its source revision. Each row ran in a fresh isolated home, with HACK_RUNTIME_BACKEND=native, against a synthetic Compose project that has one web service (python http.server on a loopback port) and comment lines at the top, inside services:, inline and at the end. Targeted hack up <service> was not tested (that is #1233).

Row Result Evidence
1. redis: dry-run, add, whole-project up -d, exec redis -- redis-cli ping, ps --json, down pass Dry-run exits 0, the diff adds redis: plus - redis-data:/data and a new top-level volumes: with redis-data: {}, and the file is unchanged. The real add saves exactly that. All 4 comment lines and every original line are kept. up -d took 12.7 s and redis-cli ping answered PONG on the first try. ps --json showed web and redis running, the web port answered, and after down both were absent (stopped-data-retained).
2a. postgres (added into an existing top-level volumes:) pass Mount postgres-data:/var/lib/postgresql/data. postgres-data: {} was added beside the existing webcache: {} and all 5 comment lines were kept. I set POSTGRES_PASSWORD with hack env set --service postgres --value-stdin (a fake test value that appears in no command output). up -d took 17.8 s and pg_isready -U postgres reported accepting connections on the first try. ps showed web and postgres running, and down was clean.
2b. mongodb (two volumes) pass Mounts mongodb-db:/data/db and mongodb-configdb:/data/configdb, both listed under a new top-level volumes:, with comments kept. up -d took 28.2 s, and a mongosh ping returned {"ok":1} on the first try. ps showed web and mongodb running, and down was clean.
3. second service add redis pass Exits 1 with E_PATH_CONFLICT: Service "redis" already exists.; the --json form gives the same code. service add redis --name web also refuses (Service "web" already exists.). The Compose file's sha256 was unchanged after all three refusals.
4. service add with HACK_RUNTIME_BACKEND=native on a Compose-file project pass Every add in rows 1 and 2 ran under the native backend, exited 0 and printed Saved locally (not committed): .hack/docker-compose.yml. None returned E_NATIVE_PROJECT_UNSUPPORTED.

The graph_image_volume_uncovered refusal seen earlier for the catalog Redis (HACK-2636) did not appear: all three recipes started on native. Each home stopped its pool and left no processes. The homes and the built bundle are deleted. No new issues were filed.

🤖 Generated with Claude Code

@roodboi

roodboi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor Author

Ready for lead: 6ef23ae

Stack order is next → #1227. Merged origin/next at 44f8e873a, including #1172 service stats. The catalog flow and its getting-started instructions are present. #1234 was still open when I checked the base.

Linux desktop gates passed (460 tests, one skipped), including formatting and both warnings-denied Clippy configurations. Repository check and 124 focused tests passed. Native VM add/start coverage for Redis, PostgreSQL, and MongoDB was confirmed by the lead before this merge. Hosted checks are pending for this head.

Resolved to the tree tested in batch run m3:z456 (lead train sync).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@roodboi
roodboi merged commit 30926cb into next Nov 24, 2026
6 of 10 checks passed
@roodboi
roodboi deleted the codex/desktop-v5-catalog-add branch November 24, 2026 21:17
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.

1 participant