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
9d55fa7f
Commit
9d55fa7f
authored
Feb 21, 2014
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
communicator/ssh: set TCP keep-alive [GH-872]
parent
eacac89a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
1 deletion
+9
-1
CHANGELOG.md
CHANGELOG.md
+1
-0
communicator/ssh/connect.go
communicator/ssh/connect.go
+8
-1
No files found.
CHANGELOG.md
View file @
9d55fa7f
...
@@ -20,6 +20,7 @@ BUG FIXES:
...
@@ -20,6 +20,7 @@ BUG FIXES:
checksum type is "none"
checksum type is "none"
*
builder/virtualbox,vmware/qemu: Support for additional scancodes for
*
builder/virtualbox,vmware/qemu: Support for additional scancodes for
`boot_command`
such as
`<up>`
,
`<left>`
,
`<insert>`
, etc. [GH-808]
`boot_command`
such as
`<up>`
,
`<left>`
,
`<insert>`
, etc. [GH-808]
*
communicator/ssh: Send TCP keep-alives on connections. [GH-872]
*
provisioners/ansible-local: Properly upload custom playbooks. [GH-829]
*
provisioners/ansible-local: Properly upload custom playbooks. [GH-829]
## 0.5.1 (01/02/2014)
## 0.5.1 (01/02/2014)
...
...
communicator/ssh/connect.go
View file @
9d55fa7f
...
@@ -10,6 +10,13 @@ import (
...
@@ -10,6 +10,13 @@ import (
// is suitable for use with the SSH communicator configuration.
// is suitable for use with the SSH communicator configuration.
func
ConnectFunc
(
network
,
addr
string
)
func
()
(
net
.
Conn
,
error
)
{
func
ConnectFunc
(
network
,
addr
string
)
func
()
(
net
.
Conn
,
error
)
{
return
func
()
(
net
.
Conn
,
error
)
{
return
func
()
(
net
.
Conn
,
error
)
{
return
net
.
DialTimeout
(
network
,
addr
,
15
*
time
.
Second
)
c
,
err
:=
net
.
DialTimeout
(
network
,
addr
,
15
*
time
.
Second
)
if
err
!=
nil
{
return
nil
,
err
}
if
tcpConn
,
ok
:=
c
.
(
*
net
.
TCPConn
);
ok
{
tcpConn
.
SetKeepAlive
(
true
)
}
}
}
}
}
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