forked from wrenn/wrenn
WIP: Add Caddy reverse proxy for dev environment
Add Caddy to docker-compose as the single entry point on port 8000: - localhost -> /api/* stripped and proxied to CP:8080, /* to frontend:5173 - *.localhost -> proxied to CP:8080 (sandbox proxy catch-all) - Direct /v1/*, /auth/*, /docs routes proxied to CP Move CP from :8000 to :8080 (its default). Caddy takes :8000. Update .env.example, vite proxy target (kept as fallback), and Makefile dev targets (pg_isready via docker exec, frontend binds 0.0.0.0). This is an intermediate state — needs further work for the full code interpreter feature.
This commit is contained in:
4
Makefile
4
Makefile
@ -39,7 +39,7 @@ dev: dev-infra migrate-up dev-cp
|
||||
dev-infra:
|
||||
docker compose -f deploy/docker-compose.dev.yml up -d
|
||||
@echo "Waiting for PostgreSQL..."
|
||||
@until pg_isready -h localhost -p 5432 -q; do sleep 0.5; done
|
||||
@until docker compose -f deploy/docker-compose.dev.yml exec -T postgres pg_isready -q 2>/dev/null; do sleep 0.5; done
|
||||
@echo "Dev infrastructure ready."
|
||||
|
||||
dev-down:
|
||||
@ -53,7 +53,7 @@ dev-agent:
|
||||
sudo go run ./cmd/host-agent
|
||||
|
||||
dev-frontend:
|
||||
cd frontend && pnpm dev --port 5173
|
||||
cd frontend && pnpm dev --port 5173 --host 0.0.0.0
|
||||
|
||||
dev-envd:
|
||||
cd $(ENVD_DIR) && go run . --debug --listen-tcp :3002
|
||||
|
||||
Reference in New Issue
Block a user