diff options
| author | Michal Nasiadka <mnasiadka@gmail.com> | 2022-09-27 10:18:01 +0000 |
|---|---|---|
| committer | Michal Nasiadka <mnasiadka@gmail.com> | 2022-09-30 14:17:34 +0000 |
| commit | 0883532434fff341c444d8fce8e28fcff3f5e769 (patch) | |
| tree | 7f1f75d1db104fb73451f086f7d0fd8b49c5bab1 /tests/templates | |
| parent | 237013960425e4ff6cbc4814d4f9d61efcf601de (diff) | |
| download | kolla-0883532434fff341c444d8fce8e28fcff3f5e769.tar.gz kolla-0883532434fff341c444d8fce8e28fcff3f5e769.zip | |
Add RockyLinux 9 support
Depends-On: https://review.opendev.org/c/openstack/kolla-ansible/+/859570
Change-Id: I7af51d07b8a939c908aa072294061def57dd67de
Diffstat (limited to 'tests/templates')
| -rw-r--r-- | tests/templates/template_overrides.j2 | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/tests/templates/template_overrides.j2 b/tests/templates/template_overrides.j2 index 932917c3c..96bf682b0 100644 --- a/tests/templates/template_overrides.j2 +++ b/tests/templates/template_overrides.j2 @@ -16,7 +16,11 @@ RUN echo registry={{ nodepool_npmjs_proxy }} > /etc/npmrc \ {% raw %} {% endblock %} +{% endraw %} + +{% if base_distro == 'centos' %} +{% raw %} {% block base_centos_repo_overrides_post_copy %} {% endraw %} @@ -51,29 +55,30 @@ RUN sed -i \ -e "s|^\(metalink.*\)|#\1|" \ -e "s|^#baseurl=http://download.example/pub|baseurl=http://{{ nodepool_mirror_host }}|" \ -e "s|^#baseurl=https://download.example/pub|baseurl=http://{{ nodepool_mirror_host }}|" \ - /etc/yum.repos.d/epel*.repo + /etc/yum.repos.d/epel*.repo \ {%- raw -%} {% endblock %} +{% endraw %} +{% endif %} +{% raw %} {% block base_debian_after_sources_list %} -{% if base_distro == "debian" %} {% endraw %} +{% if base_distro == "debian" %} RUN sed -i -e "s|http://deb.debian.org|[trusted=yes] http://{{ nodepool_mirror_host }}|" \ -e "s|http://security.debian.org|[trusted=yes] http://{{ nodepool_mirror_host }}|" \ /etc/apt/sources.list -{% raw %} {% elif base_distro == "ubuntu" %} -{% endraw %} RUN sed -i -e "s|mirror://mirrors.ubuntu.com/mirrors.txt|[trusted=yes] http://{{ nodepool_mirror_host }}/ubuntu/|" \ -e "s|http://ubuntu-cloud.archive.canonical.com/ubuntu|[trusted=yes] http://{{ nodepool_mirror_host }}/ubuntu-cloud-archive|" \ -e "s|http://ports.ubuntu.com|[trusted=yes] http://{{ nodepool_mirror_host }}/ubuntu-ports|" \ /etc/apt/sources.list -{% raw %} {% endif %} +{% raw %} {% endblock %} {# Revert to upstream mirrors after build is complete #} @@ -92,13 +97,11 @@ RUN if [ -f /usr/etc/npmrc ]; then \ fi \ && rm -f /etc/npmrc -{% raw %} -{% if base_package_type == 'rpm' %} -{% endraw %} +{% if base_distro == 'centos' %} RUN sed -i \ -e "s|^#\(mirrorlist.*\)|\1|" \ -e "s|^baseurl=http://{{ nodepool_mirror_host }}|#baseurl=http://mirror.centos.org|" \ - /etc/yum.repos.d/CentOS-*.repo \ + /etc/yum.repos.d/centos*.repo \ && sed -i \ -e "s|{{ nodepool_rdo_proxy }}|https://trunk.rdoproject.org|g" \ /etc/yum.repos.d/delorean*.repo \ @@ -106,22 +109,16 @@ RUN sed -i \ -e "s|^#\(metalink.*\)|\1|" \ -e "s|^baseurl=http://{{ nodepool_mirror_host }}|#baseurl=http://download.example/pub|" \ /etc/yum.repos.d/epel*.repo -{% raw %} -{% elif base_package_type == 'deb' %} -{% if base_distro == "debian" %} -{% endraw %} +{% elif base_distro == "debian" %} RUN sed -i -e "s|\[trusted=yes\] http://{{ nodepool_mirror_host }}|http://deb.debian.org|" \ -e "s|\[trusted=yes\] http://{{ nodepool_mirror_host }}|http://security.debian.org|" \ /etc/apt/sources.list -{% raw %} {% elif base_distro == "ubuntu" %} -{% endraw %} RUN sed -i -e "s|\[trusted=yes\] http://{{ nodepool_mirror_host }}/ubuntu/|mirror://mirrors.ubuntu.com/mirrors.txt|" \ -e "s|\[trusted=yes\] http://{{ nodepool_mirror_host }}/ubuntu-cloud-archive|http://ubuntu-cloud.archive.canonical.com/ubuntu|" \ -e "s|\[trusted=yes\] http://{{ nodepool_mirror_host }}/ubuntu-ports|http://ports.ubuntu.com|" \ /etc/apt/sources.list -{% raw %} -{% endif %} {% endif %} +{% raw %} {% endblock %} {% endraw %} |
