Installing Flux

This guide describes the installation procedure for Flux on both Windows and Unix/Linux Operating Systems.

Clear your browser cache!

If you had used the Flux Designer and Flux Operations Console on previous versions of Flux, make sure you clear the web browser cache and restart your web browser before using a new version of Flux.

Windows

To install Flux on Windows, follow these steps:

  1. (If you are installing Flux from the ZIP archive) Navigate to the Flux directory and edit the file setenv.bat located there. Find the line:
    set JAVA_HOME=<Java home>
    

    Make sure that <Java home> is set to one of the following:

    • The location of your Java installation directory (like C:\path\to\java), or
    • %JAVA_HOME%, if your JAVA_HOME environment variable is already set.
  2. (If you are installing Flux from the ZIP archive) While in the Flux directory, run the configure.bat script. This script will configure all the files necessary for Flux to launch the Operations Console web application.
  3. (If this is not an evaluation version of Flux) Install the license key as described in License Keys.
  4. (Optionally) Follow the steps described in Configuring Flux to run with Databases to connect Flux to your enterprise database.

That’s it! Flux is now installed and ready to run using the .bat scripts included in the Flux installation directory. There, you can find scripts for starting unsecured engines, secured engines, The Flux Designer, and the Flux Operations Console (the Flux web application).

If this is your first time using Flux, the quick start guides located in /doc/quick_start_guides under your Flux installation directory are a great place to get started learning about Flux, and the best ways to use and interact with each of its components.

Installing Flux as a Windows Service

.bat scripts for installing Windows services are included in /service/windows under your Flux installation directory. To install a particular Flux component as a service, simply navigate to this directory and run the installation script for that service (for example, to install the unsecured engine service, you would run the install-unsecured-flux-engine-service.bat script).

In addition, each service includes a .conf file for configuring the service. These .conf files provide information like the location of the engine configuration file (for engine service scripts), and the name and location of the wrapper log file where standard out and standard error from the service will be directed.

These .conf files also specify the name and description of the services as they will appear in the Windows service console. You can change this information by editing the following lines in the file:

wrapper.ntservice.name=
wrapper.ntservice.displayname=
wrapper.ntservice.description=

Installing the Flux Agent as a Windows Service

To install the Flux agent as a service, you must first edit the .conf (configuration) file for the agent service to point to the correct engine (these files can be found in the service/windows directory). The configuration settings for agents are supplied in the lines that look like:

wrapper.app.parameter.<number>=<value>

Each configuration option is supplied on two lines; the first line specifies the name of the configuration property (with a “-“ symbol before the property name), while the second line specifies the value. So, for example, to specify the configuration file that should be used to configure the agent, you could set:

wrapper.app.parameter.2=-configurationfile
wrapper.app.parameter.3=<path\to>\\agent-config.properties

The numbers on these lines are sequential, so if you add or remove a configuration option, it is necessary to update the numbers for all of the subsequent wrapper.app.parameter.<number> values to remain in order.

You will need to supply the same set of parameters for both the “start” and “dispose” commands for the agent. Your configuration file will end up containing parameters that look something like:

wrapper.stop.conf = agent.stop.conf
wrapper.app.parameter.1 = agent-server
wrapper.app.parameter.2 = -configurationfile
wrapper.app.parameter.3 = <path\to>\\agent-config.properties
wrapper.app.parameter.4 = start

Your agent stop configuration will end up containing parameters that look something like:

wrapper.app.parameter.1=agent-client
wrapper.app.parameter.4=dispose
wrapper.stopper = true
include=agent.conf

Next, you’ll want to edit your agent configuration file (agent-config.properties) according to the configuration settings in Flux Agents. You may, for example, need to edit the file to specify a host where the engine is running, a username / password to connect to the engine, port usage settings, or other configuration options.

Once the configuration is set, you can install the agent service by running install-flux-agent-service.bat.

Unix / Linux

To install Flux on Unix or Linux, follow these steps:

  1. Download and install the Flux ZIP archive to your system.
  2. (If your environment does not have a JAVA_HOME system environment variable set) Navigate to the Flux directory and edit the file setenv.sh located there. Find the lines:
    #JAVA_HOME=$JAVA_HOME
    #export JAVA_HOME
    

    Remove the “#” symbol from the start of each line, and change the $JAVA_HOME parameter to the location of your Java installation. This might look something like:

    JAVA_HOME=/path/to/java/home
    export JAVA_HOME
    
  3. Edit the /etc/hosts file on the system as described in Installing License Keys on Unix / Linux.
  4. (If this is not an evaluation version of Flux) You should have a license key file for your version of Flux (if you don’t, contact support@flux.ly to request one). Install the license key as described in License Keys.
  5. Make sure the Flux installation folder has the permissions needed to run as described in Database and File System Permissions.
  6. (Optionally) To enable persistent storage of workflows and data, follow the steps described in Configuring Flux to run with Databases to connect Flux to a database.

That’s it! You are now ready to run Flux using the .sh scripts included in the Flux installation directory. There, you can find scripts for starting unsecured engines, secured engines, The Flux Designer, and the Flux Operations Console (the Flux web application).

If this is your first time using Flux, the quick start guides located in /doc/quick_start_guides under your Flux installation directory are a great place to get started learning about Flux, and the best ways to use and interact with each of its components.

Installing Flux as a Unix or Linux Service

You can find .sh scripts for several Flux services (unsecured engine, secured engine, web application, and agent) located in /service/unix under your Flux installation directory.

These scripts can be installed as a service using standard techniques for your particular Operating System. If you are not familiar with the service installation procedure for your OS, you may find the following link useful:

Installing the Flux Agent as a Unix or Linux Service

Before you can install the Flux agent as a service, you will need to edit the script (flux-agent.sh) to correctly locate your Flux engine.

To do so, locate the following two lines in the file:

nohup su $USERNAME -c "$JAVA_CMD flux.Main agent-server -configurationfile <path/to>/agent-config.properties start"
su $USERNAME -c "$JAVA_CMD flux.Main agent-client -configurationfile <path/to>/agent-config.properties dispose"

Next, you’ll want to edit your agent configuration file (agent-config.properties) according to the configuration settings in Flux Agents. You may, for example, need to edit the file to specify a host where the engine is running, a username / password to connect to the engine, port usage settings, or other configuration options.

Once this file has been appropriately modified, install the agent service as described above.

Installing Flux in an Application Server

You can install Flux as a servlet in an application container as well. For more information, see the /examples/software_developers/servlet directory under your Flux installation directory. This example directory includes sample code for creating Flux as a servlet, as well as a script to package the servlet as a WAR file (which you can then deploy to your application server using standard techniques for that container).

This method of installation is recommended for advanced users only and requires knowledge of Java code for configuring and creating the Flux engine.