You can use the various qualities of service of WebSphere® Virtual
Enterprise product to manage PHP-based
applications in addition to Java Platform, Enterprise Edition 5 (Java
EE 5) applications.
Before you begin
- Create a PHP deployment target by creating either a PHP dynamic
cluster or a PHP server. Verify that you can start the deployment
targets. See Creating PHP servers and PHP dynamic clusters
for more
information.
- Prepare your PHP application to be deployed. Your PHP application
consists of an archive file and optional setup or clean-up scripts.
The supported archive file types are zip, tar, tar.gz, tar.tgz and jar.
The optional scripts run for each server on which the application
is deployed. The setup script runs during the application installation,
and the clean-up script runs when you uninstall the application to
remove any residual artifacts. The setup scripts can include commands
such as setting file permissions and creating or deleting directories.
About this task
You can experience the same qualities of service that the
product provides for Java EE 5 applications for PHP applications.
Procedure
- Navigate to the PHP application wizard. In the
administrative console, click Applications > Install new middleware
application. Choose the PHP application type, and click Next.
- Specify the location of the application archive, setup,
and clean-up scripts.
- Specify installation options, including the application
name, edition, and edition description. The application
name must be unique among all of the applications that are deployed
in the cell, including applications that are other types, such as
Java EE 5 or unmanaged Web applications.
- Define the deployment properties of the application.
- Specify the context root and virtual host information
for the application.
- Choose the servers and clusters on which the application
runs by selecting deployment targets. Choose PHP servers or PHP dynamic
clusters. You can filter the list of deployment targets
by only clusters, only servers, or by entering a name. Click Add or Remove to
specify which servers and clusters run the application.
- For an unmanaged Web application with multiple modules,
click Apply to add the module and deployment targets to the
module list.
- Confirm the new PHP application, and save the changes.
The application archive expands and the setup script runs.
- Start the application. With middleware applications,
applications start when you start the PHP server in the administrative
console. Click Servers > Other middleware servers > PHP servers.
Select the servers that you chose as deployment targets, and click Start.
You can also start the application from Applications > All
applications in the administrative console. However, doing so
from this panel will start all the servers associated with this application.
The same rule applies if you stop PHP applications from this panel.
Results
Your PHP application runs on the defined PHP deployment targets.
If you deployed the application to a PHP dynamic cluster, then the
dynamic cluster can add or remove PHP servers as needed.
What to do next
Define service policies and routing policies for the application.
All application edition manager functions are available. When you
roll out a new edition, the clean-up script from the first edition
runs, the application archive of the new edition is expanded, and
the setup script of the new edition runs.
Restriction: Only
one active edition of a PHP application is supported on a node. If
you have multiple active editions of the same PHP application, ensure
that the editions are not deployed to servers that are on the same
node.