Pull docker images from global registry

The global docker registry is where images are
being built and uploaded. It's effectively docker's
version of, say, 'pip'. The static tarballs are
not only an extra maintenance burden as they're outside
the standard build and publishing process, but are presently
outside the scope of an open development / release
process as well.

While this process does cause some trouble with
network-independence for CI purposes, the fetching
is still done from install-docker.sh; Additionally,
this driver is not currently tested via the community CI effort.

Change-Id: I3ee6bfee9c273cd3aabe1e00a1d1a8856a466189
This commit is contained in:
Eric Windisch 2014-01-31 01:25:28 -05:00
parent 465653e25f
commit 2dac885e6c
2 changed files with 10 additions and 21 deletions

View File

@ -31,10 +31,10 @@ DOCKER_UNIX_SOCKET=/var/run/docker.sock
DOCKER_PID_FILE=/var/run/docker.pid
DOCKER_REGISTRY_PORT=${DOCKER_REGISTRY_PORT:-5042}
DOCKER_IMAGE=${DOCKER_IMAGE:-http://get.docker.io/images/openstack/docker-ut.tar.gz}
DOCKER_IMAGE_NAME=docker-busybox
DOCKER_REGISTRY_IMAGE=${DOCKER_REGISTRY_IMAGE:-http://get.docker.io/images/openstack/docker-registry.tar.gz}
DOCKER_REGISTRY_IMAGE_NAME=docker-registry
DOCKER_IMAGE=${DOCKER_IMAGE:-busybox:latest}
DOCKER_IMAGE_NAME=busybox
DOCKER_REGISTRY_IMAGE=${DOCKER_REGISTRY_IMAGE:-registry:latest}
DOCKER_REGISTRY_IMAGE_NAME=registry
DOCKER_REPOSITORY_NAME=${SERVICE_HOST}:${DOCKER_REGISTRY_PORT}/${DOCKER_IMAGE_NAME}
DOCKER_APT_REPO=${DOCKER_APT_REPO:-https://get.docker.io/ubuntu}

View File

@ -55,21 +55,10 @@ if ! timeout $SERVICE_TIMEOUT sh -c "$CONFIGURE_CMD"; then
die $LINENO "docker did not start"
fi
# Get guest container image
docker pull $DOCKER_IMAGE
docker tag $DOCKER_IMAGE $DOCKER_IMAGE_NAME
# Get Docker image
if [[ ! -r $FILES/docker-ut.tar.gz ]]; then
(cd $FILES; curl -OR $DOCKER_IMAGE)
fi
if [[ ! -r $FILES/docker-ut.tar.gz ]]; then
die $LINENO "Docker image unavailable"
fi
docker import - $DOCKER_IMAGE_NAME <$FILES/docker-ut.tar.gz
# Get Docker registry image
if [[ ! -r $FILES/docker-registry.tar.gz ]]; then
(cd $FILES; curl -OR $DOCKER_REGISTRY_IMAGE)
fi
if [[ ! -r $FILES/docker-registry.tar.gz ]]; then
die $LINENO "Docker registry image unavailable"
fi
docker import - $DOCKER_REGISTRY_IMAGE_NAME <$FILES/docker-registry.tar.gz
# Get docker-registry image
docker pull $REGISTRY_IMAGE
docker tag $REGISTRY_IMAGE $REGISTRY_IMAGE_NAME