ENTRE EM CONTATO
Documentação
A Liferay oferece um armazenamento rico em recursos e fontes para ajudar nossa comunidade a usar e trabalhar melhor com a nossa tecnologia.
Deploying in production
In production or pre-production environments it's often not possible to use Ant to deploy web applications. Also, some application servers such as WebSphere or Weblogic have their own deployment tools and it isn't possible to use Liferay's autodeploy process. This section describes two methods for deploying and redeploying Ext plugins in production that can be used in each of these scenarios.
Method 1: Redeploying Liferay's web application
This method can be used in any application server that supports auto deploy, such as Tomcat or JBoss. Its main benefit is that the only artifact that needs to be transferred to the production system is the .war file which the Ext plugin produced using the ant war target, which is usually a small file. Here are the steps that need to be executed on the server:
Redeploy Liferay. To do this, follow the same steps you used when first deploying Liferay on the app server. If you are using a bundle, you can just unzip the bundle again. If you've installed Liferay manually on an existing application server, you'll need to redeploy the .war file and copy the global libraries to the appropriate directory within the application server. If this is the first time the Ext plugin is deployed, you can skip this step.
Copy the Ext plugin .war into the auto deploy directory. For a bundled Liferay distribution, the deploy folder is in the root folder.
Once the Ext plugin is detected and deployed by Liferay, restart the Liferay server.
Method 2: Generate an aggregated WAR file
This method can be used for application servers that do not support autodeploy, such as WebSphere or Weblogic. Its main benefit is that all Ext plugins are merged before deployment to production, so a single .war file will contain Liferay plus the changes from one or more Ext plugins. Before deploying the .war file, you'll need to copy the dependency .jars for both Liferay and the Ext plugin to the global application server class loader in the production server. This location varies from server to server; please see the Liferay Portal Administrator's Guide for further details for your application server.
To create the aggregated .war file, deploy the Ext plugin first to the Liferay bundle you are using in your development environment (using for example, Tomcat). Once it's deployed, restart the server so that the plugin is fully deploy and shut it down again. Now the aggregated file is ready. Create a .war file by zipping the webapps/ROOT folder of Tomcat. Also, copy all the libraries from the lib/ext directory of Tomcat that are associated to all the Ext plugins to your application server's global classpath, as noted above. These steps will be automated with Ant targets in the next version of Liferay, but for now, they need to be done manually.
Once you have the aggregated .war file follow these steps on the server:
Redeploy Liferay using the aggregated WAR file.
Stop the server and copy the new version of the global libraries to the appropriate directory in the application server.