mirror of https://github.com/hashicorp/consul
Backport of Reference hashicorp/consul instead of consul for Docker image into release/1.16.x (#17920)
* backport of commitpull/17926/headd490377d50
* backport of commitee7f7b794f
--------- Co-authored-by: Nathan Coleman <nathan.coleman@hashicorp.com>
parent
0e8b18625c
commit
e49b029a04
|
@ -169,7 +169,7 @@ dev-build:
|
||||||
|
|
||||||
dev-docker-dbg: dev-docker
|
dev-docker-dbg: dev-docker
|
||||||
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
||||||
@docker pull consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
@docker pull hashicorp/consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
||||||
@echo "Building Consul Development container - $(CONSUL_DEV_IMAGE)"
|
@echo "Building Consul Development container - $(CONSUL_DEV_IMAGE)"
|
||||||
@# 'consul-dbg:local' tag is needed to run the integration tests
|
@# 'consul-dbg:local' tag is needed to run the integration tests
|
||||||
@# 'consul-dev:latest' is needed by older workflows
|
@# 'consul-dev:latest' is needed by older workflows
|
||||||
|
@ -181,7 +181,7 @@ dev-docker-dbg: dev-docker
|
||||||
|
|
||||||
dev-docker: linux dev-build
|
dev-docker: linux dev-build
|
||||||
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
||||||
@docker pull consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
@docker pull hashicorp/consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
||||||
@echo "Building Consul Development container - $(CONSUL_DEV_IMAGE)"
|
@echo "Building Consul Development container - $(CONSUL_DEV_IMAGE)"
|
||||||
@# 'consul:local' tag is needed to run the integration tests
|
@# 'consul:local' tag is needed to run the integration tests
|
||||||
@# 'consul-dev:latest' is needed by older workflows
|
@# 'consul-dev:latest' is needed by older workflows
|
||||||
|
@ -200,7 +200,7 @@ remote-docker: check-remote-dev-image-env
|
||||||
$(MAKE) GOARCH=amd64 linux
|
$(MAKE) GOARCH=amd64 linux
|
||||||
$(MAKE) GOARCH=arm64 linux
|
$(MAKE) GOARCH=arm64 linux
|
||||||
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
||||||
@docker pull consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
@docker pull hashicorp/consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
||||||
@echo "Building and Pushing Consul Development container - $(REMOTE_DEV_IMAGE)"
|
@echo "Building and Pushing Consul Development container - $(REMOTE_DEV_IMAGE)"
|
||||||
@if ! docker buildx inspect consul-builder; then \
|
@if ! docker buildx inspect consul-builder; then \
|
||||||
docker buildx create --name consul-builder --driver docker-container --bootstrap; \
|
docker buildx create --name consul-builder --driver docker-container --bootstrap; \
|
||||||
|
@ -215,7 +215,7 @@ remote-docker: check-remote-dev-image-env
|
||||||
# should only run in CI and not locally.
|
# should only run in CI and not locally.
|
||||||
ci.dev-docker:
|
ci.dev-docker:
|
||||||
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
@echo "Pulling consul container image - $(CONSUL_IMAGE_VERSION)"
|
||||||
@docker pull consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
@docker pull hashicorp/consul:$(CONSUL_IMAGE_VERSION) >/dev/null
|
||||||
@echo "Building Consul Development container - $(CI_DEV_DOCKER_IMAGE_NAME)"
|
@echo "Building Consul Development container - $(CI_DEV_DOCKER_IMAGE_NAME)"
|
||||||
@docker build $(NOCACHE) $(QUIET) -t '$(CI_DEV_DOCKER_NAMESPACE)/$(CI_DEV_DOCKER_IMAGE_NAME):$(GIT_COMMIT)' \
|
@docker build $(NOCACHE) $(QUIET) -t '$(CI_DEV_DOCKER_NAMESPACE)/$(CI_DEV_DOCKER_IMAGE_NAME):$(GIT_COMMIT)' \
|
||||||
--build-arg CONSUL_IMAGE_VERSION=$(CONSUL_IMAGE_VERSION) \
|
--build-arg CONSUL_IMAGE_VERSION=$(CONSUL_IMAGE_VERSION) \
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# SPDX-License-Identifier: MPL-2.0
|
# SPDX-License-Identifier: MPL-2.0
|
||||||
|
|
||||||
ARG CONSUL_IMAGE_VERSION=latest
|
ARG CONSUL_IMAGE_VERSION=latest
|
||||||
FROM consul:${CONSUL_IMAGE_VERSION}
|
FROM hashicorp/consul:${CONSUL_IMAGE_VERSION}
|
||||||
RUN apk update && apk add iptables
|
RUN apk update && apk add iptables
|
||||||
ARG TARGETARCH
|
ARG TARGETARCH
|
||||||
COPY linux_${TARGETARCH}/consul /bin/consul
|
COPY linux_${TARGETARCH}/consul /bin/consul
|
||||||
|
|
|
@ -2,6 +2,6 @@
|
||||||
# SPDX-License-Identifier: MPL-2.0
|
# SPDX-License-Identifier: MPL-2.0
|
||||||
|
|
||||||
ARG CONSUL_IMAGE_VERSION=latest
|
ARG CONSUL_IMAGE_VERSION=latest
|
||||||
FROM consul:${CONSUL_IMAGE_VERSION}
|
FROM hashicorp/consul:${CONSUL_IMAGE_VERSION}
|
||||||
RUN apk update && apk add iptables
|
RUN apk update && apk add iptables
|
||||||
COPY consul /bin/consul
|
COPY consul /bin/consul
|
||||||
|
|
|
@ -308,7 +308,7 @@ metadata:
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- name: example
|
- name: example
|
||||||
image: 'consul:latest'
|
image: 'hashicorp/consul:latest'
|
||||||
env:
|
env:
|
||||||
- name: HOST_IP
|
- name: HOST_IP
|
||||||
valueFrom:
|
valueFrom:
|
||||||
|
@ -345,7 +345,7 @@ spec:
|
||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- name: example
|
- name: example
|
||||||
image: 'consul:latest'
|
image: 'hashicorp/consul:latest'
|
||||||
env:
|
env:
|
||||||
- name: HOST_IP
|
- name: HOST_IP
|
||||||
valueFrom:
|
valueFrom:
|
||||||
|
|
Loading…
Reference in New Issue