printenv from a node-script reports:
PWD=/
_=/usr/bin/printenv
CRED_CFG=/etc/cloud/cloud.cfg.d/91_kernel_cmdline_url.cfg
DOWNLOAD_PATH=/tmp/user_data.sh.P79oJp/scripts/downloads/99-mellaup201
TEMP_D=/tmp/user_data.sh.P79oJp
LANG=C.UTF-8
BIN_D=/tmp/user_data.sh.P79oJp/bin
INVOCATION_ID=a97b2391514048dd931ea7cdba59c91c
RESULT_PATH=/tmp/user_data.sh.P79oJp/out/99-mellaup201.25064/99-mellaup201.yaml
OUTPUT_COMBINED_PATH=/tmp/user_data.sh.P79oJp/out/99-mellaup201.25064/99-mellaup201
OUTPUT_STDOUT_PATH=/tmp/user_data.sh.P79oJp/out/99-mellaup201.25064/99-mellaup201.out
TERM=linux
SHLVL=2
HAS_STARTED=False
OUTPUT_STDERR_PATH=/tmp/user_data.sh.P79oJp/out/99-mellaup201.25064/99-mellaup201.err
RUNTIME=1800
JOURNAL_STREAM=9:51760
PATH=/tmp/user_data.sh.P79oJp/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
DEBIAN_FRONTEND=noninteractive
It would be very helpful to put the address of the applicable Rack Controller into the environment prior to the TEST and/or COMMISSION scripts execute.
More generally, it would be helpful to have a section allowing arbitrary environment variables to be defined. In the GUI, have it be “parallel” to the TEST and COMMISSION scripts section (applying to both). From the CLI, something like node-script environment+=.