-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
33 lines (25 loc) · 960 Bytes
/
Makefile
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
test:
$(MAKE) clean local-mongo
go test -v ./...
build:
go build -o bin/seeder cmd/seeder/main.go
go build -o bin/client cmd/client/main.go
run-seeder:
$(MAKE) clean local-mongo
go run cmd/seeder/main.go --mongo.uri mongodb://localhost:27017 --check.interval 10s
run-client:
go run cmd/client/main.go --port $(PORT) --server.address http://127.0.0.1:5000
local-mongo:
docker run -d --network host --name seeder-mongo mongo:latest
local-seeder:
$(MAKE) clean local-mongo
docker build -t seeder-image .
docker run --network host --name seeder-server seeder-image:latest seeder --mongo.uri mongodb://localhost:27017 --check.interval 10s
local-client:
docker build -t seeder-image .
docker run --network host --name seeder-client seeder-image:latest client --port $(PORT) --server.address http://127.0.0.1:5000
clean:
rm -rf bin *.bundle
- docker rm -f seeder-server seeder-client seeder-mongo
bundle:
git bundle create seeder.bundle --all