Re: [PATCH v2 18/21] schema: domain: Accept VMWARE disk sources for the disk

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thursday, 8 October 2020 10:47:16 CEST Peter Krempa wrote:
> Our vmware driver chose to format disk paths starting with a square
> bracket. This would not conform to the RNG schema for disk source.
> Modify the schema to allow these since it's around for some time.

s/VMWARE/VMware/ in the first line of the commit message.

Also, the format is not a real path: it's the datastore where the VM
is stored, followed by the relative path in it. This is also
documented: https://libvirt.org/drvesx.html#datastore

> diff --git a/docs/schemas/basictypes.rng b/docs/schemas/basictypes.rng
> index b1fb939aff..42e94c40e9 100644
> --- a/docs/schemas/basictypes.rng
> +++ b/docs/schemas/basictypes.rng
> @@ -303,6 +303,12 @@
>      </data>
>    </define>
> 
> +  <define name="vmwarePath">
> +    <data type="string">
> +      <param name="pattern">\[.+\] .+</param>

Let's make the datastore part slightly more strict:

     <param name="pattern">\[[^\]+\] .+</param>

So it should work also with a greedy validator.

With the above changes:

Reviewed-by: Pino Toscano <ptoscano@xxxxxxxxxx>

-- 
Pino Toscano

Attachment: signature.asc
Description: This is a digitally signed message part.


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux