blob: 32631299b17e6d6445923b7606e30959bd0c0955 [file] [log] [blame]
Ales Komarekefc4f0f2015-03-06 15:48:25 +01001
2=======
3Libvirt
4=======
5
6Sample pillars
7==============
8
9simple libvirt server
10
11
12.. code-block:: yaml
13
14 libvirt:
15 server:
16 enabled: true
17
18.. code-block:: yaml
19
20 libvirt:
21 server:
22 enabled: true
23 network:
24 default:
25 ensure: absent #present, running, stopped, absent
26 mydefault:
27 xml: |
28 <network>
29 <name>mydefault</name>
30 <bridge name="virbr0"/>
31 <forward/>
32 <ip address="192.168.122.1" netmask="255.255.255.0">
33 <dhcp>
34 <range start="192.168.122.2" end="192.168.122.254"/>
35 </dhcp>
36 </ip>
37 </network>
38 ovs-net:
39 autostart: False
40 xml: |
41 <network>
42 <name>ovs-net</name>
43 <forward mode='bridge'/>
44 <bridge name='ovsbr0'/>
45 <virtualport type='openvswitch'>
46 <parameters interfaceid='09b11c53-8b5c-4eeb-8f00-d84eaa0aaa4f'/>
47 </virtualport>
48 </network>
49
50.. code-block:: yaml
51
52 libvirt:
53 server:
54 enabled: true
55 pool:
56 virtimages:
57 type: dir
58 path: /var/lib/libvirt/images
59 xml: |
60 <pool type="dir">
61 <name>virtimages</name>
62 <target>
63 <path>/var/lib/libvirt/images</path>
64 </target>
65 </pool>
66 virtimages2:
67 ensure: absent
68 type: dir
69 path: /var/lib/libvirt/images2
70 xml: |
71 <pool type="dir">
72 <name>virtimages2</name>
73 <target>
74 <path>/var/lib/libvirt/images2</path>
75 </target>
76 </pool>
77
78Read more
79=========
80
81* https://github.com/bechtoldt/saltstack-libvirt-formula