Makefile: Fix bashism when building on Ubuntu + dash
Reference: https://wiki.ubuntu.com/DashAsBinSh#A.5B Ubuntu's /bin/sh is /bin/dash and '==' triggers an error: >> /bin/sh: 1: [: amd64: unexpected operator
This commit is contained in:
parent
5b24e1793d
commit
26c5a26565
4
Makefile
4
Makefile
|
|
@ -112,7 +112,7 @@ container: .container-$(DOTFILE_IMAGE) container-name
|
|||
Dockerfile.in > .dockerfile-$(ARCH)
|
||||
@docker build -t $(IMAGE):$(VERSION) -f .dockerfile-$(ARCH) .
|
||||
@docker images -q $(IMAGE):$(VERSION) > $@
|
||||
@if [ "$(ARCH)" == "amd64" ]; then \
|
||||
@if [ "$(ARCH)" = "amd64" ]; then \
|
||||
docker tag $(IMAGE):$(VERSION) $(LEGACY_IMAGE):$(VERSION); \
|
||||
fi
|
||||
|
||||
|
|
@ -123,7 +123,7 @@ push: .push-$(DOTFILE_IMAGE) push-name
|
|||
.push-$(DOTFILE_IMAGE): .container-$(DOTFILE_IMAGE)
|
||||
@gcloud docker push $(IMAGE):$(VERSION)
|
||||
@docker images -q $(IMAGE):$(VERSION) > $@
|
||||
@if [ "$(ARCH)" == "amd64" ]; then \
|
||||
@if [ "$(ARCH)" = "amd64" ]; then \
|
||||
gcloud docker push $(LEGACY_IMAGE):$(VERSION); \
|
||||
fi
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue