1
0
Fork 0
mirror of https://github.com/prometheus-operator/prometheus-operator.git synced 2025-04-21 11:48:53 +00:00

separate build the binary and container

This commit is contained in:
Frederic Branczyk 2017-01-31 15:16:09 +01:00
parent 5663dd9a81
commit 64502939e2
No known key found for this signature in database
GPG key ID: CA14788B1E48B256
3 changed files with 7 additions and 4 deletions

1
.gitignore vendored
View file

@ -1 +1,2 @@
/operator
.build/

View file

@ -1,5 +1,5 @@
FROM quay.io/prometheus/busybox:latest
ADD operator /bin/operator
ADD .build/linux-amd64/operator /bin/operator
ENTRYPOINT ["/bin/operator"]
ENTRYPOINT ["/bin/operator"]

View file

@ -14,6 +14,9 @@ all: check-license format build test
build: promu
@$(PROMU) build --prefix $(PREFIX)
crossbuild: promu
@$(PROMU) crossbuild
test:
@go test -short $(pkgs)
@ -24,7 +27,6 @@ check-license:
./scripts/check_license.sh
container:
GOOS=linux $(MAKE) build
docker build -t $(REPO):$(TAG) .
e2e-test:
@ -46,4 +48,4 @@ promu:
GOARCH=$(subst x86_64,amd64,$(patsubst i%86,386,$(shell uname -m))) \
go get -u github.com/prometheus/promu
.PHONY: all build test format check-license container e2e-test e2e-status e2e clean-e2e
.PHONY: all build crossbuild test format check-license container e2e-test e2e-status e2e clean-e2e