lib/kytoon/providers/xenserver/server_group.rb in kytoon-1.3.5 vs lib/kytoon/providers/xenserver/server_group.rb in kytoon-1.3.6

- old
+ new

@@ -235,11 +235,11 @@ cidr = IPAddr.new(sg.netmask).to_i.to_s(2).count("1") hosts_file_data = "127.0.0.1\tlocalhost localhost.localdomain\n" sg.servers.each do |server| - hosts_file_data += "#{server['ip_address']}\t#{server['hostname']}\n" + hosts_file_data += "#{server['ip_address']}\t#{server['hostname']}\t#{server['hostname']}.local\n" end Kytoon::Util.remote_exec(%{ # Add first IP to bridge if ! ip a | grep #{sg.gateway}/#{cidr} | grep #{sg.bridge}; then @@ -371,10 +371,10 @@ COUNT=$(( $COUNT + 1 )) [ $COUNT -eq 20 ] && break sleep 1 done ssh #{hostname} bash <<-EOF_SSH_BASH -hostname #{hostname} +hostname #{hostname}.local EOF_SSH_BASH scp /etc/hosts #{hostname}:/etc/hosts }, gw_ip) do |ok, out| puts out if not ok