June-18th-2020, 09:09 PM
(This post was last modified: February-16th-2021, 06:42 PM by Armin@netPI.)
Ok I see. This was a good hint. I have not been working so far with the HTTP In Node, but now I know what is happening.
The implementation of our containerized Node-RED uses the HTTPS secured method to get accessible securely. In general the Node-RED "settings.js" configuration file located here /root/.node-red/ has a special area where you can configure HTTPS and enable it. The procedure is described for examole on this web page: https://notenoughtech.com/home-automatio...o-nodered/
What I see in the source code of the Node-RED container's build file at https://github.com/HilscherAutomation/ne...Dockerfile is that the lines 98 to 110 are taking care of the settings.js file modification to enable HTTPS handling and also the generation of a self signed certificate and keys.
All relevant files are created in the container folder /root/.node-red/certs. The CA file, the private and the public key. The most relevant file for you is the /root/.node-red/certs/node-cert.pem file. This file is needed on your remote machine to tell it to trust the HTTPS site of this Node-RED instance. It is a text file and you can copy and paste its contents to a cert file on your remove machine and include it in the trusted list of certificates.
I see the following possibilities:
a.) You could use netPIs Docker web UI and click on the running container and use the embedded console function to "jump" into the container and output the /root/.node-red/certs/node-cert.pem file on the screen using the Linux command "cat /root/.node-red/certs/node-cert.pem". Then you can copy the content.
b.) You could fork the container's source code and remove the lines from 98 to 110 and the Node-RED will not more be secured during containers build process. I don't know how familiar you are with building your own container image.
c.) You could call the curl command with the option "-k" to let it trust also untrusted self signed certificates
Thx
The implementation of our containerized Node-RED uses the HTTPS secured method to get accessible securely. In general the Node-RED "settings.js" configuration file located here /root/.node-red/ has a special area where you can configure HTTPS and enable it. The procedure is described for examole on this web page: https://notenoughtech.com/home-automatio...o-nodered/
What I see in the source code of the Node-RED container's build file at https://github.com/HilscherAutomation/ne...Dockerfile is that the lines 98 to 110 are taking care of the settings.js file modification to enable HTTPS handling and also the generation of a self signed certificate and keys.
All relevant files are created in the container folder /root/.node-red/certs. The CA file, the private and the public key. The most relevant file for you is the /root/.node-red/certs/node-cert.pem file. This file is needed on your remote machine to tell it to trust the HTTPS site of this Node-RED instance. It is a text file and you can copy and paste its contents to a cert file on your remove machine and include it in the trusted list of certificates.
I see the following possibilities:
a.) You could use netPIs Docker web UI and click on the running container and use the embedded console function to "jump" into the container and output the /root/.node-red/certs/node-cert.pem file on the screen using the Linux command "cat /root/.node-red/certs/node-cert.pem". Then you can copy the content.
b.) You could fork the container's source code and remove the lines from 98 to 110 and the Node-RED will not more be secured during containers build process. I don't know how familiar you are with building your own container image.
c.) You could call the curl command with the option "-k" to let it trust also untrusted self signed certificates
Thx
„You never fail until you stop trying.“, Albert Einstein (1879 - 1955)