mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-22 18:41:37 +00:00
proxy: keep the fd open to the control file
A future version of the 9P server will shutdown the forward on 9P clunk, so if this process crashes the forward will be cleaned up properly. Signed-off-by: David Scott <dave.scott@docker.com>
This commit is contained in:
parent
e49fff3c5e
commit
d5f25d2727
@ -63,9 +63,8 @@ func exposePort(host net.Addr, port int) error {
|
||||
log.Printf("Failed to read from /port/%s/ctl: %#v\n", name, err)
|
||||
return err
|
||||
}
|
||||
// TODO: consider whether close/clunk of ctl would be a better tear down
|
||||
// signal
|
||||
ctl.Close()
|
||||
// We deliberately keep the control file open since 9P clunk
|
||||
// will trigger a shutdown on the host side.
|
||||
|
||||
response := string(results[0:count])
|
||||
if strings.HasPrefix(response, "ERROR ") {
|
||||
|
Loading…
Reference in New Issue
Block a user