- Introduction
- Administer Local Environment Variables
- Customize System Environment Variables
- Example of an IguanaEnv.txt file
- Environment Variables Defined By Iguana
Introduction
This screen allows you to administer Environment Variables local to this Iguana Server.
Note:
- Changes to System Environment Variables are local to Iguana, the OS System Variables are not updated.
- Environment Variable settings are stored in IguanaEnv.txt in the Iguana install directory.
- To pick up OS changes in System Environment Variables you need to cycle Iguana (e.g., restart the service/daemon).
If you are using a 32 bit version of Windows and LocalSystem for the Iguana Service you may need to restart Windows to pick up changes in System Environment Variables. To remedy this simply change the Iguana service user to another user with Local Administrator rights.
See Example of an IguanaEnv.txt file.
You can use os.getenv in your Lua translator scripts to get the values of environmental variables. This can be a helpful way of changing the behaviour of scripts based on the server they are running on.
Iguana uses environment variables for some of its settings, see Environment Variables Defined By Iguana.
Administer Local Environment Variables [top]
From this screen you can create modify and delete Local Iguana Environment Variables.
- Click Add Variable to Create a local Environment Variable.
- Click on a variable to Modify it.
- Click on the Red X to delete a variable.
The following shortcut keys are available for working with Environment Variables.
Create a Local Environment Variable:
Click Add Variable.
Click Save to create the variable.
Note: ${variable name} can be used to include another variable in the name.
If an environment variable has been modified in Iguana – then using ${system#VAR} shows the original value.
In this case we changed the the OS system variable from Windows_NT to Windows 7, the fact that it is italicized shows that it is changed from the original system value.
As you can see using ${system#OS} shows the original value.
Modify an Environment Variable:
Click on a variable to edit it.
Change the text and click Save.
As you can see the change is also reflected in the DEPT_CAS variable.
Delete an Environment Variable:
Click the Red X to delete a variable.
The DEPT_CAS variable also reflects the deletion.
These shortcut keys are available in the Environment Variables screen:
Shortcut Key | Action Performed |
---|---|
Ctrl+UpArrow | Scroll up |
Ctrl+DownArrow | Scroll down |
Ctrl+Shift+A | Create a new environment variable |
Ctrl+Shift+S | Save environment variable |
Ctrl+Shift+D | Delete environment variable |
Ctrl+Shift+R | Revert environment variable to original value |
Ctrl+Shift+C | Cancel change to environment variable |
Ctrl+Shift+N | Set cursor to Name field |
Ctrl+Shift+V | Set cursor to Value field |
Ctrl+Shift+Space | Edit the environment variable that the cursor is hovering over |
Customize System Environment Variables [top]
From this screen you can create, modify and delete System Environment Variables.
- Click on a variable to Modify it.
- Click on the Orange Circle to mark a variable as deleted and hide it within Iguana.
The following shortcut keys are available for working with Environment Variables.
Modify an Environment Variable:
Click on a variable to edit it.
Modify the value of the variable.
You can use Split to display the variable on multiple lines.
Click Save.
The variable is now italicized, hovering over the name shows the original value.
Mark an Environment Variable as deleted:
To mark as deleted (hide it within Iguana) click the Orange Circle.
The marked variable is shown in strike through text and any local changes are lost.
To show a marked variable click the blue circular arrow and it will revert to the original (system) value.
You can Show or Hide deleted variables using the dropdown in the Control Panel on the right.
If we choose to Mark the first two system variables as deleted.
We can hide the deleted variables:
Or show only the deleted variables:
Example of an IguanaEnv.txt file [top]
This example explains the contents of this IguanaEnv.txt file.
The CommonProgramFiles System Environment Variable has been modified. The file path “;D:\Program Files\Common Files” has been appended.
The DEPT_CAS Local Environment Variable was created and uses the ${variable} syntax to include the value of the HOSPITAL variable.
The HOSPITAL Local Environment Variable was created with a value of “Foxton General Hospital”
The OS System Environment Variable has been modified to hold a value of “Windows 7”.
The CommonProgramFiles(x86) System Environment Variable has been marked as deleted (and hidden in Iguana).
Environment Variables Defined By Iguana [top]
Iguana defines the following environment variables:
- iguana_dir, which specifies the directory in which Iguana is installed;
- chameleon_dir (defined for Windows only), which specifies the directory in which Chameleon is installed, if it is installed on this computer.
In addition, Iguana defines the CHM_PYTHON_LIB_PATH environment variable if it is not already defined. This variable specifies the location of the Python libraries that ship with Iguana and/or Chameleon. When Iguana is defining CHM_PYTHON_LIB_PATH, the value of this variable is set using the following criteria:
- On Unix, Linux and Mac OS X, CHM_PYTHON_LIB_PATH is set to the python_lib subdirectory of the directory specified by the iguana_dir environment variable.
- On Windows, Iguana checks to see whether Chameleon is installed. If Chameleon is installed, CHM_PYTHON_LIB_PATH is defined to include two directories: the lib subdirectory of the directory specified by the iguana_dir environment variable, and the lib subdirectory of the directory specified by the chameleon_dir environment variable.
- On Windows, if Chameleon is not installed, CHM_PYTHON_LIB_PATH is set to the lib subdirectory of the directory specified by the iguana_dir variable. A log message (of Informational type) notifies you that your Iguana server could not find an installation of Chameleon.
If you have stored custom Python modules in a directory other than those specified in CHM_PYTHON_LIB_PATH, you can edit this environment variable to include the directory in which you have stored the Python modules. See Administer Local Environment Variables for more information on how to edit an environment variable.