DEV Community

jzombie
jzombie

Posted on

2 1

Using Docker for a local HTTPS proxy

Sometimes when you're developing locally, you might need to use HTTPS, and might not have that tooling available in your framework of choice.

So I created this small Docker container which essentially creates a self-signed SSL certificate and uses nginx as a reverse proxy to pipe your request to whatever address you want to.

To use:

$ git clone https://github.com/zenOSmosis/docker-dev-ssl-proxy
Enter fullscreen mode Exit fullscreen mode
  • enter the repo directory
$ cd docker-dev-ssl-proxy
Enter fullscreen mode Exit fullscreen mode
$ docker run --net=host -e PROXY_ADDRESS="http://localhost:8080" docker-dev-ssl-proxy
Enter fullscreen mode Exit fullscreen mode

(The address you've defined in PROXY_ADDRESS will be proxied through to https://localhost.)

Note: For production usage, you might want to check out: https://github.com/linuxserver/docker-swag

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

Top comments (0)

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more