Merge "MNAIO: Add access to libvirt v4 via UCA Queens"
This commit is contained in:
commit
e717351c75
@ -28,13 +28,55 @@
|
||||
tags:
|
||||
- always
|
||||
|
||||
- name: Install host distro packages
|
||||
- name: Install pre-requisite host distro packages
|
||||
package:
|
||||
pkg: "{{ item }}"
|
||||
name: "{{ mnaio_host_required_distro_packages }}"
|
||||
state: "latest"
|
||||
update_cache: yes
|
||||
cache_valid_time: 600
|
||||
with_items: "{{ mnaio_host_distro_packages }}"
|
||||
register: _install_required_host_packages
|
||||
until: _install_required_host_packages | success
|
||||
retries: 3
|
||||
delay: 15
|
||||
when:
|
||||
- "mnaio_host_required_distro_packages | length > 0"
|
||||
|
||||
- name: Add/Remove/Update apt repositories
|
||||
apt_repository:
|
||||
repo: "{{ repo.repo }}"
|
||||
state: "{{ repo.state | default('present') }}"
|
||||
filename: "{{ repo.filename | default(omit) }}"
|
||||
update_cache: no
|
||||
with_items: "{{ mnaio_host_package_repos }}"
|
||||
loop_control:
|
||||
loop_var: repo
|
||||
register: _add_apt_repo
|
||||
when:
|
||||
- "ansible_os_family == 'Debian'"
|
||||
- "mnaio_host_package_repos | length > 0"
|
||||
- "(repo.condition | default(True)) | bool"
|
||||
|
||||
- name: Update apt cache
|
||||
apt:
|
||||
update_cache: yes
|
||||
register: _update_apt_cache
|
||||
until: _update_apt_cache | success
|
||||
retries: 3
|
||||
delay: 15
|
||||
when:
|
||||
- "ansible_os_family == 'Debian'"
|
||||
- "_add_apt_repo | changed"
|
||||
|
||||
- name: Install host distro packages
|
||||
package:
|
||||
name: "{{ mnaio_host_distro_packages }}"
|
||||
state: "latest"
|
||||
update_cache: yes
|
||||
cache_valid_time: 600
|
||||
register: _install_host_packages
|
||||
until: _install_host_packages | success
|
||||
retries: 3
|
||||
delay: 15
|
||||
|
||||
tasks:
|
||||
- name: Ensure root has a .ssh directory
|
||||
|
@ -13,6 +13,15 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
mnaio_host_required_distro_packages:
|
||||
- ubuntu-cloud-keyring
|
||||
|
||||
mnaio_host_package_repos:
|
||||
- repo: "deb http://ubuntu-cloud.archive.canonical.com/ubuntu {{ ansible_lsb.codename }}-updates/queens main"
|
||||
state: present
|
||||
filename: "uca"
|
||||
condition: "{{ ansible_lsb.codename == 'xenial' }}"
|
||||
|
||||
mnaio_host_distro_packages:
|
||||
- bridge-utils
|
||||
- ifenslave
|
||||
|
Loading…
x
Reference in New Issue
Block a user