I'm editing /opt/lampp/etc/extra/httpd-vhosts.conf
I've added VirtualHost directive to this file
<VirtualHost 127.0.0.2:80>
ServerAdmin kirzilla@gmail.com
ServerName rem
DocumentRoot "/home/kir/www/rem/public"
ErrorLog logs/rem-error_log
CustomLog logs/rem-access_log common
<Directory "/home/kir/www/rem/public">
Options Indexes FollowSymLinks Includes execCGI
AllowOverride None
Order Allow,Deny
Allow From All
</Directory>
</VirtualHost>
Then I've created directory /home/kir/www/rem/public 0755 kir:kir
Then I've added 127.0.0.2 rem
to /etc/hosts/
.
Then I've restarted xampp sudo /opt/lampp restart
When I'm trying to enter http://rem
I'm being redirected to http://rem/xampp
As I figured out redirect is produced by file which can be found at /opt/lampp/htdocs/index.php
; this file redirects us to /xampp
directory.
Please help me to figure out why DocumentRoot directive (and, probably other directives too) are ignored and Apache considers /opt/lampp/htdocs
as DocumentRoot.
Thank you.
UPDATED: xampp is running apache2