Giel Berkers
Giel Berkers

Reputation: 2960

Docksal : How can I enable HTTPS / SSL?

I'm using Docksal, but I want to use HTTPS/SSL.

Now I am able to navigate to my site by going to the https://-domain, but my browser shows that the certificate is invalid (the certificate is from "Internet Widgits Pty Ltd").

I cannot seem to find something in the documentation on how to enable https. It only states that the web service uses self-signed certificates, but these are not allowed by my system (unlink Valet+ for example, which installs the self-signed certificates for you).

Can anyone point me in the right direction on how to enable HTTPS/SSL?

Upvotes: 3

Views: 2382

Answers (1)

Oleksii Chekulaiev
Oleksii Chekulaiev

Reputation: 401

  1. Put your certificates for your project's virtual host into $HOME/.docksal/certs. E.g. if your project's virtual host is example.com then put CRT and KEY files as:
$HOME/.docksal/certs/example.com.crt
$HOME/.docksal/certs/example.com.key
  1. If you never had $HOME/.docksal/certs directory before you will need to do fin system reset for docksal-vhost-proxy to find it
  2. In your project set environment variable
VIRTUAL_HOST_CERT_NAME="example.com"
  1. Restart the project with fin project restart

Upvotes: 2

Related Questions