mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-11-05 04:41:20 +00:00
6423e30828
If there are no source extents the volume XML has an empty <source> element. Remove it if there's nothing in it by using virXMLFormatElement. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
22 lines
709 B
XML
22 lines
709 B
XML
<volume type='file'>
|
|
<name>LuksDemo.img</name>
|
|
<key>/var/lib/libvirt/images/LuksDemo.img</key>
|
|
<capacity unit='bytes'>5368709120</capacity>
|
|
<allocation unit='bytes'>294912</allocation>
|
|
<target>
|
|
<path>/var/lib/libvirt/images/LuksDemo.img</path>
|
|
<format type='raw'/>
|
|
<permissions>
|
|
<mode>0644</mode>
|
|
<owner>0</owner>
|
|
<group>0</group>
|
|
<label>unconfined_u:object_r:virt_image_t:s0</label>
|
|
</permissions>
|
|
<encryption format='luks'>
|
|
<secret type='passphrase' uuid='f52a81b2-424e-490c-823d-6bd4235bc572'/>
|
|
<cipher name='serpent' size='256' mode='cbc' hash='sha256'/>
|
|
<ivgen name='plain64' hash='sha256'/>
|
|
</encryption>
|
|
</target>
|
|
</volume>
|