Node-RED: v1.0.6
Node: v10.20.1
OS: Linux xxxxxxxx 3.10.0-514.10.2.el7.x86_64 #1 SMP Thu Mar 2 11:35:29 PST 2017 x86_64 x86_64 x86_64 GNU/Linux
It is worthwhile to note that I am using Docker and persisting node-red data in /data directory. i.e. The settings.js and other files are on the host (/data directory - which is mounted to node-red container /data).
Some background: We make use of Node-RED to create backend APIs for one of our web applications i.e. Node-RED is the backend for our Angular app.
I am able to set up auth using bcrypt and adminAuth setting in the settings.js file. I can login to Node-RED here. Now I want to push these changes to multiple other servers.
I do a docker commit
for the image and push the data from the volume (/data) in the form of a tar
and push it to a registry. This image is extracted by other hosts that sort out the volume using the entrypoint
of the docker image.
Problem: While the login works for the host where I set it up, it does not work for the other servers where I pushed the node-red containers.
I get below error in trace:
10/07/2020 17:05:3510 Jul 11:35:35 - [audit] {"event":"auth.invalid-token","level":98,"timestamp":1594380935483}
10/07/2020 17:06:1110 Jul 11:36:11 - [audit] {"event":"auth.login.fail.credentials","username":"admin","client":"node-red-editor","scope":"","level":98,"timestamp":1594380971194}
10/07/2020 17:10:0210 Jul 11:40:02 - [audit] {"event":"auth.invalid-token","level":98,"timestamp":1594381202139}
10/07/2020 17:19:4010 Jul 11:49:40 - [audit] {"event":"auth.login","username":"admin","client":"node-red-editor","scope":"*","level":98,"timestamp":1594381780401}
I do not get a 'Login failed' message. It just attempts to log in and then comes back to login screen.