When you create your zpk file with Zend Studio there is a deployment.xml file that specifies some vhost settings as well as various other dependencies and triggers.
If you double click this file within Zend Studio you will be presented with a gui that helps you create this file.
The two fields of importance to this question are "Application directory" and "Document Root". If you have a Zend Framework application the most likely settings for this are:
- Application Directory: data
- Document Root (main public directory): data/public
The document root is the most important part as it defines the directory where apache executes the first file.
You then export the project into a zpk and upload that within Zend Server.
Once uploaded you will be presented with a "Set Installation Details" screen. There you will define the virtual host directory name.
For a simple deployment to your localhost or your server IP you can have the following:
- Display Name: Address App
- Virtual Host: Default
- Path: address
This will then deploy your application to: http://localhost/address or http://192.168.0.*/address
You can also deploy it with a url eg:
- Display Name: Address App
- Virtual Host: click "add new" then enter the url eg. myaddressapp.com
- Path: leave blank
This will then deploy your application to: http://myaddressapp.com. IF you are not deploying to a live site you can fake the url by entering a record in your hosts file
Alternatively, I started writing a blog post a while ago on how to deploy to Zend Server in a VM. This does everything automatically so you dont have to rely on exporting and importing. Here is the work in progress of the post: https://docs.google.com/document/pub?id=1bR58tXWpkezomGiv9cnkySrXxKItoEUQ6E6V9a8n46A