Use registry at quay.io instead of docker.io.

Lately, Docker.io started to limit their resources[1], so it started to
be annoying in a cases of usual development, to typical test by CI
systems. Although our image is tiny, but still, we can observe that
limits were hit. Let's move on to the quay.io.

[1] https://www.docker.com/increase-rate-limit

Change-Id: I32af39344cb3e590a13bd07b64227d8acab6ccd0
This commit is contained in:
Roman Dobosz 2020-11-18 13:01:28 +01:00
parent 28fbe115eb
commit 0746946003
6 changed files with 20 additions and 15 deletions

View File

@ -6,9 +6,9 @@ function build_test_container {
# resolved instead of podman we need to use buildah directly, # resolved instead of podman we need to use buildah directly,
# hence this awful if clause. # hence this awful if clause.
if [[ ${CONTAINER_ENGINE} == 'crio' ]]; then if [[ ${CONTAINER_ENGINE} == 'crio' ]]; then
sudo buildah bud -t docker.io/kuryr/demo -f Dockerfile . sudo buildah bud -t quay.io/kuryr/demo -f Dockerfile .
else else
docker build -t kuryr/demo . -f Dockerfile docker build -t quay.io/kuryr/demo . -f Dockerfile
fi fi
popd popd
} }

View File

@ -166,7 +166,7 @@ class BaseKuryrScenarioTest(manager.NetworkScenarioTest):
name=np_name, namespace=np_namespace) name=np_name, namespace=np_namespace)
@classmethod @classmethod
def create_pod(cls, name=None, labels=None, image='kuryr/demo', def create_pod(cls, name=None, labels=None, image='quay.io/kuryr/demo',
namespace="default", annotations=None, wait_for_status=True, namespace="default", annotations=None, wait_for_status=True,
affinity=None): affinity=None):
if not name: if not name:

View File

@ -87,8 +87,8 @@ RUN set -ex \
busybox \ busybox \
&& ./busybox --help \ && ./busybox --help \
&& mkdir -p rootfs/bin \ && mkdir -p rootfs/bin \
&& ln -vL busybox rootfs/bin/ \ && cp busybox rootfs/bin/ \
&& chroot rootfs /bin/busybox --install /bin && chroot rootfs /bin/busybox --install -s /bin
# grab a simplified getconf port from Alpine we can statically compile # grab a simplified getconf port from Alpine we can statically compile
RUN set -x \ RUN set -x \

View File

@ -2,16 +2,16 @@
Kuryr Testing container infrastructure Kuryr Testing container infrastructure
====================================== ======================================
This directory is the official source for building Docker hub's kuryr/demo This directory is the official source for building Quay.io kuryr/demo images.
images.
The build consists on two parts: The build consists on two parts:
Builder container Builder container
----------------- -----------------
The builder container is based on the musl compiled Alpine distribution. In the The builder container is based on the `musl`_ compiled Alpine distribution. In
process of building the image, it downloads and compiles: the process of building the image, it downloads and compiles:
* busybox * busybox
* musl * musl
@ -21,14 +21,14 @@ It also includes golang so that we can use it in our test web server:
* server.go * server.go
Everything that is to be included in the kuryr/demo image is put in:: Everything that is to be included in the kuryr/demo image is put in
``/usr/src/busybox/rootfs``.
/usr/src/busybox/rootfs
The reason for this is that this build is based on Docker's busybox build The reason for this is that this build is based on Docker's busybox build
system and the rootfs won't have any library, so all you want to add must be system and the rootfs won't have any library, so all you want to add must be
statically compiled there. statically compiled there.
kuryr/demo container kuryr/demo container
-------------------- --------------------
@ -42,6 +42,7 @@ This is the actual container used in the tests. It includes:
that includes the hostname, so it can be used to see which pod replies to a that includes the hostname, so it can be used to see which pod replies to a
service request. service request.
When and how to build When and how to build
--------------------- ---------------------
@ -53,14 +54,18 @@ app version of something in kuryr/demo or add another tool like bind9 dig.
The way to do this is:: The way to do this is::
sudo ./mkrootfs.sh .. code-block:: console
$ sudo ./mkrootfs.sh
kuryr/demo kuryr/demo
~~~~~~~~~~ ~~~~~~~~~~
Everytime you want to run the tests, you should build the kuryr/demo container Everytime you want to run the tests, you should build the kuryr/demo container
locally to avoid pulls from dockerhub to make sure you run the latest locally to avoid pulls from quay.io to make sure you run the latest
authoritative version. authoritative version.
Note that the kuryr-tempest-plugin devstack will build it for you. Note that the kuryr-tempest-plugin devstack will build it for you.
.. _musl: https://musl.libc.org

View File

@ -12,4 +12,4 @@ docker rm ${BUILDER_NAME}
chmod +s rootfs/bin/busybox chmod +s rootfs/bin/busybox
tar -J -f rootfs.tar.xz --numeric-owner --exclude='dev/*' -C rootfs -c . tar -J -f rootfs.tar.xz --numeric-owner --exclude='dev/*' -C rootfs -c .
rm -fr rootfs rm -fr rootfs
docker build -t kuryr/demo . -f Dockerfile docker build -t quay.io/kuryr/demo . -f Dockerfile

Binary file not shown.