-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
35 lines (25 loc) · 694 Bytes
/
Makefile
File metadata and controls
35 lines (25 loc) · 694 Bytes
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
.PHONY: proto build test up down load-test lint
PROTO_DIR := proto
GEN_DIR := proto/gen
proto:
@mkdir -p $(GEN_DIR)
protoc --go_out=$(GEN_DIR) --go_opt=paths=source_relative \
--go-grpc_out=$(GEN_DIR) --go-grpc_opt=paths=source_relative \
-I$(PROTO_DIR) $(PROTO_DIR)/taskqueue.proto
build: proto
go build -o bin/server ./cmd/server
go build -o bin/worker ./cmd/worker
test:
go test -v -race -count=1 ./...
test-integration:
go test -v -race -count=1 -tags=integration ./...
docker-build:
docker build -t distributed-task-queue:latest .
up:
docker compose up --build -d
down:
docker compose down -v
load-test:
go run ./cmd/loadtest/main.go
lint:
golangci-lint run ./...