File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -49,17 +49,17 @@ The image below shows an instance with the following environment variables:
4949Standard environment variables are set for all Node-RED instances running
5050within the platform:
5151
52- - ` FF_INSTANCE_ID `
53- - ` FF_INSTANCE_NAME `
54- - ` FF_INSTANCE_URL `
52+ - ` FF_INSTANCE_ID ` - The unique identifier of the instance
53+ - ` FF_INSTANCE_NAME ` - The name of the instance as set in FlowFuse
54+ - ` FF_INSTANCE_URL ` - The full URL of the instance (e.g. ` https://my-instance.flowfuse.cloud ` )
5555
5656In addition, the following variables are set when running on a device:
5757
58- - ` FF_DEVICE_ID `
59- - ` FF_DEVICE_NAME `
60- - ` FF_DEVICE_TYPE `
61- - ` FF_SNAPSHOT_ID `
62- - ` FF_SNAPSHOT_NAME `
58+ - ` FF_DEVICE_ID ` - The unique identifier of the device
59+ - ` FF_DEVICE_NAME ` - The name of the device as set in FlowFuse
60+ - ` FF_DEVICE_TYPE ` - The device type label assigned in FlowFuse
61+ - ` FF_SNAPSHOT_ID ` - The unique identifier of the snapshot currently deployed to the device
62+ - ` FF_SNAPSHOT_NAME ` - The name of the snapshot currently deployed to the device
6363
6464When deploying the same set of flows out to multiple devices, these variables can
6565be used by the flows to identify the specific device being run on.
Original file line number Diff line number Diff line change @@ -318,8 +318,8 @@ module.exports = {
318318 let customHostname
319319 if ( app . config . features . enabled ( 'customHostnames' ) ) {
320320 const projectURL = URL . parse ( project . url )
321- const hostnameSetting = project . ProjectSettings ?. filter ( setting => setting . key === KEY_CUSTOM_HOSTNAME ) || [ ]
322- customHostname = hostnameSetting [ 0 ] ?. value ? `${ projectURL . protocol } //${ hostnameSetting [ 0 ] . value } ` : undefined
321+ const hostnameSetting = project . ProjectSettings ?. find ( setting => setting . key === KEY_CUSTOM_HOSTNAME )
322+ customHostname = hostnameSetting ?. value ? `${ projectURL . protocol } //${ hostnameSetting . value } ` : undefined
323323 }
324324
325325 const result = [ ]
You can’t perform that action at this time.
0 commit comments