I'm running node-red under Docker. I'm trying to use the filesystem for my global context. My node-red volume is mounted to :/data:Z
I've set my settings.js as...
contextStorage: {
storeInFile: {
module: "localfilesystem",
config: {
dir: "/data/.node-red",
base: "context",
cache: false
}
},
default: { module: "memory" }
},
If I issue...
global.set("test", "Hello world", "storeInFile");
... I am unable to retrieve this value using global.get("test");
If I bash to my docker instance, I see a folder /context
under /data
(not under /.node-red
). If I browse to /data/context/global and cat global.json I see...
{
"test": "Hello world"
}
What gives? What am I doing wrong? It acts like it's writing to one path /data/context/global
but trying to read from another /data/.node-red/context/global
.