To start FlexDeploy server in the background on Windows server, you can use Windows Service. It is similar in concept to a Unix daemon. A Windows service must conform to the interface rules and protocols of the Service Control Manager, the component responsible for managing Windows services. This document explains how to install the Windows Service and configure it to start automatically.
This document covers Tomcat FlexDeploy Server start. Database server need to be started before the FlexDeploy Server.
Step 1: Current FlexDeploy distribution doesn’t come with the Tomcat service out of the box, but it is easy to add. Go to the Apache Tomcat site and download the Windows distribution
URL is currently here: https://tomcat.apache.org/download-90.cgi
Step 2: Unzip the archive and move the following files into <FlexDeploy Home>/apache-tomcat-flexdeploy\bin folder of FlexDeploy distribution( From: C:\apache-tomcat-9.0.37-windows-x64\apache-tomcat-9.0.37\bin to C:\FD56\Tomcat_Complete-188.8.131.52\apache-tomcat-flexdeploy\bin )
Step 3: Open a command line as an administrator and run the command service.bat install from the<FlexDeploy Home>/apache-tomcat-flexdeploy/bin folder
Installing the service 'Tomcat9' ...
Using CATALINA_HOME: "C:\FD56\Tomcat_Complete-184.108.40.206\apache-tomcat-flexdeploy"
Using CATALINA_BASE: "C:\FD56\Tomcat_Complete-220.127.116.11\apache-tomcat-flexdeploy"
Using JAVA_HOME: "C:\Program Files\Java\jdk1.8.0_231"
Using JRE_HOME: "C:\Program Files\Java\jdk1.8.0_231\jre"
Using JVM: "C:\Program Files\Java\jdk1.8.0_231\jre\bin\server\jvm.dll"
The service 'Tomcat9' has been installed.
Step 4: Now you can open the <FlexDeploy Home>/apache-tomcat-flexdeploy/bin/tomcat9w.exe executable to configure the service.
Step 5: Add the following on the Java tab.
a. Set following Java Options
- Please make sure to change C:\FD56\Tomcat_Complete-18.104.22.168 to your FlexDeploy Home.
- Please make sure to change values for-Dflexagon.fd.install.root and -Dflexagon.fd.repository.root as you configured working directory and artifact repository in setup.bat.
- Please make sure no spaces at the end of each line
b. Set the initial memory pool and the maximum memory pool - This will be based on the values that were in the setenv.sh If you had the following:
The minimum would be 1024 and the maximum would be 4096.
c. Add the FDLogFormatter (adjusted to fit the location) to the Java Classpath. Please make sure to change C:\FD53\Tomcat_Complete-22.214.171.124 to your FlexDeploy Home.
Step 6: Start the service using the tomcat8 GUI.
Note: Before starting the Service check DB server running or not, if not started, Start the DB server.
Startup type: Automatic
If you want to start manually keep Startup type: Manual
Step 7: Launch FlexDeploy in your browser to verify.
- Update hostname in URL to indicate host where FlexDeploy is installed.
- Update port in URL.