diff --git a/ai/frontend-context.md b/ai/frontend-context.md index 213d164..3462801 100644 --- a/ai/frontend-context.md +++ b/ai/frontend-context.md @@ -36,19 +36,14 @@ Install dependencies in a fresh checkout or worktree: direnv exec "$(git rev-parse --show-toplevel)" npm install ``` -To start only the development server on the port assigned by the shell hook: +Start the development server on the port assigned by the shell hook: ```sh direnv exec "$(git rev-parse --show-toplevel)" \ - npm run dev -- \ - --host 127.0.0.1 \ - --port "$VITE_PORT" \ - --strictPort + npm run dev -- --port "$VITE_PORT" ``` -`process-compose` starts the frontend as part of the full development stack. -The frontend remains directly accessible on `VITE_PORT`; Caddy does not proxy -it. +`process-compose` does not start or proxy the frontend. The available validation commands are: diff --git a/ai/shared.md b/ai/shared.md index 97f3e33..9c921c2 100644 --- a/ai/shared.md +++ b/ai/shared.md @@ -74,15 +74,12 @@ those changes with the most relevant parser, formatter, dry run, or check. - Run backend commands from `backend/`, or explicitly change into it in the command. The direnv target remains the worktree root. - Run frontend commands from `frontend/website/`. -- `process-compose` starts the frontend on the worktree's assigned port. To - start only the frontend: +- `process-compose` does not start the frontend. Start it separately with + the worktree's assigned port when needed: ```sh direnv exec "$(git rev-parse --show-toplevel)" \ - npm run dev -- \ - --host 127.0.0.1 \ - --port "$VITE_PORT" \ - --strictPort + npm run dev -- --port "$VITE_PORT" ``` - When a normally valid check fails because a required service is down, diff --git a/nix/shell-hook.sh b/nix/shell-hook.sh index d835131..90e0f50 100644 --- a/nix/shell-hook.sh +++ b/nix/shell-hook.sh @@ -124,5 +124,4 @@ if [ ! -e "$REPO_ROOT/backend/public/storage" ]; then (cd "$REPO_ROOT/backend" && php artisan storage:link) fi -echo "[dev] run 'process-compose up' to start:" \ - "postgres + mailpit + backend + caddy + frontend" +echo "[dev] run 'process-compose up' to start postgres + mailpit + backend + caddy" diff --git a/process-compose.yaml b/process-compose.yaml index ad7a160..dc1ea2f 100644 --- a/process-compose.yaml +++ b/process-compose.yaml @@ -44,21 +44,6 @@ processes: initial_delay_seconds: 2 period_seconds: 10 - frontend: - command: >- - npm run dev -- - --host 127.0.0.1 - --port ${VITE_PORT:-5173} - --strictPort - working_dir: ./frontend/website - readiness_probe: - http_get: - host: 127.0.0.1 - port: ${VITE_PORT:-5173} - path: / - initial_delay_seconds: 1 - period_seconds: 2 - caddy: command: caddy run --config Caddyfile --adapter caddyfile depends_on: