Help with: HTTPS:// (SSL) with HA, DuckDNS, Let's Encrypt in Docker

Tags: #<Tag:0x00007f32743aeeb0> #<Tag:0x00007f32743aed20> #<Tag:0x00007f32743aeaf0>

Hi, I am trying to get setup with SSL on HA.

I have setup Duck DNS and can access my HA through my duckdns subdomain. (mydomain.ducks.org).

The issue is, that I am not sure where to go from here with getting set up with the SSL and let’s encrypt or certbot. I am running HA in a docker container on a RPI 3 with Raspbian 32 bit.

Could anyone give me an easy guide to get this setup in my configuration and what my next steps should be? I am happy to help with more info.

Many Thanks.

UPDATE: I still have no solution for this. Can anyone help at all?

Hello GreeBear33,
you need to check the documentation of duckdns. It is all explained it there. Basically, you need to accept the terms of the Let’s encrypt.
accept_terms: true
and put your duckdns token
token:
and put a portforward on your internet router to your home assistant

Hi Alejandro.

Thank you for the advice.

I have already downloaded certbot and have retrived my certificate. The files are saved on my Rpi at the following locations: for privacy i have changed my domain to xxxxxx

/etc/letsencrypt/live/xxxxxx.duckdns.org/fullchain.pem
/etc/letsencrypt/live/xxxxxx.duckdns.org/privkey.pem

I tried to follow a tutorial and it said to add the following to my configuration.yaml file:

ssl_certificate: /etc/letsencrypt/live/xxxxxx.duckdns.org/fullchain.pem
ssl_key: /etc/letsencrypt/live/xxxxxx.duckdns.org/privkey.pem
base_url: xxxxxx.duckdns.org:8123

But it doesn’t work and tells me the config is not valid.

I currently have my duckdns working with http:// with this in my configuration.yaml file:

duckdns:                                                                    
  domain: xxxxxxxx                                               
  access_token: xxxxxxx-xxxx-xxxxx-xxxx-xxxxxxxxxx

Since that works, I am happy but I would like to secure the connection. Anyone can help me with some guidance?

GreenBear33, duckdns does all the configuration for let’s encrypt and everything you don’t need to install certbot.
for the secure connection you need to install MariaDB addon. once you have it running, install Nginx Proxy Manager addon to send the http protocol to https. Follow the documentation on Nginx Proxy Manager addon
if you want you can use ngrok addon but you won’t have a custom domain unless you paid for it.

Hi Alejandro.

I am using HA in Docker so there are no add-ons.

Any luck with this? I’m stuck on this issue as well – HA on docker + duckDNS and LetsEncrypt.