FreedomBen / dory

Your development proxy for docker
MIT License
156 stars 24 forks source link

Can't find where the default SSL certs directory is? #4

Closed Spittal closed 7 years ago

Spittal commented 8 years ago

I'm a little confused on how to use SSL with this gem.

I know from my experience with dinghy-http-proxy that if I put my certificates with a certain name in a certain directory, it will automatically redirect to HTTPS and use the named certs. As explained here: https://github.com/codekitchen/dinghy-http-proxy#ssl-support

Does this package include that feature? and if it does where do I put my certificates?

Thanks

FreedomBen commented 8 years ago

For all of your containers you can simply hit them with https instead of http and the proxy will serve up it's default certificate (located here: https://github.com/freedomben/dory-http-proxy). This should be on and working by default.

If you want to use your own certificates (useful for avoiding the annoying browser warnings), you should be able to drop them in any directory and then specify that directory it in your ~/.dory.yml. If you put [yourhome]/.dinghy/certs it may just work.

If you don't have a ~/.dory.yml file already, generate one with:

dory config-file

Then specify the directory with the certs in it:

---
dory:
   ...
  nginx_proxy:
    enabled: true
    container_name: dory_dinghy_http_proxy
    https_enabled: true
    ssl_certs_dir: '[yourhome]/.dinghy/certs'
  ...
Spittal commented 7 years ago

This is great info thanks!