Skip to content

Commit

Permalink
promu for build is working. Some more tests needed.
Browse files Browse the repository at this point in the history
  • Loading branch information
kbudde committed May 20, 2016
1 parent 4105ea0 commit 7e95114
Show file tree
Hide file tree
Showing 14 changed files with 14 additions and 25 deletions.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.build/
.tarballs/

2 changes: 1 addition & 1 deletion .promu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ verbose: true
repository:
path: github.com/kbudde/rabbitmq_exporter
build:
flags: -a
flags: -a -tags netgo
ldflags: |
-X main.Version={{.Version}}
-X main.Revision={{.Revision}}
Expand Down
9 changes: 7 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
FROM sdurrheimer/alpine-golang-make-onbuild
FROM scratch
MAINTAINER Kris Budde <Kris.Budde@gmail.com>
EXPOSE 9090

COPY rabbitmq_exporter /

EXPOSE 9090

CMD ["/rabbitmq_exporter"]
8 changes: 0 additions & 8 deletions Dockerfile.scratch

This file was deleted.

7 changes: 2 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ tarballs: promu
@echo ">> building crossbuild tarballs"
@$(PROMU) crossbuild tarballs

docker:
docker: build
@echo ">> building docker image"
@docker build -t "$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG)" .

Expand All @@ -62,7 +62,4 @@ promu:
GOARCH=$(subst x86_64,amd64,$(patsubst i%86,386,$(shell uname -m))) \
$(GO) get -v github.com/prometheus/promu

scratch:
CGO_ENABLED=0 GOOS=linux $(GO) build -a -installsuffix cgo -o $(TARGET)_static && docker build -f Dockerfile.scratch -t $(TARGET):scratch .

.PHONY: all style format build test vet tarball docker promu scratc
.PHONY: all style format build test vet tarball tarballs docker promu
1 change: 0 additions & 1 deletion vendor/github.com/Sirupsen/logrus
Submodule logrus deleted from cd7d1b
1 change: 0 additions & 1 deletion vendor/github.com/beorn7/perks
Submodule perks deleted from 3ac7bf
1 change: 0 additions & 1 deletion vendor/github.com/golang/protobuf
Submodule protobuf deleted from 7cc19b
1 change: 0 additions & 1 deletion vendor/github.com/matttproud/golang_protobuf_extensions
Submodule golang_protobuf_extensions deleted from c12348
1 change: 0 additions & 1 deletion vendor/github.com/prometheus/client_golang
Submodule client_golang deleted from d38f1e
1 change: 0 additions & 1 deletion vendor/github.com/prometheus/client_model
Submodule client_model deleted from fa8ad6
1 change: 0 additions & 1 deletion vendor/github.com/prometheus/common
Submodule common deleted from ba1c91
1 change: 0 additions & 1 deletion vendor/github.com/prometheus/procfs
Submodule procfs deleted from abf152
2 changes: 1 addition & 1 deletion version.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package main

var (
Version string
Revision string
Revision string
Branch string
BuildDate string
)

0 comments on commit 7e95114

Please sign in to comment.