bvgcd 发表于 2015-8-21 04:34:27

树莓派安装LAMP配置【2】-虚拟目录设置

  Apache2的配置目录文件是:



/etc/apache2/sites-available/default
  然后sudo nano 编辑(建议先备份)



<VirtualHost *:80>
#    ServerAdmin webmaster@localhost
ServerAdmin root@xxoo.org
#    DocumentRoot /var/www
DocumentRoot /home/pi/wwwroot/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
#    <Directory /var/www/>
<Directory /home/pi/wwwroot/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
  我只是更改了原先的一些配置而已,具体配置直接搜索即可~~包括域名绑定神马的
页: [1]
查看完整版本: 树莓派安装LAMP配置【2】-虚拟目录设置