Skip to content

Commit 9f7cc8f

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "[2024.1 only] Add conditionals for Ubuntu Jammy" into stable/2024.1
2 parents eef5645 + fa6431e commit 9f7cc8f

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

docker/base/Dockerfile.j2

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -240,19 +240,23 @@ RUN cat /tmp/kolla_bashrc >> /etc/bash.bashrc \
240240
{% if base_distro == 'debian' %}
241241
RUN rm -f /etc/apt/sources.list.d/debian.sources
242242
COPY sources.list.{{ base_distro }} /etc/apt/sources.list
243-
{% elif ( base_distro == 'ubuntu' and base_arch == 'x86_64' ) %}
243+
{% elif base_distro == 'ubuntu' %}
244244
{% if base_distro_tag.startswith('22.04') or base_distro_tag.startswith('jammy') %}
245+
RUN rm -f /etc/apt/sources.list
246+
{% if base_arch == 'x86_64' %}
245247
COPY sources.list.{{ base_distro }}.jammy /etc/apt/sources.list
248+
{% else %}
249+
COPY sources.list.{{ base_distro }}.jammy.{{ base_arch }} /etc/apt/sources.list
250+
{% endif %}
246251
{% elif base_distro_tag.startswith('24.04') or base_distro_tag.startswith('noble') %}
252+
RUN rm -f /etc/apt/sources.list.d/{{ base_distro }}.sources
253+
{% if base_arch == 'x86_64' %}
247254
COPY sources.list.{{ base_distro }}.noble /etc/apt/sources.list
248-
{% endif %}
249255
{% else %}
250-
{% if base_distro_tag.startswith('22.04') or base_distro_tag.startswith('jammy')%}
251-
COPY sources.list.{{ base_distro }}.jammy.{{ base_arch }} /etc/apt/sources.list
252-
{% elif base_distro_tag.startswith('24.04') or base_distro_tag.startswith('noble')%}
253256
COPY sources.list.{{ base_distro }}.noble.{{ base_arch }} /etc/apt/sources.list
254257
{% endif %}
255258
{% endif %}
259+
{% endif %}
256260
COPY sources.list /etc/apt/sources.list.d/kolla-custom.list
257261
{% endblock %}
258262

0 commit comments

Comments
 (0)