PingAuthorize

Variable substitution using manage-profile

You can use the manage-profile tool to substitute different variables in server profiles.

The manage-profile tool uses the format ${VARIABLE} to support the substitution of variables in profiles. To escape this format, use another $. For example, after substitution, $${VARIABLE} becomes ${VARIABLE}.

Variable values can be read from a profile variables file or from environment variable values. If both options are used, the values in the file overwrite any environment variables.

The following lines provide an example of how you can set user-defined variables by using a variables file in the server profile.

HOSTNAME=testserver.example.com
PORT=389

The following table describes built-in variables that you can also reference in the server profile. Use these variables in the format previously described.

Built-in variable Description

PING_SERVER_ROOT

Evaluates to the absolute path of the server’s root directory

PING_PROFILE_ROOT

Evaluates to the individual profile’s root directory

[NOTE] ==== Use PING_PROFILE_ROOT only with files that are not needed after initial setup, such as password files in setup-arguments.txt. Do not use the PING_PROFILE_ROOT variable for files needed while the server is running. The manage-profile tool creates a temporary copy of the server profile that is deleted after the tool completes, so files are not accessible under PING_PROFILE_ROOT when the server is running. For files you need while the server is running, such as keystore and truststore files, copy the files into the server root using the profile’s server-root/pre-setup directory, and then refer to the files using with the PING_SERVER_ROOT variable. ====

For more information about the tool’s usage, run the command bin/manage-profile --help.