【筆記】Debian安裝Apache2

本文遷移地址:https://blog.muumlover.com/2016/11/apache2-setup.html

sudo apt-get install apache2 apache2-utils

配置apache端口爲8080

vim /etc/apache2/ports

修改內容如下

# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default.conf

Listen 8080

<IfModule ssl_module>
        Listen 8088
</IfModule>

<IfModule mod_gnutls.c>
        Listen 8088
</IfModule>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet///////

打開apache2的文件訪問功能

vim /etc/apache2/apache2.conf

修改內容如下

<Directory />
        Options FollowSymLinks
        AllowOverride None
#       Require all denied
        Order deny,allow
        allow from all
</Directory>

配置apache2自啓動

chkconfig apache2 2
/etc/init.d/apache2 start
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章