node-red-contrib-cron-plus icon indicating copy to clipboard operation
node-red-contrib-cron-plus copied to clipboard

Environment Variable for cron value

Open Awatatah opened this issue 10 months ago • 2 comments

Hello, we would like to use an environment variable to set the corn value. Is there currently a way to do this? Below is where we want to pass the env var.

image

Awatatah avatar Apr 05 '24 16:04 Awatatah

Just like any other free text field in node-red , you should be able to use ${ENV_VAR}

Docs.

https://nodered.org/docs/user-guide/environment-variables

Steve-Mcl avatar Apr 05 '24 18:04 Steve-Mcl

Failing that, you can setup schedules dynamically. See the built-in examples: ctrl+i ➡️ examples ➡️ node-red-contrib-cron-plus whereby you could use a change node to grab the env var to form a dynamic Cron schedule

Steve-Mcl avatar Apr 05 '24 18:04 Steve-Mcl