Skip to content

SSL Certs

craig2017 edited this page Mar 20, 2017 · 2 revisions

Configuring SSL

There are 2 ways to configure SSL.

1. Provide your own cert

You can use your own certs by providing them in the projects /nginx/conf/certs directory.

Without needing to modify the nginx template file /nginx/conf/conf.d/opp.template, you can just name your certs and keys: opp-ui-crt.pem opp-ui-key.pem opp-svc-crt.pem opp-svc-key.pem

2. Auto cert generation

If you chose to do nothing, certs will be automatically generated for you.

SSL and certs are configured in the docker-compose.yml

ui:
    build: ./nginx
    ...    
    environment:
    - SSL_CERT_INFO="C=US/ST=MA/L=Boston/O=MyOrg/OU=Performance Team/Email=craig@myteam.org"
    - SSL_DH_SIZE=2048 #Diffie-Hellman size (extra ssl security - slow to generate)
    - NGINX_HOST_UI=opp-ui.roving.com
    - NGINX_HOST_SVC=opp-svc.roving.com
    - NGINX_PORT=443

Certificate caching

By default, your certs will be cached on a docker volume. This speeds up the process so they aren't auto generated each time.

To clear the cache, you need to just remove the volume.

remove container: docker rm opp_ui_1 remove volume: docker volume rm opp_nginxCerts

Clone this wiki locally