Class: Docker::Container

Inherits:
Object
  • Object
show all
Defined in:
lib/buncker/patches/docker.rb

Instance Method Summary collapse

Instance Method Details

#attach(options = {}, &block) ⇒ Object



12
13
14
15
16
17
18
19
# File 'lib/buncker/patches/docker.rb', line 12

def attach(options = {}, &block)
  if (stdin = options.delete(:stdin))
    stdin_thread = stream_stdin stdin
  end

  orig_attach options, &block
  stdin_thread.join
end

#orig_attachObject

the original doesn’t work with SSL sockets due to inability to close just one half of them

work around that by opening a separate connection for stdin



10
# File 'lib/buncker/patches/docker.rb', line 10

alias_method :orig_attach, :attach