TIBCO Spotfire® Server and Environment - Installation and Administration

Scripting a configuration

For more experienced administrators, Spotfire Server includes two prepared configuration scripts that you can use to set up simple configurations. You can also create and run your own scripts.

  • The simple-config.txt file sets up Spotfire database authentication and the user directory.
  • The simple-config-ldap.txt file sets up LDAP authentication and the user directory.

These scripts are located in the <installation dir>/tomcat/spotfire-bin folder.

Example: The simple-config.txt file

The simple-config.txt file, shown below, is divided into three sections:
  • The first two lines describe how the script is executed.
  • The second section is a list of the variables that are used by the commands.
  • The rest of the script contains the commands.
# Run this script from the command-line using the following command:
# config run simple-config.txt

# Before using this script you need to set the variables below:
set DB_DRIVER = "tibcosoftwareinc.jdbc.oracle.OracleDriver"
set DB_URL = "jdbc:tibcosoftwareinc:oracle://<server>:<port>;SID=\ <SID>"
#set DB_DRIVER = "tibcosoftwareinc.jdbc.sqlserver.SQLServerDriver"
#set DB_URL = "jdbc:tibcosoftwareinc:sqlserver://<server>:<port>;DatabaseName=<database name>"
set DB_USER = "<db username>"
set DB_PASSWORD = "<db password>"
set CONFIG_TOOL_PASSWORD = "<config tool password>"
set ADMIN_USER = "<admin username>"
set ADMIN_PASSWORD = "<admin password>"

echo Creating the database connection configuration
bootstrap --no-prompt --driver-class="${DB_DRIVER}" --database-url=\ "${DB_URL}" \
  --username="${DB_USER}" --password="${DB_PASSWORD}" --tool-password="${CONFIG_TOOL_PASSWORD}"
echo

echo Creating the default configuration
create-default-config
echo

echo Importing the configuration
import-config --tool-password="${CONFIG_TOOL_PASSWORD}" --comment=\ "First config"
echo

echo Creating the '${ADMIN_USER}' user to become administrator
create-user --tool-password="${CONFIG_TOOL_PASSWORD}" --username=\ "${ADMIN_USER}" --password="${ADMIN_PASSWORD}"
echo

echo Promoting the user '${ADMIN_USER}' to administrator
promote-admin --tool-password="${CONFIG_TOOL_PASSWORD}" --username=\ "${ADMIN_USER}"
echo