Running Custom settings.js in node-red container

I am trying to run a custom settings.js on my N-R docker contrainer. I tried couple of methods, but non of it is working.

  1. tried to copy and replace the exisiting "settings.js" to the /data directory in the container

  2. created a volume and saved the new "settings.js" in the volume and tried to run the container using
    "sudo docker run -it -p 1880:1880 -v avolume:/data mynode-red"

  3. tried to use "--settings" to specify my new settings file in the run command
    "sudo docker run -it -p 1880:1880 -v avolume:/data --settings settings.js mynode-red" (the settings
    .js is copied to the work directory in the container )

    can someone tell me how to fix it.
    because everythime i run the node-red the default settings.js is being run inside the /data directory.
    You can see my Dockerfile below

What is wrong with letting node-red create the settings file in your /data volume then just changing it? As I understand it the standard node-red docker build uses the data volume as the userDir folder so other than it is on a different volume, there should be no difference to normal running?

I tried that, once the node-red creates the setting file in the volume and i tried making changes to that setting file. but when i run the container it keeps updating the setting files to the default one. everytime i run the container i have to manually copy my settings file to the /data dir to replace the default setting file and restart the container.

I don't think it should be doing that. @dceejay or @Steve-Mcl - any ideas?

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.