Question

Docker Nginx-proxy and letsencrypt not working

Posted December 6, 2018 1.5k views
Nginx DigitalOcean Docker Let's Encrypt

Hi, I’m writing this out of frustration, after reading all available tutorials and docs, but apparently I’m missing something important.

I want to revamp my website [MYDOMAIN] using docker and create a static website, a POSTGRES container, and some Dockerized apps.
I started out registering MYDOMAIN on Digital Ocean Network section with www and without.
Then:
I cloned and started https://github.com/jwilder/nginx-proxy
I cloned https://github.com/evertramos/docker-compose-letsencrypt-nginx-proxy-companion
Create a .env with my Digital Ocean IP:

Set the IP address of the external access Interface

IP=0.0.0.0

After that if I run

./teststartssl.sh MYDOMAIN
./teststartssl.sh www.MYDOMAIN

And I get “it works” results then I run ./test_stop.sh

After that I registered a subdomain portainer.MYDOMAIN
I cloned https://github.com/evertramos/docker-portainer-letsencrypt
And updated the following parameters:
DOMAINS= MYDOMAIN.com,www. MYDOMAIN.com,portainer. MYDOMAIN.com
MAINDOMAIN=portainer. MYDOMAIN.com
LETSENCRYPT
EMAIL=youremail@domain.com
PORTAINER
SSLPATH=/path/to/your/certs
PORTAINER
SSLCERTIFICATE=/certs/ MYDOMAIN.crt
PORTAINER
SSL_KEY=/certs/ MYDOMAIN.key
Then I try to visit all my domain and portainer domain always with different errors
Can somebody point me in the right direction or suggest a tutorial?

0 answers
Submit an answer

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!