Add make victoria-metrics Makefile rule for building dev binary

This commit is contained in:
Aliaksandr Valialkin 2019-05-25 18:24:51 +03:00
parent 2ffcf7a4a5
commit 96ac664b27
2 changed files with 5 additions and 2 deletions

View file

@ -82,8 +82,8 @@ to your needs.
#### Development build #### Development build
1. [Install Go](https://golang.org/doc/install). The minimum supported version is Go 1.12. 1. [Install Go](https://golang.org/doc/install). The minimum supported version is Go 1.12.
2. Run `go build ./app/victoria-metrics` from the root folder of the repository. 2. Run `make victoria-metrics` from the root folder of the repository.
It will build `victoria-metrics` binary in the root folder of the repository. It will build `victoria-metrics` binary and put int into the `bin` folder.
#### Production build #### Production build

View file

@ -1,5 +1,8 @@
# All these commands must run from repository root. # All these commands must run from repository root.
victoria-metrics:
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