Installing DuckDNS

Next we will install DuckDNS on your system. On your web browser go to https://www.duckdns.org/

You can create a new account with your github credentials, just click on the Sign in with github and follow the instructions. Then create a new subdomain, name it whatever you want, see if it is available and click create.

When your subdomain is created leave the duckdns page open, you will need the token shown on it later. Then go to your router settings and you have to port forward the Home Assistant port to duckdns. The port is 8123 and the Home Assistant IP is what you set up in the config – system – network page. You need a static IP for Home Assistant!

If you do not know how to set up port forwarding on your router then check this page:

https://portforward.com/router.htm

Find your router by manufacturer and model number and follow the instructions.

If your port forward is complete then on your Home Assistant go to config – add-ons – add-ons store – search for duckdns. Install the add on, then go to configure and in the domains section add your duckdns subdomain and hit enter (myhomeassistantsubdomain.duckdns.org). then copy the token from duckdns page and paste it in token window.

In the Let’s Encrypt window copy and paste this:
accept_terms: true
algo: secp384r1
certfile: fullchain.pem
keyfile: privkey.pem

Set seconds to 300. Click save and then start the add on from the Information panel. Turn on the Observer option (it will automatically restart DuckDns add-on if it crashes). Go to Logs tab and check if the Let’s Encrypt certificate was installed successfully, wait couple of minutes, refresh the log and check again. If the certificate was not created then restart DuckDns add-on from the information panel and check the logs again. If this time the certificate was not installed you may need to open on your router ports 80 and 443 and tie them to your Home Assistant IP. Restart DuckDns add on and check if you have the certificate. After you get it then you can delete port forward to ports 80 and 443 on your router (leave port 8123 open).

Then you need to go to config – add-ons – add-ons store and search for File Editor, install the add on, start it, check the Observer and Show on the side options. Go to the File Editor open your configuration.yaml file. Add this to the page below default_config: line:

http:
    ssl_certificate: /ssl/fullchain.pem
    ssl_key: /ssl/privkey.pem

Hit save and restart your Home Assistant. If it turns back on check the page myhomeassistantsubdomain.duckdns.org:8123 to see if it works, if you get a Home Assistant login screen your good to go! At this point you can install Home Assistant app on your phone, go to the app store and find it and install. In the configuration on the start of the app provide the duckdns address of your Home Assistant and log in. Now you can control your home from anywhere! And you just did your first yaml editing!

By:

Posted in:


Dodaj komentarz

Design a site like this with WordPress.com
Rozpocznij