美文网首页
apache多端口

apache多端口

作者: 残风疏影 | 来源:发表于2017-07-05 17:33 被阅读0次

touch /etc/apache2/sites-available/packages.conf

vim /etc/apache2/sites-available/packages.conf

Listen 81

<VirtualHost *:81>
ServerAdmin webmaster@localhost

DocumentRoot /mnt/ramdisk
<Directory />
    Options FollowSymLinks
    AllowOverride None
</Directory>

ErrorLog /var/log/apache2/error.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn

CustomLog /var/log/apache2/access.log combined

</VirtualHost>

ln -s /etc/apache2/sites-available/packages.conf /etc/apache2/sites-enabled

vim /etc/apache2/apache2.conf

...

<Directory /mnt>
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
</Directory>

...

service apache2 restart

相关文章

网友评论

      本文标题:apache多端口

      本文链接:https://www.haomeiwen.com/subject/jkiqhxtx.html