-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
74 lines (54 loc) · 2.37 KB
/
Makefile
File metadata and controls
74 lines (54 loc) · 2.37 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
COMPOSE = docker compose -f platform/dev/docker-compose.dev.yml
.PHONY: up up-infra up-core build down down-v restart ps logs \
migrate-user \
test test-unit test-integration \
run-user
# ── Infrastructure ──────────────────────────────────────────────────────────
## Start full dev stack (infra + all .NET services); run `make build` first on first use
up:
$(COMPOSE) up -d
## Build all .NET service images
build:
$(COMPOSE) build --parallel
## Start only infrastructure (no .NET services)
up-infra:
$(COMPOSE) up -d postgres mongo redis kafka kafka-init minio minio-init keycloak otel-collector livekit coturn kafka-ui
## Start only core services (postgres, redis, kafka, minio) — no Keycloak/LiveKit/etc.
up-core:
$(COMPOSE) up -d postgres redis kafka minio kafka-init minio-init
## Stop all containers (preserve volumes)
down:
$(COMPOSE) down
## Stop all containers and delete volumes (full reset)
down-v:
$(COMPOSE) down -v
## Restart all containers
restart:
$(COMPOSE) restart
## Show running containers
ps:
$(COMPOSE) ps
## Tail logs (Ctrl+C to stop)
logs:
$(COMPOSE) logs -f
## Tail logs for a specific service: make logs-SERVICE (e.g. make logs-keycloak)
logs-%:
$(COMPOSE) logs -f $*
# ── Database migrations ─────────────────────────────────────────────────────
## Apply EF Core migrations for UserService
migrate-user:
cd src/Services/User/UserService.Api && dotnet ef database update
# ── Tests ───────────────────────────────────────────────────────────────────
## Run all tests
test:
dotnet test
## Run unit tests only
test-unit:
dotnet test tests/unit/UserService.UnitTests/
## Run integration tests only
test-integration:
dotnet test tests/integration/UserService.IntegrationTests/
# ── Services ────────────────────────────────────────────────────────────────
## Run UserService locally
run-user:
cd src/Services/User/UserService.Api && dotnet run