Node Red with Duckdns/Let's Encrypt isn't executing locally. Please help a novice?

I was having the same issue - the solutions above seemed fine if I wanted to expose nodered to the internet (eg. port forwarding etc) but I just wanted nodered to be accessible locally (while HA was open to the internet with letsencrypt & duckdns setup).

I tried all the same URL’s as the original posted - turned out the solution was to just add an entry to my hosts file on the pi so calls from nodered were just looped back to the local interface when yourdomain.duckdns.org:8123 was called.

Try
sudo nano /etc/hosts

at the bottom I added
127.0.0.1 yourdomain.duckdns.org

and all working fine now (and no access to nodered from outside my network)

1 Like

Hi Wayne, two of the solutions mentioned above don’t require any port forwarding and don’t expose Node Red to the internet.

Thanks for posting your solution though! The more solutions that are mentioned, the more potential to help just about anyone having the same problem, regardless of their setup.

How exactly do I configuring the Node-Red Home Assistant server URL with hassio? I’m trying to access the node red webpage though can’t because of duckdns.

So I can now acess my HA through the IP:8123 and also XXXX.duckdns.org (using ssl with nginx). Though Ive tried everything to access the node red UI with no luck. I have port 80 and 443 forwarded. Any ideas on whats happening?

I’ve always used: http://IP_Address:1880. If that doesn’t work for you, I don’t know what’s wrong.

can you tell me how to do this?

Sure! I learned how to do it from an article on the DIY Futurism blog. I linked to the article in the third post in this thread. Scroll down the blog post to the “Routing Traffic Locally” section. It shows you what you need to add to the “hosts” configuration setting.

where you put this?

“Neither of those options were available to me, but I am running Pi Hole. Since Pi Hole is acting as the DNS server for my local network, I can add a custom host entry for my domain name. Now, all the clients on my LAN will resolve hass.mydomain.com to the private IP instead of the public one:”

Are you using Hass.io? You add this to the Pi-hole add-on configuration. I have no idea how to do this on other versions of Home Assistant.

I use HASSIO, but currently I have pihole on a separate PI3

Sorry, I don’t know if it’s possible with your setup. Maybe someone more knowledgeable than me will be able to help.

The link to DIY Futurism is broken. Are there any other version available as I’d like to try out the Pi-Hole fix.

1 Like

That’s unfortunate! I’m not aware of another online resource that shows this.

The gist is this…
Using the Pi-hole add-on for Hassio, you can add your DuckDNS domain as a host in the configuration section of the add-on.

Look for the hosts section and add this:
“hosts”: [
{
“name”: “yourdomain.duckdns.org”,
“ip”: “xxx.xxx.xxx.xxx”
}
]

Supplying the IP address of your Raspberry Pi, this will resolve your custom domain to your local IP address.

Sorry to hijack this thread from last year, but I’m trying to do this same thing but I’m working with HA and Node-RED and LetsEncrypt in Docker containers.

I tried the http://hassio/homeassistant trick and that did not work.

Any thoughts?

Sorry, but I don’t know any alternatives if that URL isn’t working for you.