forked from silvinux/kvm-guest-rhn-idm
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathkvm.yml
69 lines (68 loc) · 1.82 KB
/
kvm.yml
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
---
- hosts: local
gather_facts: yes
connection: local
become: yes
become_method: sudo
environment:
LIBGUESTFS_BACKEND: direct
roles:
- role: kvm-guest-qcow2
### Variables
## Paths
vm_location: "/var/lib/libvirt/images"
image: "/home/silvinux/kvm/rhel-server-7.6-x86_64-kvm.qcow2"
path_output: "/var/log/cloud-init.log"
## Image
new_image_size: "10G"
## Owner
dir_owner: silvinux
dir_group: silvinux
useransible: silvinux
## Storage
env_LIBGUESTFS_BACKEND: "direct"
preallocation: metadata
ssh_keys:
- sshkey: ssh-rsa AAAAprilNzaC1li15I1NTE5AAAAIBlv6QfLyGzTf2IkJaj3zeFuWjmk9Ll3oT/n0Zdgd/6Z [email protected]
## Users
users_dic:
- name: silvinux
groups: users,wheel
shell: /bin/bash
sudo: ALL=(ALL) NOPASSWD:ALL
chg_pwd_users:
- name: root
password: toor
## Timezone
timezone: "Europe/Madrid"
## VM definition
guests:
test1:
fqdn: test.lab.example.com
mem: 2048
cpus: 1
os_type: rhel7
file_type: qcow2
pnetwork: "virbr0"
model: virtio
graphics: spice
address: 192.168.122.13
network: 192.168.122.0
netmask: 255.255.255.0
broadcast: 192.168.122.255
gateway: 192.168.122.1
test1:
fqdn: test1.lab.example.com
mem: 2048
cpus: 1
os_type: rhel7
file_type: qcow2
pnetwork: "virbr0"
model: virtio
graphics: spice
address: 192.168.122.113
network: 192.168.122.0
netmask: 255.255.255.0
broadcast: 192.168.122.255
gateway: 192.168.122.1
- import_playbook: rhn_register.yml