Skip to content

3 Installation

DariaPerfilova edited this page Dec 8, 2020 · 22 revisions

3 Installation

Before starting the installation of Sailfish on a computer, make sure that it meets the requirements outlined in section 2. Make sure that MySQL/PostgreSQL and Tomcat servers have been deployed.

3.1 Installation

3.1.1 Linux

  1. Create 2 folders on any disc with a sufficient amount of space: Sailfish/ - it will contain the application itself, and tmp/ – a temporary folder for archives.

  2. Download the Tomcat server (apache-tomcat-8.x.xx or higher, e.g.: apache-tomcat-9.0.24.zip).

  3. Unpack it to the Sailfish folder created in step 1 above.

NOTE!: Please note that Apache Tomcat is not a part of the Sailfish installation archive and should be installed separately. You can download distribution suitable for your OS from here: https://tomcat.apache.org/download-90.cgi.

  1. Download a set of Sailfish installation files – the core distributive for Sailfish and the required plug-ins. (Alternatively, you can request them from GitHub https://github.com/Exactpro/sailfish-core).

Usually, the archive with the core set of files contains the following: DB, Tomcat, Workspace folders and a file named sfgui.war.

  1. Unzip the archive with the core set of files to the tmp/ folder created in step 1 above.

  2. Create folder in <Deployed Tomcat>/webapps/demogui.

  3. Extract the war archive from <tmp>/sfgui.war file to the <Deployed Tomcat>/webapps/demogui folder.

  4. Extract the zipped archive with Sailfish plugins to the <Deployed Tomcat>/webapps/demogui folder.

  5. The <tmp>/DB folder contains different scripts for creating databases. There are ready-made sets of scripts for MySQL and PostgreSQL.

  6. For example, you can choose the create_mysql_db.sh file to define the correct parameters of the database. It may also be required to set up a “superuser” password. You can pass the required options as script arguments (create_mysql_db.sh -superpassword <superuser password> -superuser <superuser name>).

  7. Save the changes to the create_mysql_db.sh file and launch it to create the DB for Sailfish.

NOTE!: This procedure should be performed after each version update of Sailfish before launching the new version of it.

  1. Launch the startup.sh file.

  2. Sailfish GUI will be available via the following link in your browser: http://localhost:8080/demogui.

3.1.2 Windows

If you have the Windows operating system - you will need to run .bat batches instead of .sh ones. All other operations should be the same as in section 3.1.1.

3.2 Sailfish update

  1. Shut down Sailfish by launching shutdown.bat/sh.

  2. Create a back-up folder in Sailfish/.

  3. Back up the files from <Deployed Tomcat>/webapps/demogui folder to the back-up folder (this allows using the current build if a new build has issues).

  4. Download the sfgui.war archive installation file (Alternatively, you can request it from GitHub https://github.com/Exactpro/sailfish-core).

  5. Extract the sfgui.war archive file to the <Deployed Tomcat>/webapps/demogui folder replacing the earlier files.

  6. Start Sailfish by launching startup.bat/sh.

  7. Sailfish GUI will be available via the following link in your browser: http://localhost:8080/demogui/.

3.3 Several Sailfish WEB UIs under one Tomcat

3.3.1 Linux

It’s required to configure a separate demogui folder in the Sailfish/apache-tomcat-8.5.33/webapps folder and configure separate DBs for each Sailfish.

  1. To create a new DB, the create_mysql_db.sh file can be used (see section 3.1. point 8). Update the .sh file with the new DB name (e.g. sailfish2) and execute the .sh file:
  1. Navigate to the Sailfish/apache-tomcat-8.5.33/webapps folder.

  2. Copy the /demogui folder and rename it, e.g. demogui2.

  1. Navigate to the demoqui2/cfg folder and update the hibernate.cfg.xml file as follows:

update the ‘hibernate.connection.url’ section with the corresponding new DB name:

  1. Navigate to the Sailfish/apache-tomcat-x.x.xx/bin/ directory and launch the startup.sh file.

  2. Both Sailfish UIs (demogui and demogui2) will be available in your browser:

demogui - on http://localhost:8080/demogui/

demogui2 - on http://localhost:8080/demogui2/

NOTE!: A restart of Tomcat triggers a restart of all Sailfish applications.

3.3.2 Windows

If you have the Windows operating system - you will need to run .bat batches instead of .sh ones. All other operations should be the same as in section 3.3.1.