libvirt: Restart iptables only if a virbr interface exists

This commit is contained in:
Ossi Salmi 2013-07-08 15:48:48 +03:00
parent bd487b87f7
commit f3b849dd66

View file

@ -117,7 +117,7 @@ class libvirt::kvm inherits libvirt::client {
notify => Service["libvirtd"],
}
if defined(Service["iptables"]) {
if $::interfaces =~ /virbr[0-9]/ and defined(Service["iptables"]) {
$iptables = Service["iptables"]
} else {
$iptables = undef