diff options
author | Thomas Hipp <thipp@suse.de> | 2017-07-07 17:40:35 +0200 |
---|---|---|
committer | Flavio Castelli <flavio@castelli.me> | 2017-07-27 14:59:30 +0200 |
commit | ccf4dff4f872291b5cf131cbdfb3d3c5b2f0dd47 (patch) | |
tree | dfd1952f157bf6f369c561379ed90ba500fd0853 /libvirt/utils_libvirt.go | |
parent | ed3000f4d3b2ee5eeab855f32e9fde80193944df (diff) | |
download | terraform-provider-libvirt-ccf4dff4f872291b5cf131cbdfb3d3c5b2f0dd47.tar terraform-provider-libvirt-ccf4dff4f872291b5cf131cbdfb3d3c5b2f0dd47.tar.gz |
use github.com/libvirt-go-xml
Replace the custom XML structs with libvirt's offcial ones.
This resolves #143.
Signed-off-by: Thomas Hipp <thipp@suse.de>
Diffstat (limited to 'libvirt/utils_libvirt.go')
-rw-r--r-- | libvirt/utils_libvirt.go | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libvirt/utils_libvirt.go b/libvirt/utils_libvirt.go index ae7943c5..7918aac6 100644 --- a/libvirt/utils_libvirt.go +++ b/libvirt/utils_libvirt.go @@ -5,12 +5,13 @@ import ( "log" libvirt "github.com/libvirt/libvirt-go" + "github.com/libvirt/libvirt-go-xml" ) func getHostXMLDesc(ip, mac, name string) string { - dd := defNetworkIpDhcpHost{ - Ip: ip, - Mac: mac, + dd := libvirtxml.NetworkDHCPHost{ + IP: ip, + MAC: mac, Name: name, } xml, err := xmlMarshallIndented(dd) |