[Ovirt-devel] [PATCH server] move add_guest_server_to_etc_hosts into common dns
Hugh O. Brock
hbrock at redhat.com
Mon Apr 13 02:01:01 UTC 2009
On Thu, Apr 09, 2009 at 03:17:05PM -0400, Joey Boggs wrote:
> If using a remote dns server the installer will fail, since the imported dns::remote class does not contain add_guest_server_to_etc_hosts, adding it to common is the quickest fix until the classes are better organized to common/remote/bundled
>
> ---
> installer/modules/ovirt/manifests/dns.pp | 10 +++++-----
> 1 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/installer/modules/ovirt/manifests/dns.pp b/installer/modules/ovirt/manifests/dns.pp
> index 57c128b..7709cbf 100644
> --- a/installer/modules/ovirt/manifests/dns.pp
> +++ b/installer/modules/ovirt/manifests/dns.pp
> @@ -65,17 +65,17 @@ define dns::common($guest_ipaddr="", $admin_ipaddr="",$guest_dev="",$admin_dev="
> require => [Single_exec["set_hostname"], Package["dnsmasq"], File["/etc/dhclient.conf"]] ,
> notify => Service[dnsmasq],
> }
> +
> + single_exec {"add_guest_server_to_etc_hosts":
> + command => "/bin/echo $guest_ipaddr $ipa_host >> /etc/hosts",
> + notify => [Service[dnsmasq], Single_exec["add_dns_server_to_resolv.conf"]]
> + }
> }
>
> define dns::bundled($guest_ipaddr="", $admin_ipaddr="",$guest_dev="",$admin_dev="") {
>
> dns::common{"setup": guest_ipaddr=>$guest_ipaddr, admin_ipaddr=>$admin_ipaddr, guest_dev=>$guest_dev, admin_dev=>$admin_dev}
>
> - single_exec {"add_guest_server_to_etc_hosts":
> - command => "/bin/echo $guest_ipaddr $ipa_host >> /etc/hosts",
> - notify => [Service[dnsmasq], Single_exec["add_dns_server_to_resolv.conf"]]
> - }
> -
> augeas{"set_system_hostname":
> context => "/files/etc/sysconfig/network",
> changes => [
This was tested by Mike McGrath and works, so ACK
--Hugh
More information about the ovirt-devel
mailing list