openstack-ansible/tests/roles/bootstrap-host/templates/apt-sources.list.j2
Jesse Pretorius ae6a0055d4 AIO: Provide facility to exclude apt distributions
When using a mirror which compiles all apt sources into
a single repo with the intent of relying on that repo for
all package updates the /etc/apt/sources.list file must
contain only the base ubuntu repo.

This patch adds the ability to implement an AIO with
this kind of apt sources configuration, while keeping
the current configuration that's used for gating.

Change-Id: Ia9785a43c9027df86f3bc94f825aba3c43a96e4c
2017-03-07 14:42:29 +00:00

17 lines
724 B
Django/Jinja

# {{ ansible_managed }}
# Base repository
deb {{ bootstrap_host_ubuntu_repo }} {{ ansible_distribution_release }} {{ bootstrap_host_apt_components | join(" ") }}
{% if bootstrap_host_apt_distribution_suffix_list | length > 0 %}
# Additional distribution repositories
{% for suffix in bootstrap_host_apt_distribution_suffix_list %}
deb {{ bootstrap_host_ubuntu_repo }} {{ ansible_distribution_release }}-{{ suffix }} {{ bootstrap_host_apt_components | join(" ") }}
{% endfor %}
{% endif %}
{% if bootstrap_host_ubuntu_security_repo is defined %}
# Security repository
deb {{ bootstrap_host_ubuntu_security_repo }} {{ ansible_distribution_release }}-security {{ bootstrap_host_apt_components | join(" ") }}
{% endif %}