Skip to content

Commit 1a8a656

Browse files
author
Matthew Fisher
committed
fix(logger): use godep for dependencies
This issue was brought up when building a new release of images for deployment. The logger relied on `go get` to fetch dependencies. Because there was a breaking change in the etcd client[1], the logger failed to connect to the cluster. We have moved over to a global Godeps for managing dependencies, so this changes the compilation on the host to follow the other components' build process. [1]: coreos/go-etcd@5348c80#diff-33c1223aac4ef741731cc8c73b4d7777L295
1 parent 055719e commit 1a8a656

2 files changed

Lines changed: 3 additions & 11 deletions

File tree

logger/Dockerfile

Lines changed: 0 additions & 7 deletions
This file was deleted.

logger/Makefile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,14 @@ COMPONENT = logger
44
IMAGE = $(IMAGE_PREFIX)$(COMPONENT):$(BUILD_TAG)
55
BUILD_IMAGE := $(COMPONENT)-build
66
DEV_IMAGE = $(DEV_REGISTRY)/$(IMAGE)
7+
BINARY_DEST_DIR = image/bin
78

89
build: check-docker
9-
docker build -t $(BUILD_IMAGE) .
10-
docker cp `docker run -d $(BUILD_IMAGE)`:/go/bin/logger image/bin/
10+
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 godep go build -a -v -ldflags '-s' -o $(BINARY_DEST_DIR)/logger github.com/deis/deis/logger || exit 1
1111
docker build -t $(IMAGE) image
12-
rm -rf image/bin/logger
13-
-docker rm -f `docker ps | grep logger-build | awk '{print $$1}'`
1412

1513
clean: check-docker check-registry
14+
rm -f image/bin/logger
1615
docker rmi $(IMAGE)
1716

1817
full-clean: check-docker check-registry

0 commit comments

Comments
 (0)