forked from volcano-sh/volcano
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
46 lines (35 loc) · 1.04 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
BIN_DIR=_output/bin
BIN_OSARCH=linux/amd64
IMAGE=volcanosh/volcano
TAG = latest
.EXPORT_ALL_VARIABLES:
all: init verify cli images e2e-test-kind
init:
mkdir -p ${BIN_DIR}
cli:
go get github.com/mitchellh/gox
CGO_ENABLED=0 gox -osarch=${BIN_OSARCH} -output ${BIN_DIR}/${BIN_OSARCH}/vkctl ./cmd/cli
image_bins:
go get github.com/mitchellh/gox
for name in controllers scheduler admission; do\
CGO_ENABLED=0 gox -osarch=${BIN_OSARCH} -output ${BIN_DIR}/${BIN_OSARCH}/vk-$$name ./cmd/$$name; \
done
images: image_bins
for name in controllers scheduler admission; do\
cp ${BIN_DIR}/${BIN_OSARCH}/vk-$$name ./installer/dockerfile/$$name/; \
docker build --no-cache -t $(IMAGE)-$$name:$(TAG) ./installer/dockerfile/$$name; \
rm installer/dockerfile/$$name/vk-$$name; \
done
generate-code:
./hack/update-gencode.sh
unit-test:
go list ./... | grep -v e2e | xargs go test -v
e2e-test-kind:
./hack/run-e2e-kind.sh
clean:
rm -rf _output/
rm -f *.log
verify: generate-code
hack/verify-gofmt.sh
hack/verify-golint.sh
hack/verify-gencode.sh