Sign inSign up

ldclakmal/go-http-passthrough

By ldclakmal

•Updated over 6 years ago

Go HTTP Passthrough (Proxy) Service

Image
0

1.4K

ldclakmal/go-http-passthrough repository overview

⁠Go HTTP Passthrough (Proxy) Service

A Docker image of Go passthrough service which forward the request to configured backend and forward the response to the client. Supports both HTTP/1.1 and HTTP/2.0 with SSL. Also, supports any type of request payload such as text, json, xml etc.

⁠Installed
  1. Ubuntu 16.04
  2. Go 1.14.2
⁠Run the image
  • HTTP/1.1 - $ docker run -d --network="host" -p 9090:9090 -e "VERSION=1" ldclakmal/go-http-passthrough:latest
  • HTTP/2.0 - $ docker run -d --network="host" -p 9090:9090 -e "VERSION=2" -e "MAXSTREAM=1000" ldclakmal/go-http-passthrough:latest

⁠Test the image
  • HTTP/1.1 - $ curl -kv https://localhost:9090/passthrough -d "Hello GoLang"
  • HTTP/2.0 - $ curl --http2 -kv https://localhost:9090/passthrough -d "Hello GoLang"

(Since this is a proxy, there should be a backend HTTP service already started on port 9191 with request path /hello/sayHello. i.e. $ curl -v http://localhost:9191/hello/sayHello should be up and running)

Tag summary

Content type

Image

Digest

Size

338.5 MB

Last updated

over 6 years ago

docker pull ldclakmal/go-http-passthrough