The first step in creating our mock layer 7 routing service is to generate a certificate for our test domain (for local testing, just add the at-sea.mydomain.com to your dev machine host file). In the following diagram, we generate the certificates with an interactive Certificate Signing Request (CSR) ( the openssl req command will prompt you for the CSR parameters, and this is where you provide the common name of your domain) using the openssl req command to generate the certificate (.crt) and private key (.key) files that are required by NGINX for termination.
We will use Docker secrets (requires Docker Engine-Community Swarm to be initialized) to safely store the certificate ...