Skip to content

Commit 0e8ee78

Browse files
committed
gcloud is now forcing -- be present for all docker commands
1 parent 7458904 commit 0e8ee78

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

nginx-controller/Makefile

+5-5
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@ DOCKERFILE = Dockerfile
1111
BUILD_IN_CONTAINER = 1
1212
PUSH_TO_GCR =
1313

14-
ifeq ($(PUSH_TO_GCR),1)
15-
GCLOUD = gcloud
16-
endif
17-
1814
nginx-ingress:
1915
ifeq ($(BUILD_IN_CONTAINER),1)
2016
$(DOCKER_RUN) -e CGO_ENABLED=0 $(GOLANG_CONTAINER) go build -a -installsuffix cgo -ldflags "-w -X main.version=${VERSION}" -o nginx-ingress *.go
@@ -33,7 +29,11 @@ container: test nginx-ingress
3329
docker build -f $(DOCKERFILE) -t $(PREFIX):$(TAG) .
3430

3531
push: container
36-
$(GCLOUD) docker push $(PREFIX):$(TAG)
32+
ifeq ($(PUSH_TO_GCR),1)
33+
gcloud docker -- push $(PREFIX):$(TAG)
34+
else
35+
docker push $(PREFIX):$(TAG)
36+
endif
3737

3838
osx:
3939
ifeq ($(BUILD_IN_CONTAINER),1)

nginx-plus-controller/Makefile

+5-5
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ GOLANG_CONTAINER = golang:1.7
1010
BUILD_IN_CONTAINER = 1
1111
PUSH_TO_GCR =
1212

13-
ifeq ($(PUSH_TO_GCR),1)
14-
GCLOUD = gcloud
15-
endif
16-
1713
nginx-plus-ingress:
1814
ifeq ($(BUILD_IN_CONTAINER),1)
1915
$(DOCKER_RUN) -e CGO_ENABLED=0 $(GOLANG_CONTAINER) go build -a -installsuffix cgo -ldflags "-w -X main.version=${VERSION}" -o nginx-plus-ingress *.go
@@ -32,7 +28,11 @@ container: test nginx-plus-ingress
3228
docker build -t $(PREFIX):$(TAG) .
3329

3430
push: container
35-
$(GCLOUD) docker push $(PREFIX):$(TAG)
31+
ifeq ($(PUSH_TO_GCR),1)
32+
gcloud docker -- push $(PREFIX):$(TAG)
33+
else
34+
docker push $(PREFIX):$(TAG)
35+
endif
3636

3737
osx:
3838
ifeq ($(BUILD_IN_CONTAINER),1)

0 commit comments

Comments
 (0)