This repository was archived by the owner on Feb 27, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -252,7 +252,7 @@ func cmdUp() int {
252252 break
253253 }
254254 }
255- if err := read (natSSH , 1 , 1 * time .Second ); err == nil {
255+ if err := read (natSSH , 1 , 2 * time .Second ); err == nil {
256256 IP = RequestIPFromSSH (m )
257257 break
258258 }
@@ -264,7 +264,13 @@ func cmdUp() int {
264264 logf ("Started." )
265265
266266 if IP == "" {
267- logf ("Auto detection of the VM's IP address." )
267+ // lets try one more time
268+ time .Sleep (3 )
269+
270+ IP = RequestIPFromSSH (m )
271+ if IP == "" {
272+ logf ("Auto detection of the VM's IP address failed." )
273+ }
268274 }
269275 switch runtime .GOOS {
270276 case "windows" :
@@ -484,7 +490,7 @@ func cmdIP() int {
484490func RequestIPFromSSH (m * vbx.Machine ) string {
485491 // fall back to using the NAT port forwarded ssh
486492 out , err := cmd (B2D .SSH ,
487- //"-vvv ", //TODO: add if its boot2docker -v
493+ "-v " , // please leave in - this seems to improve the chance of success
488494 "-o" , "StrictHostKeyChecking=no" ,
489495 "-o" , "UserKnownHostsFile=/dev/null" ,
490496 "-p" , fmt .Sprintf ("%d" , m .SSHPort ),
You can’t perform that action at this time.
0 commit comments