-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
49 lines (38 loc) · 984 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
VERSION ?= latest
REGISTRY_BASE ?= 607167088920.dkr.ecr.ap-northeast-1.amazonaws.com/dreamkast-weaver
.PHONY: fmt
fmt:
go fmt ./...
.PHONY: dbmateup
dbmateup:
cd internal/cfp && go run github.com/amacneil/dbmate/v2 up
cd internal/dkui && go run github.com/amacneil/dbmate/v2 up
.PHONY: vet
vet: dbmateup
go vet ./...
go run github.com/sqlc-dev/sqlc/cmd/sqlc vet -f internal/sqlc.yaml
.PHONY: test
test: fmt vet
go test ./... -v --race -coverprofile cover.out
.PHONY: build
build:
go build -o dkw cmd/dkw/main.go
.PHONY: generate
generate:
go generate -x ./...
go run github.com/ServiceWeaver/weaver/cmd/weaver generate ./...
.PHONY: lint
lint:
golangci-lint run -v --fix
.PHONY: multi-deploy
multi-deploy:
weaver multi deploy weaver.toml
.PHONY: multi-status
multi-status:
weaver multi status
.PHONY: build-image
build-image:
docker build -f Dockerfile -t $(REGISTRY_BASE):$(VERSION) .
.PHONY: push-image
push-image:
docker push $(REGISTRY_BASE):$(VERSION)