Configuring App Variables with the TIBCO Cloud™ - Command Line Interface

You can late-bind property values for a TIBCO BusinessWorks™ App, Node.js, or TIBCO Flogo® app using the /tibcli app push and tibcli app configure commands. The current values of app properties can be displayed or overridden. System (engine) variables for TIBCO BusinessWorks™ App or apps can also be modified with the ,/tibcli app configure command.

Note: In , App Variables are called App Properties.

The tibcli app configure command prompts you to restart the app with new override values. This enables you to modify properties without pushing and building a new EAR file, speeding up changes for moving from test to production, or changing credentials or other variables.

New application variables for TIBCO BusinessWorks Apps must be added in TIBCO Business Studio™ for BusinessWorks™. For Node.js apps, the tibcli-node tool must be used to modify the manifest, as described in Using Environment Variables in Node.js Apps. Once the app is repushed, the variables display in the Environment controls tab after refreshing the page.

Viewing App Properties

  1. Log in with the CLI as shown in Logging In with the TIBCO Cloud™ - Command Line Interface.
  2. List the app properties for an app using the tibcli app configure -l command. For example, to view the configuration for the app myApp1:
    tibcli app configure -l myApp1
    
  3. List the engine variables for an app using the tibcli app configure --engineVarList command. For example, to view the engine variables for the app myApp1:
    tibcli app configure --engineVarList myApp1
    

Configuring an App

  1. Change the configuration for the app with the tibcli app configure command, specifying overridden app properties in property=value pairs. For example, to override app properties prop1 and prop2 with the values "newval" and "newval2" for myApp1:
    tibcli app configure myApp1 prop1="newval" prop2="newval2"
    
    After issuing the above command, you are prompted to verify if the app should be reconfigured. If you confirm, the overrides are applied and the app is restarted. The verification can be skipped with the -f option.
  2. You can also specify app properties with the --appVar option:
    tibcli app configure --appvar prop1="newval" --appvar prop2="newval2" myApp1
    
  3. Engine variables can be specified with the --engineVar option:
    tibcli app configure --engineVar FLOGO_LOG_LEVEL=WARN myApp1
    

Notes

Using a Properties File

The CLI can be used with a set of app property overrides defined in a file, instead of specifying them in the command line. Note that you cannot change engine variables with a properties file.

For example create a file.properties file such as the following:

prop1="newval" prop2="newval2"

Then use the following command:

tibcli app configure -p file.properties myApp1

Configuring With App Push

You can also configure or reconfigure an app using the tibcli app push command. See the app push command help in the for more details TIBCO Cloud™ - Command Line Interface Reference.

Passwords

For password properties, values are not shown when viewing app properties. Values are displayed as ******.

The password values are encrypted on the server using strong encryption. They can only be used by your app and can not be inspected. You can set password properties by using the BusinessWorks obfuscated format. See below for how to obfuscate passwords.

Obfuscating Passwords

To obfuscate a BusinessWorks password:

  1. Go to <BWCLOUD_HOME>/bwcloud/1.0/bin.
  2. Run bwobfuscator
  3. Type the password and press Enter. An obfuscated password string is given, which can be used in a property value.

Role Requirements

Related Topics

Pushing an App with the TIBCO Cloud™ - Command Line Interface

Using Environment Variables in Node.js Apps

TIBCO Cloud™ - Command Line Interface Reference