Add hypervisor playbook to Vagrant
This commit is contained in:
parent
bad45b2fe9
commit
93ec159bbb
11
dev/host_vars/hypervisor.yml
Normal file
11
dev/host_vars/hypervisor.yml
Normal file
@ -0,0 +1,11 @@
|
||||
# base
|
||||
allow_reboot: false
|
||||
manage_network: false
|
||||
|
||||
# libvirt
|
||||
libvirt_users: vagrant
|
||||
libvirt_isos:
|
||||
- url: https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/debian-10.4.0-amd64-netinst.iso
|
||||
hash: sha256:ab3763d553330e90869487a6843c88f1d4aa199333ff16b653e60e59ac1fc60b
|
||||
- url: https://cdimage.debian.org/debian-cd/current/i386/iso-cd/debian-10.4.0-i386-netinst.iso
|
||||
hash: sha256:549966a43224f237c46ee4397901ec9fd6feae74abb1e6f6baa0078acf77a936
|
9
dev/hypervisor.yml
Normal file
9
dev/hypervisor.yml
Normal file
@ -0,0 +1,9 @@
|
||||
- name: Install Hypervisor
|
||||
hosts: all
|
||||
become: true
|
||||
vars_files:
|
||||
- host_vars/hypervisor.yml
|
||||
roles:
|
||||
- ansible
|
||||
- base
|
||||
- libvirt
|
@ -1,2 +1,3 @@
|
||||
manage_network: false
|
||||
network_type: static
|
||||
allow_reboot: true
|
||||
|
@ -15,3 +15,13 @@
|
||||
append: yes
|
||||
with_items: "{{ libvirt_users }}"
|
||||
when: libvirt_users is defined
|
||||
|
||||
- name: Download GNU/Linux ISOs
|
||||
get_url:
|
||||
url: "{{ item.url }}"
|
||||
dest: /var/lib/libvirt/images
|
||||
checksum: "{{ item.hash }}"
|
||||
owner: libvirt-qemu
|
||||
group: libvirt-qemu
|
||||
loop: "{{ libvirt_isos }}"
|
||||
when: libvirt_isos is defined
|
||||
|
Loading…
Reference in New Issue
Block a user