This repository has been archived by the owner on Jun 16, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Setting up SSL
Joshua Zenn edited this page Jan 17, 2022
·
5 revisions
Because it is not possible to get a valid SSL certificate for the localhost
domain, you will need to import this project's self-signed certificate to your trusted certificate store. This certificate is generated the first time you launch the Docker Compose stack and is completely safe to trust as long as you don't share any .crt or .key files with anyone or accidentally commit the certificate to GitHub.
- Run the entire Docker Compose stack with
docker compose up --build
for at least 30 seconds, or until text stops appearing in your terminal. - From the project directory in Explorer, double-click on
./proxy/cert/virtudoc-https.pfx
. - In the dialog box that appears, select
Current User
- Ensure that the path to the PFX file appears, then click next.
- Leave the password field blank, then click next.
- Select
Place all certificates in the following store
. ClickBrowse
and selectTrusted Root Certificate Authorities
. Click next. - Click finish to import the certificate and close the wizard. If a warning pops up, click accept.
- Restart your browser and/or your computer.
- Launch the Docker Compose stack, including the
proxy
component. - In your browser, go to
https://localhost
and ensure that you do not receive a certificate warning.
- Run the entire Docker Compose stack with
docker compose up --build
for at least 30 seconds, or until text stops appearing in your terminal. - Open the project directory in your terminal.
- Run the following:
cd ./proxy/cert
sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain virtudoc-https.pfx
- If prompted, enter your user account password to confirm the action.
- Restart your browser and/or your computer.
- Launch the Docker Compose stack, including the
proxy
component. - In your browser, go to
https://localhost
and ensure that you do not receive a certificate warning.
- Run the entire Docker Compose stack with
docker compose up --build
for at least 30 seconds, or until text stops appearing in your terminal. - Open the project directory in your terminal.
- Run the following:
cd ./proxy/cert
copy virtudoc-https.crt /usr/local/share/ca-certificates/virtudoc-https.crt
chmod 644 /usr/local/share/ca-certificates/virtudoc-https.crt
update-ca-certificates
# follow the on-screen prompts to add the certificate to the trusted root store.