I followed Anders Jensen’s tutorial (https://www.youtube.com/watch?v=Zy04eSDy3RI) and implemented the installation of openflow on my VPS server (digital ocean). I also enabled Node-red perfectly.
However, I noticed that node-red is constantly disabled. Is this normal? I saw something about it being turned off every 8 hours, but I thought that wouldn’t happen when the installation was done on my own server.
Either way, I looked for how to purchase the paid plans to avoid this problem and couldn’t find any.
Hey.
Go to Resources and click “Ensure common”.
Reload the website in your browser.
Then go to agents and on each agent, select a “non free” plan for the agent(s) …
this will ensure they do not turn off after 8 hours.
Hmm, sounds like a bug … unless you did not turn off the agent before updating ? ( click stop and then start/play )
Lots of questions about this topic, i think there is an issue in my code somewhere ( also mentioned here Parameter "runtime_hours" )
const resource = await Config.db.GetResource("Agent Instance", parent);
let runtime: number = resource?.defaultmetadata?.runtime_hours;
if (NoderedUtil.IsNullUndefinded(runtime)) {
// If agent resource does not exists, dont turn off agents
runtime = 0;
// If agent resource does exists, but have no default, use 24 hours
if (!NoderedUtil.IsNullUndefinded(resource)) runtime = 24;
}
it did not care about multi tenancy … guess my memory is not as good as I though.
If no agent resource has been added, or if the resource’s default metadata does not have runtime_hours it will stop all instances after 24 hours.
If it exists, it turn them off after runtime_hours hours.
That is not what I intended. Not sure how that ended up being like that.
So i have changed it to this in 1.5.9.17 … I will make 1.5.9 the latest version this week.
So now the code is
const resource: any = await Config.db.GetResource("Agent Instance", parent);
if (NoderedUtil.IsNullUndefinded(resource)) return;
let runtime: number = resource?.defaultmetadata?.runtime_hours;
if (NoderedUtil.IsNullUndefinded(runtime)) {
// If agent resource does not exists, dont turn off agents
runtime = 0;
}
if (runtime < 1) return;
If no agent resource has been added. Do nothing
If agent resource does not have runtime_hours, do nothing
If runtime_hours exists it will turn off the free plan instances after runtime_hours hours.