Skip to content

Instantly share code, notes, and snippets.

@foliea
Last active August 29, 2015 14:18
Show Gist options
  • Save foliea/7140178a497457499c55 to your computer and use it in GitHub Desktop.
Save foliea/7140178a497457499c55 to your computer and use it in GitHub Desktop.
DockerProxy.prototype.hijack = function(req, clientSocket) {
this.client({
method: req.method,
uri: this.host+req.url
})
.on('socket', function(dockerSocket) {
dockerSocket.pipe(clientSocket);
.pipe(dockerSocket);
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment