Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
29279415
Commit
29279415
authored
Jul 16, 2013
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
builder/vmware: error if guest IP is blank [GH-189]
parent
8e1e40c0
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
0 deletions
+11
-0
CHANGELOG.md
CHANGELOG.md
+1
-0
builder/vmware/guest_ip.go
builder/vmware/guest_ip.go
+5
-0
builder/vmware/ssh.go
builder/vmware/ssh.go
+5
-0
No files found.
CHANGELOG.md
View file @
29279415
...
...
@@ -45,6 +45,7 @@ BUG FIXES:
place. [GH-152]
*
virtualbox: "paused" doesn't mean the VM is stopped, improving
shutdown detection.
*
vmware: error if guest IP could not be detected. [GH-189]
## 0.1.5 (July 7, 2013)
...
...
builder/vmware/guest_ip.go
View file @
29279415
package
vmware
import
(
"errors"
"fmt"
"io/ioutil"
"os"
...
...
@@ -68,5 +69,9 @@ func (f *DHCPLeaseGuestLookup) GuestIP() (string, error) {
}
}
if
curIp
==
""
{
return
""
,
errors
.
New
(
"IP not found for MAC in DHCP leases"
)
}
return
curIp
,
nil
}
builder/vmware/ssh.go
View file @
29279415
...
...
@@ -47,6 +47,11 @@ func sshAddress(state map[string]interface{}) (string, error) {
return
""
,
fmt
.
Errorf
(
"IP lookup failed: %s"
,
err
)
}
if
ipAddress
==
""
{
log
.
Println
(
"IP is blank, no IP yet."
)
return
""
,
errors
.
New
(
"IP is blank"
)
}
log
.
Printf
(
"Detected IP: %s"
,
ipAddress
)
return
fmt
.
Sprintf
(
"%s:%d"
,
ipAddress
,
config
.
SSHPort
),
nil
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment