Browse Source

Add dockerfile for ppc64le (#638)

* Add dockerfile for ppc64le and related changes

* Pass the fill file as DOCKEFILE

* Add the dockerfile name to build msg
pull/646/head
Hemant Kumar 7 years ago committed by Tobias Schmidt
parent
commit
de08e38c5e
  1. 7
      Dockerfile.ppc64le
  2. 9
      Makefile

7
Dockerfile.ppc64le

@ -0,0 +1,7 @@
FROM ppc64le/busybox:glibc
COPY node_exporter /bin/node_exporter
EXPOSE 9100
USER nobody
ENTRYPOINT [ "/bin/node_exporter" ]

9
Makefile

@ -22,6 +22,8 @@ PREFIX ?= $(shell pwd)
BIN_DIR ?= $(shell pwd)
DOCKER_IMAGE_NAME ?= node-exporter
DOCKER_IMAGE_TAG ?= $(subst /,-,$(shell git rev-parse --abbrev-ref HEAD))
MACH ?= $(shell uname -m)
DOCKERFILE ?= Dockerfile
ifeq ($(OS),Windows_NT)
OS_detected := Windows
@ -77,8 +79,11 @@ tarball: $(PROMU)
@$(PROMU) tarball --prefix $(PREFIX) $(BIN_DIR)
docker:
@echo ">> building docker image"
@docker build -t "$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG)" .
ifeq ($(MACH), ppc64le)
$(eval DOCKERFILE=Dockerfile.ppc64le)
endif
@echo ">> building docker image from $(DOCKERFILE)"
@docker build --file $(DOCKERFILE) -t "$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG)" .
test-docker:
@echo ">> testing docker image"

Loading…
Cancel
Save