Presentation is loading. Please wait.

Presentation is loading. Please wait.

Basic Setup Copyright © 2000-2006 Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission.

Similar presentations


Presentation on theme: "Basic Setup Copyright © 2000-2006 Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission."— Presentation transcript:

1 Basic Setup Copyright © 2000-2006 Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission from Liferay, Inc.

2 Objectives Basic Setup 1. Install Java 2. Install Liferay/Tomcat bundle

3 Why use Tomcat? Tomcat is the fastest server for development of the extension environment. Use Tomcat for development even if you will use a different server for production. Then deploy your code to the other server for periodic testing. Changing servers is easy! Just change the app.server.type. For example, app.server.type=tomcat app.server.type=websphere

4 Tomcat Requirements Java will need to be installed and JAVA_HOME will need to set in order for Tomcat to run. What’s JAVA_HOME? JAVA_HOME is an Environment Variable. You will need to point it to the directory where you installed your JDK. Note: We will go over how to set JAVA_HOME later in the presentation.

5 Uninstall Previous Versions of Java We will be using J2SE 5.0 jdk-1_5_0_08-windows-i586-p.exe It is highly recommended that you uninstall all previous versions of Java even if you need it for another project. Java is easy to install, and you can always reinstall the version of Java that you need after the training session is over. Errors that occur from having multiple versions of Java will cause delays for the entire class.

6 Install Java 1.First let’s create a folder where we will install all Java-related tools: C:\Java 2.Next install J2SE 5.0. Double click jdk-1_5_0_08-windows-i586-p.exe 3.See the next slide for further instructions.

7 1.Install J2SE 5.0 to C:\Java\jdk1.5.0_08\ instead of C:\Program Files\Java\jdk1.5.0_08\ (See below.) 1.Click Next until the installation has finished. C:\Java\jdk1.5.0_08

8 1.Right click My Computer and click Properties  Advanced  Environment Variables 2.Under System Variables click New Make sure you click New under System variables NOT User variables 3.Variable name: JAVA_HOME Variable value: C:\Java\jdk1.5.0_08 Set JAVA_HOME C:\Java\jdk1.5.0_08

9 Checkpoint Verify that JAVA_HOME is correct. C:\Java\jdk1.5.0_08

10 1.Under System Variables click Path then Edit 2.Type %JAVA_HOME%\bin; at the beginning of the Path 3.Don’t forget the semi-colon at the end! Example: %JAVA_HOME%\bin;%SystemRoot%\system 32;%SystemRoot%;%SystemRoot%\System32 \Wbem;C:\Program Files\ATI Technologies\ATI Control Panel; Add JAVA_HOME to the Path

11 1.Click Start  Run… 2.Type cmd and press Enter 3.Type path 4.Make sure that C:\Java\jdk1.5.0_08 is in the Path! 5.Make sure that there is only ONE JDK in your path! Checkpoint

12 Unzip Tomcat 1.Create the following directory structure: C:\Training\liferay\tomcat 2.Locate the Liferay-Tomcat bundle on CD: liferay-portal-tomcat-jdk5-4.1.2.zip 3.What’s the Liferay-Tomcat bundle? It’s just Tomcat pre-configured to run Liferay. 4.Unzip Tomcat (liferay-portal-tomcat-jdk5- 4.1.1.zip) to C:\Training\liferay\tomcat

13 1.Go to C:\Training\liferay\tomcat\bin 2.Double click startup.bat Start up Tomcat

14 Modify the Console Window Right click the Tomcat menu bar and select Properties

15 Modify the Console Window 1.Click the Layout tab 2.Screen Buffer Size Width: 100 Height: 9999 1.Window Size Width: 100 Height: 30 1.Click Save properties for future windows with same title

16 Look at the Console Window! Increasing the window size makes it easier to read the console. Increasing the screen buffer size allows us to see the full error message when an error is thrown. Make it a habit to read what is being displayed in the console even if you do not have an error! By the time we start developing our first portlet, you should know which messages indicate a successful startup and which messages indicate an error. As a developer you MUST learn how to read the console and track down the root cause of an error.

17 Open up your web browser and type http://localhost:8080 You will automatically be redirected to http://localhost:8080/web/guest/home

18 Congratulations! Congratulations! You’ve just set up Liferay Portal! Login: test@liferay.com Password: test To hot deploy JSR-168 compliant portlets, Liferay layout templates, or Liferay themes just drop your *.war files in C:/home/liferay/deploy Sample portlets can be found here: http://www.liferay.com/web/guest/downloads/samples For more information on hot deploy, click here: http://content.liferay.com/4.0.0/docs/developers/ch06s01.html

19 Revision History Edward Shin8/28/2006Updated for Liferay 4.1.1 Mark Wong9/12/2006Updated for 4.1.2


Download ppt "Basic Setup Copyright © 2000-2006 Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission."

Similar presentations


Ads by Google