虚拟主机,apache2和aws无法访问

时间:2014-06-23 13:51:32

标签: php apache magento ubuntu amazon-web-services

使用ubuntu 14:04服务器在aws中创建了一个实例,安装并配置了我的apache2虚拟主机,如下所示:

<VirtualHost *:80>
ServerAdmin webmaster@localhost
    ServerName magento.com
    ServerAlias www.magento.com
    DocumentRoot /var/www/magento.com/public_html

    <Directory />
            Options FollowSymLinks
            AllowOverride None
    </Directory>
    <Directory /var/www/magento.com/public_html>
            Options Indexes FollowSymLinks MultiViews
            AllowOverride None
            Order allow,deny
            allow from all
    </Directory>
<VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@localhost
    ServerName recomendador.com
    ServerAlias www.recomendador.com
    DocumentRoot /var/www/recomendador.com/public_html

    <Directory />
            Options FollowSymLinks
            AllowOverride None
    </Directory>
    <Directory /var/www/recomendador.com/public_html>
            Options Indexes FollowSymLinks MultiViews
            AllowOverride None
            Order allow,deny
            allow from all
    </Directory>
<VirtualHost>

我的档案在:

/var/www/magento.com/public_html/
/var/www/recomendador.com/public_html/

我的/ etc / hosts:

127.0.0.1 localhost
127.0.0.1 magento.com
127.0.0.1 recomendador.com

当我访问我的aws时:

http://meu_ip/

当我访问时打开magento:

http://meu_ip/recomendador.com

http://meu_ip/www.recomendador.com

此服务器上未找到显示。

如果我输入:

http://meu_ip/magento.com

http://meu_ip/www.magento.com

也就是说,似乎他只识别magento,但仍然没有使用ServerName或ServerAlias。

我启用了a2ensite

任何人都知道可能出现的问题?

由于

0 个答案:

没有答案