1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

[Rackspace|Compute] fixed issue with bootstrap method where server was ready, but it had not received an ipv4 address yet. Added check for ip address in server ready block as well as a timeout parameter

This commit is contained in:
Kyle Rames 2013-01-15 16:45:21 -06:00
parent a2255c7a66
commit 575d3abf8e

View file

@ -14,9 +14,9 @@ module Fog
load(data)
end
def bootstrap(new_attributes = {})
def bootstrap(new_attributes = {}, timeout=1500)
server = create(new_attributes)
server.wait_for { ready? }
server.wait_for(timeout) { ready? && !ipv4_address.empty? }
server.setup(:password => server.password)
server
end