Go to file
2016-12-29 19:21:37 +01:00
.gitignore Removed unsecure RC4 2016-04-10 09:36:03 +02:00
Dockerfile rework / refactoring / documentation 2016-04-12 07:05:24 +02:00
haproxy_ssl.conf reordered statements 2016-12-29 19:21:37 +01:00
haproxy.conf add X-Forwarded-For Header to request 2016-12-29 19:15:45 +01:00
letsencrypt.conf rework / refactoring / documentation 2016-04-12 07:05:24 +02:00
list_domains.py first step to refactor 2016-04-10 12:36:43 +02:00
NOTES add code to extract all resolving domains from the containers 2016-04-07 08:03:13 +02:00
README.md Update README.md 2016-12-29 19:09:31 +01:00
start.py Fixed issues with relative directories 2016-04-12 07:29:39 +02:00

SSL Termination using HAProxy

This image translates between plain http and https using HAProxy.

How it works

                                                                          +-------------+
                                                                          |             |
                                                                     +----+             |
                                                          +--------->+8080|   Tomcat    |
                                                          |          +----+             |
                                                          |               |             |
        +-------------------------+                       |               +-------------+
        |                         |                       |
    +---+                         |          +------------+-+             +-------------+
--->+ 80|                         |          |              |             |             |
    +---+                         |      +---+ docker nginx |        +----+             |
        |    SSL Proxy            +----->+ 80|  auto proxy  +-------->  80|  Wordpress  |
    +---+                         |      +---+              |        +----+             |
--->+443|                         |          |              |             |             |
    +---+                         |          +--+---------+-+             +-------------+
        |                         |             |         |
        +---------+------------+--+             |         |               +-------------+
                  |            |                |         |               |             |
                  v            |                |         |         +-----+    Flask    |
               +--+-+          |   +------+     |         +-------->+5000||             |
               |Cert|          |   |Docker|     |                   +-----+     App     |
               |Data|          +-->+Socket+<----+                         |             |
               +----+              +------+                               +-------------+

The docker_ssl_endpoint Container listens on port 443 (expose this port for public) availability. All secure connections coming in on this port are handled using the certificates form the cert data volume and passed on to the target container's port 80.

Starting the container

docker run --name ssl_endpoint -v $PATH_TO_CERT_DATA:/data -v /var/run/docker.sock:/var/run/docker.sock -p $IP:443:443 -p $IP:80:80 -d --link nginx:target docker_ssl_endpoint