A little sanity for our infrastructure
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

37 lines
1.6 KiB

DOCKER_CLI := docker
TARGET := de04-sseng-docker-unstable.docker.nexus.zurich.com/de/zurich/sanity
DOCKER_REGISTRY := de04-sseng-unstable-master.docker.nexus.zurich.com
TAG := aaalpha
VERSION := 0.0.1-aaa
dockerbuild: Dockerfile
$(DOCKER_CLI) build . -t $(TARGET):$(VERSION)
bambooagentbuild: Dockerfile
$(DOCKER_CLI) build . -t $(TARGET):$(VERSION) --build-arg HTTP_PROXY="http://ceala05956.emea.zurich.corp:8080/" \
--build-arg HTTPS_PROXY="http://ceala05956.emea.zurich.corp:8080/" \
--build-arg http_proxy="http://ceala05956.emea.zurich.corp:8080/" \
--build-arg https_proxy="http://ceala05956.emea.zurich.corp:8080/" \
publish: bambooagentbuild
echo "[INFO ] login $(DOCKER_REGISTRY)"; \
$(DOCKER_CLI) login -u "$$NEXUS_USER" -p "$$NEXUS_PASSWORD" $(DOCKER_REGISTRY) ||exit 1; \
docker image ls
$(DOCKER_CLI) push $(TARGET):$(VERSION) ||exit 1; \
$(DOCKER_CLI) logout $(DOCKER_REGISTRY) ||exit 1 \
echo "=> Build Successfull !To download image please run: 'docker pull $(TARGET):$(VERSION)'"
publish-with-tag: bambooagentbuild
echo "[INFO ] login $(DOCKER_REGISTRY)"; \
$(DOCKER_CLI) login -u "$$NEXUS_USER" -p "$$NEXUS_PASSWORD" $(DOCKER_REGISTRY) ||exit 1; \
$(DOCKER_CLI) tag $(TARGET):$(VERSION) $(TARGET):$(TAG) ||exit 1; \
docker image ls
$(DOCKER_CLI) push $(TARGET):$(VERSION) ||exit 1; \
$(DOCKER_CLI) push $(TARGET):$(TAG) ||exit 1; \
$(DOCKER_CLI) logout $(DOCKER_REGISTRY) ||exit 1 \
echo "=> Build Successfull !To download image please run: 'docker pull $(TARGET):$(TAG)'"