Правильные глобальные хосты Apache2 по умолчанию

<VirtualHost _default_:80>
        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/localhost/
        <Directory /var/www/localhost>
                Options Indexes FollowSymLinks
                php_admin_value open_basedir /tmp:/var/www/localhost/
                AllowOverride All
                Require all granted
        </Directory>
        ErrorLog /var/www/logs/localhost-error.log
        LogLevel warn
        CustomLog /var/www/logs/localhost-access.log combined
</VirtualHost>

<VirtualHost _default_:443>
    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/localhost/
    ErrorLog /var/www/logs/localhost-ssl-error.log
    CustomLog /var/www/logs/localhost-ssl-access.log combined

    SSLEngine on

    SSLCertificateFile  /etc/ssl/certs/ssl-cert-snakeoil.pem
    SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key

    <Directory /var/www/localhost>
            Options Indexes FollowSymLinks
            php_admin_value open_basedir /tmp:/var/www/localhost/
            AllowOverride All
            Require all granted
    </Directory>
</VirtualHost>
 21   24 дн  
Популярное