mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
Makefile: extract app-local
and app-local-pure
build rules
This commit is contained in:
parent
ede7ad3703
commit
3685fc18d5
2 changed files with 8 additions and 5 deletions
6
Makefile
6
Makefile
|
@ -75,6 +75,12 @@ vendor-update:
|
||||||
GO111MODULE=on go mod tidy
|
GO111MODULE=on go mod tidy
|
||||||
GO111MODULE=on go mod vendor
|
GO111MODULE=on go mod vendor
|
||||||
|
|
||||||
|
app-local:
|
||||||
|
CGO_ENABLED=1 GO111MODULE=on go build $(RACE) -mod=vendor -ldflags "$(GO_BUILDINFO)" -o bin/$(APP_NAME)$(RACE) $(PKG_PREFIX)/app/$(APP_NAME)
|
||||||
|
|
||||||
|
app-local-pure:
|
||||||
|
CGO_ENABLED=0 GO111MODULE=on go build $(RACE) -mod=vendor -ldflags "$(GO_BUILDINFO)" -o bin/$(APP_NAME)-pure$(RACE) $(PKG_PREFIX)/app/$(APP_NAME)
|
||||||
|
|
||||||
quicktemplate-gen: install-qtc
|
quicktemplate-gen: install-qtc
|
||||||
qtc
|
qtc
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,7 @@
|
||||||
# All these commands must run from repository root.
|
# All these commands must run from repository root.
|
||||||
|
|
||||||
victoria-metrics:
|
victoria-metrics:
|
||||||
APP_NAME=victoria-metrics $(MAKE) app-via-host-builder
|
APP_NAME=victoria-metrics $(MAKE) app-local
|
||||||
|
|
||||||
app-via-host-builder:
|
|
||||||
GO111MODULE=on go build -mod=vendor -ldflags "$(GO_BUILDINFO)" -o bin/victoria-metrics ./app/victoria-metrics
|
|
||||||
|
|
||||||
victoria-metrics-prod:
|
victoria-metrics-prod:
|
||||||
APP_NAME=victoria-metrics $(MAKE) app-via-docker
|
APP_NAME=victoria-metrics $(MAKE) app-via-docker
|
||||||
|
@ -36,7 +33,7 @@ victoria-metrics-arm64-prod:
|
||||||
APP_NAME=victoria-metrics APP_SUFFIX='-arm64' DOCKER_OPTS='--env CGO_ENABLED=0 --env GOARCH=arm64' $(MAKE) app-via-docker
|
APP_NAME=victoria-metrics APP_SUFFIX='-arm64' DOCKER_OPTS='--env CGO_ENABLED=0 --env GOARCH=arm64' $(MAKE) app-via-docker
|
||||||
|
|
||||||
victoria-metrics-pure:
|
victoria-metrics-pure:
|
||||||
GO111MODULE=on CGO_ENABLED=0 go build -mod=vendor -ldflags "$(GO_BUILDINFO)" -o bin/victoria-metrics-pure ./app/victoria-metrics
|
APP_NAME=victoria-metrics $(MAKE) app-local-pure
|
||||||
|
|
||||||
victoria-metrics-pure-prod:
|
victoria-metrics-pure-prod:
|
||||||
APP_NAME=victoria-metrics APP_SUFFIX='-pure' DOCKER_OPTS='--env CGO_ENABLED=0' $(MAKE) app-via-docker
|
APP_NAME=victoria-metrics APP_SUFFIX='-pure' DOCKER_OPTS='--env CGO_ENABLED=0' $(MAKE) app-via-docker
|
||||||
|
|
Loading…
Reference in a new issue