-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
32 lines (21 loc) · 914 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
MAIN_FILE=cmd/files/main.go
build: $(MAIN_FILE)
CGO_ENABLED=0 go build -ldflags "-w -s" $(MAIN_FILE)
run: $(MAIN_FILE)
CGO_ENABLED=0 go run -ldflags "-w -s" $(MAIN_FILE)
test: $(MAIN_FILE)
CGO_ENABLED=1 go test --cover -race -v -ldflags "-w -s" ./...
clean: deployments/compose.yaml
if [ -f *.exe ]; then rm *.exe; fi
docker compose -f deployments/compose.yaml down
build-image: build/package/Containerfile
docker build -f build/package/Containerfile -t tempsy .
git-mod-update:
git submodule update --remote --merge
fmt:
go fix ./... && go fmt ./... && go vet ./...
lint-image: build/package/Containerfile
docker run --rm -i hadolint/hadolint:latest-alpine < build/package/Containerfile
docker run --rm -i hadolint/hadolint:latest-alpine < build/package/test.Containerfile
compose-up: deployments/compose.yaml
docker compose -f deployments/compose.yaml up -d