-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
532 lines (470 loc) Β· 20.4 KB
/
Copy pathMakefile
File metadata and controls
532 lines (470 loc) Β· 20.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
.PHONY: help up down logs clean api worker web venv
.PHONY: db-migrate db-upgrade db-downgrade db-stamp db-shell db-query db-init
.PHONY: db-local-shell db-local-query
.PHONY: db-staging-init db-staging-migrate db-staging-upgrade db-staging-proxy
.PHONY: db-prod-init db-prod-migrate db-prod-upgrade db-prod-proxy
.PHONY: openapi-sync openapi-validate openapi-diff codegen lint fmt test ci
.PHONY: test-db-up test-db-down test-api test-worker test-web
.PHONY: demo-nats demo-nats-install demo-nats-check demo-all nats-monitor
.PHONY: nats-purge nats-info
.PHONY: gcp-auth gcp-deploy-all gcp-deploy-nats gcp-deploy-worker
.PHONY: gcp-status gcp-logs-api gcp-logs-worker gcp-logs-nats
.PHONY: test-api-local test-worker-local test-all-local
PROJECT=planet
COMPOSE=cd infra && docker compose
# Environment management (default: development)
ENV ?= development
ALEMBIC_CONFIG = db/alembic.ini
# Root environment files (shared across all apps)
ifeq ($(ENV),local)
ROOT_ENV = .env.local
else ifeq ($(ENV),staging)
ROOT_ENV = .env.staging
else ifeq ($(ENV),production)
ROOT_ENV = .env.production
else
ROOT_ENV = .env.development
endif
# Helper function to load env files (root + optional override)
# Usage: $(call load_env,app_name)
define load_env
@set -a; \
[ -f $(ROOT_ENV) ] && . $(ROOT_ENV); \
[ -f apps/$(1)/.env.$(ENV).override ] && . apps/$(1)/.env.$(ENV).override; \
set +a
endef
help:
@echo "$(PROJECT) - Available Commands"
@echo "===================================="
@echo ""
@echo "Environment: $(ENV) (override with ENV=local|staging|production)"
@echo ""
@echo "Infrastructure (Docker):"
@echo " make dev - Start core services (Docker Compose: Postgres 18, NATS)"
@echo " make up - Start all services (compose)"
@echo " make down - Stop all services"
@echo " make logs - Tail compose logs"
@echo ""
@echo "Services (Local Development):"
@echo " make clean - Kill all running service processes (API, worker, web)"
@echo " make api [ENV=...] - Run API service (default: development)"
@echo " make worker [ENV=...] - Run worker service (default: development)"
@echo " make web - Run web app locally (dev)"
@echo ""
@echo "NATS Demo (Quick Start):"
@echo " make demo-nats-install - Install dependencies (one-time setup)"
@echo " make demo-nats-check - Check all services are ready"
@echo " make demo-all - Start all services in background + run demo"
@echo " make demo-nats - Run NATS integration demo script"
@echo " make nats-monitor - Monitor NATS stream in real-time"
@echo ""
@echo "Database Commands (Environment-aware):"
@echo " make db-init [ENV=...] - Initialize database (development/staging/production)"
@echo " make db-migrate msg=\"...\" [ENV=...] - Generate migration"
@echo " make db-upgrade [ENV=...] - Apply migrations"
@echo " make db-downgrade [ENV=...] - Revert migration"
@echo " make db-stamp rev=\"...\" [ENV=...] - Stamp database to specific revision"
@echo ""
@echo "Cloud SQL Proxy (Staging/Production):"
@echo " make db-staging-proxy - Start Cloud SQL proxy for staging (port 5433)"
@echo " make db-prod-proxy - Start Cloud SQL proxy for production (port 5434)"
@echo ""
@echo "Development Tools:"
@echo " make venv - Create local Python venv with Alembic"
@echo " make openapi-sync - Sync spec from running API"
@echo " make openapi-validate - Validate spec.yaml"
@echo " make openapi-diff - Check if spec matches running API"
@echo " make codegen - Generate TS types from spec"
@echo " make lint - Lint all packages/services"
@echo " make fmt - Format all packages/services"
@echo " make ci - CI placeholder"
@echo ""
@echo "Testing:"
@echo " make test-db-up - Start test database (Docker)"
@echo " make test-db-down - Stop test database"
@echo " make test-api - Run API tests (starts test DB if needed)"
@echo " make test-web - Run Web tests"
@echo " make test-worker - Run worker tests (placeholder)"
@echo " make test - Run all tests"
@echo ""
@echo "Local Testing (Plan A - Shared Infrastructure):"
@echo " make test-api-local - Start API test infrastructure (shared DB + NATS)"
@echo " make test-worker-local - Start Worker test infrastructure (shared DB + NATS)"
@echo " make test-all-local - Start all test infrastructure"
@echo ""
@echo "GCP Deployment (Plan A):"
@echo " make gcp-auth - Authenticate to GCP and get GKE credentials"
@echo " make gcp-deploy-all - Deploy all infrastructure (NATS + Worker)"
@echo " make gcp-deploy-nats - Deploy NATS to infrastructure namespace"
@echo " make gcp-deploy-worker - Deploy Worker to staging and production"
@echo " make gcp-status - Show status of all GKE resources"
@echo " make gcp-logs-api - View API logs from GKE"
@echo " make gcp-logs-worker - View Worker logs from GKE"
@echo " make gcp-logs-nats - View NATS logs from GKE"
up:
$(COMPOSE) up -d
down:
$(COMPOSE) down
logs:
$(COMPOSE) logs -f --tail=200
clean:
@echo "Killing all service processes..."
@-pkill -9 -f "uvicorn" 2>/dev/null || true
@-pkill -9 -f "python3 src/run.py" 2>/dev/null || true
@-pkill -9 -f "python3 src/main.py" 2>/dev/null || true
@-pkill -9 -f "apps/worker" 2>/dev/null || true
@-pkill -9 -f "apps/api" 2>/dev/null || true
@-pkill -9 -f "bun.*next" 2>/dev/null || true
@-pkill -9 -f "node.*next" 2>/dev/null || true
@-lsof -ti:8000 | xargs kill -9 2>/dev/null || true
@-lsof -ti:3000 | xargs kill -9 2>/dev/null || true
@-lsof -ti:3001 | xargs kill -9 2>/dev/null || true
@echo "β All services stopped (Docker daemon left running)"
@echo " Run 'make down' to stop Docker containers"
api:
@echo "Starting API with environment: $(ENV)"
$(call load_env,api); \
cd apps/api && poetry run python3 -m src.run
worker:
@echo "Starting Worker with environment: $(ENV)"
$(call load_env,worker); \
cd apps/worker && poetry run python3 -m src.main
web:
@cd apps/web && bun run dev
VENV=.venv
ACTIVATE=. $(VENV)/bin/activate
venv:
@test -d $(VENV) || (python3 -m venv $(VENV) && $(ACTIVATE) && pip install --upgrade pip && pip install alembic SQLAlchemy psycopg2-binary)
@echo "Dont forget to manually activate the venv with: source $(VENV)/bin/activate"
# ============================================================================
# Database Commands (Docker - Recommended)
# ============================================================================
# Uses containerized Postgres on localhost:5432
# Accessible across all repos (api, worker, etc)
# Use once
db-init:
@echo "Initializing database for environment: $(ENV)..."
@set -a; . $(ROOT_ENV); set +a; \
psql $$(echo $$DATABASE_URL | sed 's/postgresql+psycopg2/postgresql/') -c \
"CREATE TABLE IF NOT EXISTS alembic_version (version_num VARCHAR(64) NOT NULL, CONSTRAINT alembic_version_pkc PRIMARY KEY (version_num));"
@echo "β Database initialized for $(ENV)"
db-migrate:
@test -n "$(msg)" || (echo "Usage: make db-migrate msg=\"your message\" [ENV=...]" && exit 1)
@echo "Generating Alembic revision for $(ENV): $(msg)"
@set -a; . $(ROOT_ENV); set +a; \
REV_ID=$$(date +"%Y%m%d_%H%M%S"); \
bash -lc "source $(VENV)/bin/activate; alembic -c $(ALEMBIC_CONFIG) revision --rev-id \"$${REV_ID}_$(msg)\" -m \"$(msg)\""
db-upgrade:
@echo "Applying DB migrations for $(ENV)..."
@set -a; . $(ROOT_ENV); set +a; \
bash -lc 'source $(VENV)/bin/activate; alembic -c $(ALEMBIC_CONFIG) upgrade head'
@echo "β Migrations applied for $(ENV)"
db-downgrade:
@echo "Reverting last migration for $(ENV)..."
@set -a; . $(ROOT_ENV); set +a; \
bash -lc 'source $(VENV)/bin/activate; alembic -c $(ALEMBIC_CONFIG) downgrade -1'
db-stamp:
@test -n "$(rev)" || (echo "Usage: make db-stamp rev=\"revision_id\" [ENV=...]" && exit 1)
@echo "Stamping database to revision $(rev) for $(ENV)..."
@set -a; . $(ROOT_ENV); set +a; \
bash -lc 'source $(VENV)/bin/activate; alembic -c $(ALEMBIC_CONFIG) stamp $(rev)'
@echo "β Database stamped to $(rev) for $(ENV)"
db-staging-proxy:
@echo "Starting Cloud SQL Proxy for staging..."
@cloud-sql-proxy overflying-db:europe-west1:overflying-db --port 5433
db-prod-proxy:
@echo "Starting Cloud SQL Proxy for production..."
@cloud-sql-proxy overflying-db:europe-west1:overflying-db --port 5434
# Not used currently
db-local-shell:
@echo "Connecting to local Postgres..."
@psql -d planet
# Not used currently
db-local-query:
@echo "Querying jobs from local Postgres..."
@psql -d planet -c "SELECT * FROM jobs ORDER BY created_at DESC;"
# Not used currently
openapi-diff:
@echo "Checking if manual spec matches API..."
@curl -s http://localhost:8000/openapi.json > /tmp/openapi-live.json
@python3 openapi/openapi-diff.py
@rm -f /tmp/openapi-live.json
# Not used currently
openapi-validate:
@echo "Validating OpenAPI spec..."
@npx -y @redocly/cli lint openapi/spec-generated.json --config openapi/.redocly.yaml || true
# Used currently
openapi-sync:
@echo "Syncing OpenAPI spec from FastAPI..."
@curl -s http://localhost:8000/openapi.json | python3 -m json.tool > openapi/spec-generated.json
@echo "β Spec synced to spec-generated.json (spec.yaml unchanged)"
# Used currently
codegen:
@echo "Generating TS types from OpenAPI..."
@npx -y openapi-typescript openapi/spec-generated.json -o packages/shared-types/ts/index.ts
@echo "β TS types generated"
lint:
@echo "Running Ruff linter..."
@ruff check apps/api/src apps/worker/src 2>/dev/null || true
@echo "Linting complete!"
fmt:
@echo "Running Ruff formatter..."
@ruff format apps/api/src apps/worker/src 2>/dev/null || true
@ruff check --fix apps/api/src apps/worker/src 2>/dev/null || true
@echo "Formatting complete!"
test-db-up:
@echo "Starting shared test infrastructure (PostgreSQL + NATS)..."
@cd apps/api && docker compose -f docker-compose.test.yml up -d
@echo "Waiting for services to be ready..."
@sleep 5
@docker exec api-test-db pg_isready -U test > /dev/null 2>&1 || (echo "Test DB not ready" && exit 1)
@echo "β Test infrastructure ready (PostgreSQL on :5433, NATS on :4222)"
test-db-down:
@echo "Stopping shared test infrastructure..."
@cd apps/api && docker compose -f docker-compose.test.yml down
@echo "β Test infrastructure stopped"
test-api: test-db-up
@echo "Running API tests..."
@cd apps/api && poetry install --with dev && \
DATABASE_URL="postgresql+psycopg2://test:test@localhost:5433/test_db" \
TEST_DATABASE_URL="postgresql+psycopg2://test:test@localhost:5433/test_db" \
NATS_URL="nats://localhost:4222" \
poetry run pytest
@echo "β API tests complete"
test-web:
@echo "Running Web tests..."
@cd apps/web && bun install --silent && bun run test
@echo "β Web tests complete"
test-worker: test-db-up
@echo "Running Worker tests..."
@cd apps/worker && poetry install --with dev && \
DATABASE_URL="postgresql+psycopg2://test:test@localhost:5433/test_db" \
TEST_DATABASE_URL="postgresql+psycopg2://test:test@localhost:5433/test_db" \
NATS_URL="nats://localhost:4222" \
poetry run pytest
@echo "β Worker tests complete"
test: test-api test-worker
@echo "β All tests complete"
ci:
@echo "CI local placeholder"
# ============================================================================
# NATS Demo Commands
# ============================================================================
demo-nats-install:
@echo "Installing dependencies for NATS demo..."
@echo ""
@echo "1. Installing API dependencies..."
@cd apps/api && pip install -e . -q
@echo " β API ready"
@echo ""
@echo "2. Installing Worker dependencies..."
@cd apps/worker && pip install -e . -q
@echo " β Worker ready"
@echo ""
@echo "3. Installing Frontend dependencies..."
@cd apps/web && bun install --silent
@echo " β Frontend ready"
@echo ""
@echo "β All dependencies installed!"
@echo ""
@echo "Next steps:"
@echo " 1. Ensure database is set up: make db-upgrade"
@echo " 2. Check services: make demo-nats-check"
@echo " 3. Run demo: make demo-all"
demo-nats-check:
@echo "Checking NATS demo prerequisites..."
@echo ""
@echo "1. Checking Docker services..."
@docker ps --filter "name=planet-dev-postgres" --format "{{.Names}}" | grep -q planet-dev-postgres && echo " β PostgreSQL running" || echo " β PostgreSQL not running (run: make dev)"
@docker ps --filter "name=planet-dev-nats" --format "{{.Names}}" | grep -q planet-dev-nats && echo " β NATS running" || echo " β NATS not running (run: make dev)"
@echo ""
@echo "2. Checking NATS health..."
@curl -s http://localhost:8222/varz > /dev/null && echo " β NATS API responding" || echo " β NATS not healthy"
@echo ""
@echo "3. Checking database connection..."
@docker exec planet-dev-postgres pg_isready -U postgres > /dev/null 2>&1 && echo " β Database ready" || echo " β Database not ready"
@echo ""
@echo "All checks complete!"
demo-all:
@echo "=================================================="
@echo "Starting NATS Demo (All Services)"
@echo "=================================================="
@echo ""
@echo "π‘ This will start API, Worker, and Frontend in background"
@echo " Press Ctrl+C to stop monitoring, then run 'make clean' to stop services"
@echo ""
@sleep 2
@echo "1. Starting infrastructure (PostgreSQL + NATS)..."
@$(MAKE) dev
@echo " Waiting for services to be healthy..."
@sleep 5
@docker exec planet-dev-postgres pg_isready -U postgres || (echo "PostgreSQL not ready" && exit 1)
@curl -s http://localhost:8222/varz > /dev/null || (echo "NATS not ready" && exit 1)
@echo " β Infrastructure ready"
@echo ""
@echo "2. Starting API in background..."
@set -a; . $(ROOT_ENV); set +a; \
cd apps/api && nohup python3 -m src.run > /tmp/planet-api.log 2>&1 & echo $$! > /tmp/planet-api.pid
@echo " Waiting for API to start..."
@sleep 5
@curl -s http://localhost:8000/health > /dev/null && echo " β API running" || echo " β API may still be starting (check logs: tail -f /tmp/planet-api.log)"
@echo ""
@echo "3. Starting Worker in background..."
@set -a; . $(ROOT_ENV); set +a; \
cd apps/worker && nohup python3 src/main.py > /tmp/planet-worker.log 2>&1 & echo $$! > /tmp/planet-worker.pid
@sleep 3
@echo " β Worker running (logs: tail -f /tmp/planet-worker.log)"
@echo ""
@echo "4. Starting Frontend in background..."
@cd apps/web && nohup bun dev > /tmp/planet-web.log 2>&1 & echo $$! > /tmp/planet-web.pid
@sleep 4
@echo " β Frontend running (logs: tail -f /tmp/planet-web.log)"
@echo ""
@echo "=================================================="
@echo "β All services started!"
@echo "=================================================="
@echo ""
@echo "Services:"
@echo " - API: http://localhost:8000"
@echo " - Frontend: http://localhost:3000"
@echo " - NATS UI: http://localhost:8222"
@echo ""
@echo "Logs:"
@echo " - API: tail -f /tmp/planet-api.log"
@echo " - Worker: tail -f /tmp/planet-worker.log"
@echo " - Frontend: tail -f /tmp/planet-web.log"
@echo ""
@echo "π‘ TIP: Open another terminal and run: tail -f /tmp/planet-*.log"
@echo ""
@echo "Now running demo in 3 seconds..."
@sleep 3
@$(MAKE) demo-nats
demo-nats:
@echo "=================================================="
@echo "NATS Integration Demo"
@echo "=================================================="
@echo ""
@echo "Creating 3 test jobs and monitoring real-time events..."
@echo ""
@./scripts/demo-nats.sh || echo "Demo script failed. Check if services are running with: make demo-nats-check"
nats-monitor:
@echo "Monitoring NATS JetStream in real-time..."
@echo "Press Ctrl+C to stop"
@echo ""
@curl -N http://localhost:8222/jsz?streams=1 2>/dev/null | python3 -m json.tool || \
echo "NATS not responding. Start with: make dev"
nats-purge:
@echo "Purging JOBS stream..."
@curl -X POST "http://localhost:8000/admin/purge-stream?stream_name=JOBS" 2>/dev/null && \
echo "β Stream purged" || \
echo "β Failed. Make sure API is running: make api"
nats-info:
@echo "JetStream Info:"
@curl -s http://localhost:8222/jsz | jq '.'
# ============================================================================
# GCP Deployment Commands (Plan A Infrastructure)
# ============================================================================
GCP_PROJECT=overflying-cluster
GCP_REGION=europe-west1
GCP_CLUSTER=overflying-autopilot
gcp-auth:
@echo "Authenticating to GCP and getting GKE credentials..."
gcloud auth login
gcloud config set project $(GCP_PROJECT)
gcloud container clusters get-credentials $(GCP_CLUSTER) \
--region=$(GCP_REGION) \
--project=$(GCP_PROJECT)
@echo "β Authenticated and connected to GKE cluster"
gcp-deploy-all:
@echo "Deploying all infrastructure to GKE..."
@chmod +x scripts/deploy-infrastructure.sh
@./scripts/deploy-infrastructure.sh
gcp-deploy-nats:
@echo "Deploying NATS to GKE infrastructure namespace..."
kubectl create namespace infrastructure --dry-run=client -o yaml | kubectl apply -f -
kubectl apply -f k8s/infrastructure/nats-deployment.yaml
kubectl wait --for=condition=ready pod -l app=nats -n infrastructure --timeout=120s
@echo "β NATS deployed successfully"
@echo ""
@echo "Verify with:"
@echo " kubectl get pods -n infrastructure"
@echo " kubectl logs -n infrastructure -l app=nats"
gcp-deploy-worker:
@echo "Deploying Worker to GKE..."
@echo ""
@echo "β οΈ Make sure DATABASE_URL_STAGING and DATABASE_URL_PRODUCTION are set!"
@echo ""
@if [ -z "$$DATABASE_URL_STAGING" ] || [ -z "$$DATABASE_URL_PRODUCTION" ]; then \
echo "Error: Set environment variables first:"; \
echo " export DATABASE_URL_STAGING='postgresql://...'"; \
echo " export DATABASE_URL_PRODUCTION='postgresql://...'"; \
exit 1; \
fi
@echo "Setting up secrets..."
cd k8s/worker && chmod +x setup-secrets.sh && ./setup-secrets.sh
@echo "Deploying to staging..."
kubectl apply -f k8s/worker/staging-deployment.yaml
@echo "Deploying to production..."
kubectl apply -f k8s/worker/production-deployment.yaml
@echo "β Worker deployed successfully"
@echo ""
@echo "Verify with:"
@echo " kubectl get pods -n staging -l app=worker"
@echo " kubectl get pods -n production -l app=worker"
gcp-status:
@echo "=================================================="
@echo "GCP Infrastructure Status"
@echo "=================================================="
@echo ""
@echo "Infrastructure Namespace (NATS):"
@kubectl get all -n infrastructure
@echo ""
@echo "Staging Namespace:"
@kubectl get all -n staging
@echo ""
@echo "Production Namespace:"
@kubectl get all -n production
gcp-logs-api:
@echo "API logs (staging):"
@kubectl logs -n staging -l app=api --tail=50
gcp-logs-worker:
@echo "Worker logs (staging):"
@kubectl logs -n staging -l app=worker --tail=50
gcp-logs-nats:
@echo "NATS logs (infrastructure):"
@kubectl logs -n infrastructure -l app=nats --tail=50
# ============================================================================
# Local Testing with Shared Infrastructure (Plan A)
# ============================================================================
test-api-local:
@echo "Starting shared test infrastructure for API..."
@cd apps/api && docker compose -f docker-compose.test.yml up -d
@echo "Waiting for services to be ready..."
@sleep 5
@echo "β Test infrastructure running:"
@echo " - PostgreSQL: localhost:5433 (user: test, password: test, db: test_db)"
@echo " - NATS: localhost:4222 (client), localhost:8222 (monitoring)"
@echo ""
@echo "Run tests with:"
@echo " cd apps/api && DATABASE_URL='postgresql+psycopg2://test:test@localhost:5433/test_db' NATS_URL='nats://localhost:4222' pytest"
@echo ""
@echo "Stop with:"
@echo " cd apps/api && docker compose -f docker-compose.test.yml down"
test-worker-local:
@echo "Starting shared test infrastructure for Worker..."
@cd apps/worker && docker compose -f docker-compose.test.yml up -d
@echo "Waiting for services to be ready..."
@sleep 5
@echo "β Test infrastructure running:"
@echo " - PostgreSQL: localhost:5433 (user: test, password: test, db: test_db)"
@echo " - NATS: localhost:4222 (client), localhost:8222 (monitoring)"
@echo ""
@echo "Run tests with:"
@echo " cd apps/worker && DATABASE_URL='postgresql+psycopg2://test:test@localhost:5433/test_db' NATS_URL='nats://localhost:4222' pytest"
@echo ""
@echo "Stop with:"
@echo " cd apps/worker && docker compose -f docker-compose.test.yml down"
test-all-local:
@echo "Note: API and Worker share the same test infrastructure (test-db and test-nats)"
@echo "Starting from the API directory will make it available to both."
@$(MAKE) test-api-local