prepare_libvirt.yml 1.68 KB
Newer Older
's avatar
committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
- hosts: hypervisors:&centos_hosts
  tasks:

  - name: ACTION | Upgrade dist ad install common packages on hypervisors hosts
    import_role:
      name: yum
    vars:
      update_before_install: true
      upgrade_dist: true
      GPG_keys: []
      yum_repositories: []
      remove_packages: []
      upgrade_packages: []
      packages:
        - vim
        - dos2unix
        - curl
        - wget
    tags:
      - common
      - package

  - name: ACTION | Install libvirt dependencies on hypervisors hosts
    import_role:
      name: yum
      tasks_from: install_packages.yml
    vars:
      update_before_install: true
      packages: "{{ virt_dependencies }}"
    tags:
      - virtualization
      - package

- hosts: hypervisors:&debian_hosts
  tasks:

  - name: ACTION | Upgrase dist and install common packages on hypervisors hosts
    import_role:
      name: apt
    vars:
      update_before_install: true
      upgrade_dist: true
      GPG_keys: []
      yum_repositories: []
      remove_packages: []
      upgrade_packages: []
      packages:
        - vim
        - dos2unix
        - curl
        - wget
    tags:
      - common
      - package

  - name: ACTION | Install libvirt dependencies on hypervisors hosts
    import_role:
      name: apt
      tasks_from: install_packages.yml
    vars:
      update_before_install: false
      packages: "{{ virt_dependencies }}"
    tags:
      - virtualization
      - packages

- hosts: hypervisors
  tasks:

  - name: ROLE | Ensure users exists
    import_role:
      name: users
    vars:
      users: "{{ local_users }}"
    tags:
      - virtualization
      - user