mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Merge pull request #1069 from ccaum/improve_libvirt_support
Improve libvirt support
This commit is contained in:
commit
a909ab7ed0
2 changed files with 5 additions and 3 deletions
|
@ -240,8 +240,10 @@ module Fog
|
|||
# It returns an array of public and private ip addresses
|
||||
# Currently only one ip address is returned, but in the future this could be multiple
|
||||
# if the server has multiple network interface
|
||||
def addresses(connection, options={})
|
||||
mac=self.mac
|
||||
def addresses(connection=connection, options={})
|
||||
unless mac = self.mac
|
||||
mac = Nokogiri::XML(`virsh dumpxml #{self.name}`).xpath('//domain/devices/interface/mac').first.attribute('address').content
|
||||
end
|
||||
|
||||
# Aug 24 17:34:41 juno arpwatch: new station 10.247.4.137 52:54:00:88:5a:0a eth0.4
|
||||
# Aug 24 17:37:19 juno arpwatch: changed ethernet address 10.247.4.137 52:54:00:27:33:00 (52:54:00:88:5a:0a) eth0.4
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
<target port='0'/>
|
||||
</console>
|
||||
<input type='mouse' bus='ps2'/>
|
||||
<graphics type='<%= display[:type] %>' port='<%= display[:port] %>' autoport='yes' listen='<%= display[:listen] %>' passwd='<%=display[:password] %>'/>
|
||||
<graphics type='<%= display[:type] %>' port='<%= display[:port] %>' autoport='yes' <% if display[:listen] and !(display[:listen].empty?) %> listen='<%= display[:listen] %>'<% end %> <% if display[:password] and !(display[:password].empty?) %>passwd='<%=display[:password] %>'<% end %> />
|
||||
<video>
|
||||
<model type='cirrus' vram='9216' heads='1'/>
|
||||
</video>
|
||||
|
|
Loading…
Add table
Reference in a new issue