Skip to content

Commit

Permalink
tox/tests: use base image from quay.io
Browse files Browse the repository at this point in the history
Avoid as much as possible to use the docker.io registry so even the centos
base container image should be pulled from the quay.io registry.

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
(cherry picked from commit 5fa7592)
  • Loading branch information
dsavineau committed Aug 26, 2021
1 parent 6151fda commit 52f5dc2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/tox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ else
sudo chgrp "$(whoami)" /var/run/docker.sock
fi

if [ -n "${DOCKER_HUB_USERNAME}" ] && [ -n "${DOCKER_HUB_PASSWORD}" ]; then
docker login -u "${DOCKER_HUB_USERNAME}" -p "${DOCKER_HUB_PASSWORD}"
if [ -n "${REGISTRY_USERNAME}" ] && [ -n "${REGISTRY_PASSWORD}" ]; then
docker login -u "${REGISTRY_USERNAME}" -p "${REGISTRY_PASSWORD}" "${REGISTRY}"
fi

rm -rf "$WORKSPACE"/ceph-ansible || true
Expand Down Expand Up @@ -87,7 +87,7 @@ make_output=$(make FLAVORS="$FLAVOR" stage) # Run staging to get DAEMON_IMAGE na
daemon_image=$(echo "${make_output}" | grep " DAEMON_IMAGE ") # Find DAEMON_IMAGE line
daemon_image="${daemon_image#*DAEMON_IMAGE*: }" # Remove DAEMON_IMAGE from beginning
daemon_image="$(echo "${daemon_image}" | tr -s ' ')" # Remove whitespace
make FLAVORS="$FLAVOR" build.parallel
make FLAVORS="$FLAVOR" BASEOS_REGISTRY="${REGISTRY}/centos" BASEOS_REPO="centos" build.parallel

# start a local docker registry
docker run -d -p 5000:5000 --restart=always --name registry registry:2
Expand Down
1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ setenv=
CEPH_ANSIBLE_BRANCH = stable-6.0
VAGRANT_PROVIDER = {env:VAGRANT_PROVIDER:libvirt}
CEPH_ANSIBLE_VAGRANT_BOX = centos/8
REGISTRY = quay.io
deps=
ceph_ansible: ansible>=2.9,<2.10
commands=
Expand Down

0 comments on commit 52f5dc2

Please sign in to comment.