Running GateIn on your machine

Let's assume that you have correctly configured GateIn as shown in the previous recipes or are using the default settings found in the standard binary package. Now we are going to run GateIn for the first time.

Getting ready

Locate the bin folder of your application server; this is the location where the start/stop script is stored in your machine. Here are the details for the scripts in different application servers:

  • If you are using Tomcat then you have a specific script gatein.sh, for Windows gatein.bat, provided in the binary folder <TOMCAT_HOME>/bin
  • For JBoss AS 6 you can use the standard run.sh script available in this folder <JBOSS6_HOME>/bin
  • JBoss AS 7 requires using the script standalone.sh stored here <JBOSS7_HOME/bin>

How to do it...

Supposing that we are using Linux as the operating system, we would follow these steps:

  1. To start GateIn using Tomcat use the following command line from the current bin folder:
    ./gatein.sh start
    
  2. Once the command above executes, you can take a look at the log file with the following command:
    tail –f ../logs/catalina.out
    

    Now you can start using the portal, pointing your browser at http://localhost:8080/portal.

  3. If the first deployment of GateIn finishes without errors we expect to see in the browser the following homepage of the default portal:
    How to do it...
  4. In order to stop the GateIn instance use the following command line:
    ./gatein.sh stop
    

How it works...

GateIn is distributed as a standard Java EE application that needs to be deployed in an application server.

In this recipe, we have seen how to start and stop a Tomcat instance by using a specific script file provided by GateIn developers.

For each specific application server you must follow the correct procedure to use the dedicated script file to start and stop the portal instance.

There's more…

We will take a look at how to start GateIn with different versions of JBoss application servers.

Starting GateIn with JBoss AS 6 instance

If you are using GateIn with JBoss AS 6, you have to use the following command line:

nohup ./run.sh & 

Then you can access the log file in the following way:

tail –f nohup.out

To stop the instance you can use the following command line:

./shutdown.sh -S

Starting GateIn with JBoss AS 7 instance

Otherwise, if you are using JBoss AS 7 use the following command line:

nohup ./standalone.sh &

The log file can be viewed in this way:

tail –f nohup.out

To stop the JBoss 7 instance run the following command:

./jboss-cli.sh –connect command=:shutdown

See also

  • The Configuring the content storage recipe
  • The Configuring GateIn to send e-mails recipe
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.12.166.131