summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMichal Nasiadka <mnasiadka@gmail.com>2022-02-14 15:21:40 +0100
committerMark Goddard <mark@stackhpc.com>2022-03-04 09:55:43 +0000
commit76841d99ec35dccf7231ef67938aaf3629957a6e (patch)
tree64e5d86ef446ee7308b06c621c2d31132da98eb0 /tests
parentd4e7ff9d2877bbd795c7b42bd3a6ca44ce88d1c3 (diff)
downloadkolla-76841d99ec35dccf7231ef67938aaf3629957a6e.tar.gz
kolla-76841d99ec35dccf7231ef67938aaf3629957a6e.zip
Build CentOS Stream 8 images
This is part of the effort to allow a migration path for operators using CentOS 7 and Train today. Depends-On: https://review.opendev.org/c/openstack/kolla-ansible/+/831265 Change-Id: I75373eb21c4269c20f72603ad4cf162a472de25b (cherry picked from commit 67d6d28b6208cc004a50f19be1386d88c2404bc4)
Diffstat (limited to 'tests')
-rw-r--r--tests/templates/kolla-build.conf.j25
-rw-r--r--tests/test_build.py14
2 files changed, 12 insertions, 7 deletions
diff --git a/tests/templates/kolla-build.conf.j2 b/tests/templates/kolla-build.conf.j2
index e66006ef4..bdc6060ab 100644
--- a/tests/templates/kolla-build.conf.j2
+++ b/tests/templates/kolla-build.conf.j2
@@ -1,5 +1,8 @@
[DEFAULT]
debug = true
+{% if ansible_distribution | lower == 'centos' and base_tag | default == 'stream8' %}
+base_image = quay.io/centos/centos
+{% endif %}
{% if publisher %}
namespace = kolla
{# NOTE(hrw): we do not publish centos images for aarch64 so can just override #}
@@ -7,7 +10,7 @@ namespace = kolla
{% set tag_suffix = '-aarch64' %}
{% else %}
{# TODO(mgoddard): Remove tag_suffix when CentOS 7 is no longer supported. #}
-{% set tag_suffix = '-centos8' if ansible_distribution | lower == 'centos' and base_tag | default == 8 else '' %}
+{% set tag_suffix = '-centos8s' if ansible_distribution | lower == 'centos' and base_tag | default == 'stream8' else '' %}
{% endif %}
tag = {{ (zuul.tag if zuul.pipeline == "release" else zuul.branch | basename) ~ tag_suffix }}
{% endif %}
diff --git a/tests/test_build.py b/tests/test_build.py
index 38116d134..fad696b44 100644
--- a/tests/test_build.py
+++ b/tests/test_build.py
@@ -79,25 +79,27 @@ class BuildTestCentosSource(BuildTest, base.BaseTestCase):
"--type", "source"])
-class BuildTestCentos8Binary(BuildTest, base.BaseTestCase):
+class BuildTestCentosStream8Binary(BuildTest, base.BaseTestCase):
def setUp(self):
- super(BuildTestCentos8Binary, self).setUp()
+ super(BuildTestCentosStream8Binary, self).setUp()
# TODO(mgoddard): Remove --base-tag argument when CentOS 8 is the
# default.
self.build_args.extend(["--base", "centos",
- "--base-tag", "8",
+ "--base-tag", "stream8",
+ "--base-image", "quay.io/centos/centos",
"--type", "binary"])
-class BuildTestCentos8Source(BuildTest, base.BaseTestCase):
+class BuildTestCentosStream8Source(BuildTest, base.BaseTestCase):
def setUp(self):
- super(BuildTestCentos8Source, self).setUp()
+ super(BuildTestCentosStream8Source, self).setUp()
# TODO(mgoddard): Remove --base-tag argument when CentOS 8 is the
# default.
self.build_args.extend(["--base", "centos",
- "--base-tag", "8",
+ "--base-tag", "stream8",
+ "--base-image", "quay.io/centos/centos",
"--type", "source"])