chameleonbr / node-red-contrib-redis

Node RED client for Redis with pub/sub, list, lua scripting and other commands support.
MIT License
46 stars 40 forks source link

Only able to connect Localhost #35

Closed luigonsec closed 4 years ago

luigonsec commented 4 years ago

Hi guys!

I am facing a rare problem with the node-red-contrib-redis module. No matter how I configure the server, it always sends the commands to localhost.

I attach pictures of how I am configuring the node, maybe that is not the way to do it.

Captura de pantalla 2020-07-03 a las 14 27 25 Captura de pantalla 2020-07-03 a las 14 27 59

Any idea of what could be happening?

chameleonbr commented 4 years ago

Object format is:

{ "host":"10.0.0.189", "port":6379, "db":5 }

chameleonbr commented 4 years ago

Now you could add connection string to Config node too...

Look the two options...

Captura de tela_2020-07-03_17-24-08

Captura de tela_2020-07-03_17-23-02

Kristofer3127 commented 3 months ago

By default, Redis can only be accessed locally. In addition to the object format @chameleonbr, you need to edit the Redis config file, usually found at etc/redis/redis.conf. Find and comment out the line bind 127.0.0.1. Just below it, add the line bind 0.0.0.0. The Redis server will now listen to all incoming IP addresses, rather than only localhost. This works for me, because in my system, security access is controlled at the network level, not at the individual app level. Reference: Baeldung: Connecting to a Remote Redis Server