mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
network: wire up dnsmasq option xmlns
This maps to XML like: <network xmlns:dnsmasq='http://libvirt.org/schemas/network/dnsmasq/1.0'> ... <dnsmasq:options> <dnsmasq:option value="foo=bar"/> <dnsmasq:option value="cname=*.foo.example.com,master.example.com"/> </dnsmasq:options> </network> To dnsmasq config options ... foo=bar cname=*.foo.example.com,master.example.com Reviewed-by: Laine Stump <laine@laine.org> Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
@@ -25,8 +25,12 @@ testCompareXMLToConfFiles(const char *inxml, const char *outconf, dnsmasqCapsPtr
|
||||
virCommandPtr cmd = NULL;
|
||||
char *pidfile = NULL;
|
||||
dnsmasqContext *dctx = NULL;
|
||||
virNetworkXMLOptionPtr xmlopt = NULL;
|
||||
|
||||
if (!(def = virNetworkDefParseFile(inxml, NULL)))
|
||||
if (!(xmlopt = networkDnsmasqCreateXMLConf()))
|
||||
goto fail;
|
||||
|
||||
if (!(def = virNetworkDefParseFile(inxml, xmlopt)))
|
||||
goto fail;
|
||||
|
||||
if (!(obj = virNetworkObjNew()))
|
||||
@@ -63,6 +67,7 @@ testCompareXMLToConfFiles(const char *inxml, const char *outconf, dnsmasqCapsPtr
|
||||
VIR_FREE(actual);
|
||||
VIR_FREE(pidfile);
|
||||
virCommandFree(cmd);
|
||||
virObjectUnref(xmlopt);
|
||||
virNetworkObjEndAPI(&obj);
|
||||
dnsmasqContextFree(dctx);
|
||||
return ret;
|
||||
@@ -141,6 +146,7 @@ mymain(void)
|
||||
DO_TEST("dhcp6-nat-network", dhcpv6);
|
||||
DO_TEST("dhcp6host-routed-network", dhcpv6);
|
||||
DO_TEST("ptr-domains-auto", dhcpv6);
|
||||
DO_TEST("dnsmasq-options", dhcpv6);
|
||||
|
||||
virObjectUnref(dhcpv6);
|
||||
virObjectUnref(full);
|
||||
|
||||
Reference in New Issue
Block a user