From 32207fc8e88275b1da100a345e212327285282d7 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Evrard Date: Tue, 3 Jan 2017 13:59:29 +0000 Subject: [PATCH] Allow override of the repo filename Apt cannot have 2 mirrors with the same content in 2 different files. If a deployer has an apt mirror with uca, the deployer still need to add a repository, but will also need to define the filename used, in order to avoid clashes. This commit makes possible to decide the filename for the repo. Change-Id: I05c57fe1e43c15757797ff4ad6a2acf39441cb50 Signed-off-by: Jean-Philippe Evrard --- defaults/main.yml | 1 + .../notes/apt-source-filenamed-2cc698add82f5eea.yaml | 5 +++++ tasks/neutron_install.yml | 1 + 3 files changed, 7 insertions(+) create mode 100644 releasenotes/notes/apt-source-filenamed-2cc698add82f5eea.yaml diff --git a/defaults/main.yml b/defaults/main.yml index f74d12db..6ec19fe2 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -480,6 +480,7 @@ neutron_local_ip: 127.0.0.1 neutron_uca_enable: True # Ubuntu Cloud Archive mirror URL uca_apt_repo_url: "http://ubuntu-cloud.archive.canonical.com/ubuntu" +uca_apt_source_list_filename: "ubuntu_cloud_archive_canonical_com_ubuntu" # When running in an AIO, we need to implement an iptables rule in any # neutron_agent containers to that ensure instances can communicate with diff --git a/releasenotes/notes/apt-source-filenamed-2cc698add82f5eea.yaml b/releasenotes/notes/apt-source-filenamed-2cc698add82f5eea.yaml new file mode 100644 index 00000000..ea744d9c --- /dev/null +++ b/releasenotes/notes/apt-source-filenamed-2cc698add82f5eea.yaml @@ -0,0 +1,5 @@ +--- +features: + - The filename of the apt source for the ubuntu + cloud archive can now be defined with the + variable ``uca_apt_source_list_filename``. \ No newline at end of file diff --git a/tasks/neutron_install.yml b/tasks/neutron_install.yml index 832bccd3..f5991213 100644 --- a/tasks/neutron_install.yml +++ b/tasks/neutron_install.yml @@ -36,6 +36,7 @@ repo: "{{ uca_repo }}" state: present update_cache: yes + filename: "{{ uca_apt_source_list_filename }}" register: neutron_uca_add_repo when: - neutron_uca_enable