Setting Environment Variables for Node.js Services
You can only manage the environment variables of Node.js services of the node instance the used Bridge is running on. If you have aggregated multiple node instances into a Bridge domain, you need to use the Bridge of the specific node instance the Node.js service is running on.
Switch to the Environment Variables tab in the information/working area.
Each Node.js service runs with a specific set of environment variables which is provided by the operating system. On this tab you can add, change and remove environment variables for the selected service.
Users with administration rights are allowed to view and modify the environment variables of any Node.js service. Users who are member of a group, to which the role MODELER has been assigned, are only allowed to modify them, if they themselves or a member of the same group deployed the Node.js service. Members of a USERs group may only view the environment variables.
The environment variables of a Node.js service can only be changed, if the service has been stopped before.
Figure: Overview of Tab Environment Variables
The Environment Variables tab is divided into three parts (corresponding to the tasks you can perform):
- Changed Environment Variables (see Change or Add Environment Variables)
- Removed Environment Variables (see Remove Environment Variables)
- Unchanged Environment Variables (see View Unchanged Environment Variables)
View Unchanged Environment Variables
Section Unchanged Environment Variables displays the complete list of environment variables provided by the operating system. By clicking Remove or Change, you can select a variable to be removed or changed.
- Removed environment variables will be moved to section Removed Environment Variables (see Remove Environment Variables).
- Environment variables that are selected for change, are moved to section Changed Environment Variables (see Change or Add Environment Variables).
Environment variables will only be effectively removed or changed as soon as the Apply button is clicked. To indicate this, removed or changed variables are displayed in bold.
Change or Add Environment Variables
Change an Environment Variable
Look-up the environment variable you want to change on the list of unchanged environment variables and click Change. The selected variable will be moved to section Changed Environment Variables.
Now, you can:
- change the value of the variable in column Value.
- remove the changed variable by clicking Remove. The variable then will fall back into the list of unchanged variables.
- reset the variable to the original value, but keep it in the list of changed variables to apply other changes.
Keep in mind that you have to click the Apply button to apply the changes. To indicate this, removed or changed variables are displayed in bold.
Add an Environment Variable
Enter a name in field New Environment Variable and click Add.
The new environment variable is added to the list of changed environment variables. Now, you can:
- change the value of the variable in column Value.
- remove the changed variable by clicking Remove.
You cannot reset the variable, because it is not coming from the set of variables provided by the operating system.
Keep in mind that you have to click the Apply button to apply the changes. To indicate this, removed or changed variables are displayed in bold.
Remove Environment Variables
Environment variables can be removed from the list of unchanged variables or from the list of changed variables. Look-up the environment variable you want to remove on either list and click Remove. The selected variable will be moved to section Removed Environment Variables.
Keep in mind that you have to click the Apply button to finally remove the variables. To indicate this, removed or changed variables are displayed in bold.
- Environment variables coming from the list of unchanged variables will persist in the list of removed variables as they can be reset to their original value.
- Environment variables that had been added manually, will be completely removed.
Now, you can:
- select the removed variable for change by clicking Change. If you have not yet clicked Apply this is also possible for manually created variables that have been removed. This way, you can move them back to the list of changed variables.
restore the removed variable to the original value (coming from the operating system) by clicking Reset. Manually created variables cannot be reset.
Related Pages: