forked from picodata/stroppy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
51 lines (35 loc) · 1.22 KB
/
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
BUILD_COMMIT=$(shell git rev-list -1 HEAD)
BUILD_DATE=$(shell date +%d-%m-%Y-%H:%M)
VERSION=$(shell build/get_version.sh)
LDFLAGS="-s -w -X main.version=$(VERSION) -X main.commit=$(BUILD_COMMIT) -X main.date=$(BUILD_DATE)"
cache:
go mod tidy
go mod vendor
build:
go build -ldflags=$(LDFLAGS) -o bin/stroppy ./cmd/stroppy
.PHONY: build
all: cache build
clean:
rm -rf _data
postgres_pop:
bin/stroppy pop --url postgres://stroppy:stroppy@localhost/stroppy?sslmode=disable --count 5000 -r 1.02
postgres_pay:
bin/stroppy pay --url postgres://stroppy:stroppy@localhost/stroppy?sslmode=disable --check --count=100000 -r 1.02
postgres_payz:
bin/stroppy pay --url postgres://stroppy:stroppy@localhost/stroppy?sslmode=disable --check --count=100000 -z true
fdb_init:
echo "docker:[email protected]:4500" > fdb.cluster
fdb_pop:
bin/stroppy pop --url fdb.cluster --count 5000 -d fdb -r 1.02
fdb_pay:
bin/stroppy pay --url fdb.cluster --check --count=100000 -d fdb -r 1.02
fdb_payz:
bin/stroppy pay --url fdb.cluster --check --count=100000 -d fdb -z true
fmt:
gofumpt -w -s .
lint:
golangci-lint run --new-from-rev=main --timeout=10m
deploy_yandex:
bin/stroppy deploy --cloud yandex --flavor small --nodes 3
test:
go test ./...