php - Debian & apache deploying multiple applications -
i have small problem.
i have 2 applications named appa , appb created using php. deploy them on apache2 server @ same time able test integration between them ( doesn't work). far editing everytime apache virtualhost configuration in
/etc/apache2/sites-enabled/sites.conf
i trying edit hosts creating second *.conf file like:
<virtualhost localhost:80> serveradmin webmaster@example.net servername appa serveralias appa documentroot /var/www/appa </virtualhost> into
<virtualhost localhost/appa:80> serveradmin webmaster@example.net servername appa serveralias appa documentroot /var/www/appa </virtualhost> but apache restart error:
[error] (eai 2)name or service not known: not resolve host name
the main thing can appa on address: localhost if sites-ebabled conf set docummentroot appa , b have change configuration of virtuanlhost
goal have appa under localhost/appa , appb under localhost/appb
i realise have edit dns or host file can me out because i'm out of ideas..
you need 1 virtualhost , many directories:
<virtualhost localhost:80> serveradmin webmaster@example.net servername myserver serveralias myserver documentroot /var/www </virtualhost> alias /appa "/var/www/appa" <directory /var/www/appa> options indexes includes followsymlinks multiviews allowoverride authconfig fileinfo order allow,deny allow </directory> alias /appb "/var/www/appb" <directory /var/www/appb> options indexes includes followsymlinks multiviews allowoverride authconfig fileinfo order allow,deny allow </directory> then access them using
http://localhost/appa or
http://localhost/appb since virtualhost @ port 80.
Comments
Post a Comment