1 . httpd.conf文件中 添加 listen [port], 有几个添加几条
2. httpd.conf文件中 添加 include conf/extra/httpd-vhost.conf
3. httpd-vhost.conf 文件中, 添加
<VirtualHost *:8080>
ServerAdmin admin@localhost
DocumentRoot "D:/WorkSpace/p2p/Merchant/public"
ServerName www.p2p.com
ServerAlias p2p
ErrorLog "logs/dummy-host.example.com-error.log"
CustomLog "logs/dummy-host.example.com-access.log" common
<Directory "D:/WorkSpace/p2p/Merchant/public">
#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs/2.2/mod/core.html#options
# for more information.
#
Options Indexes FollowSymLinks
#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
#
AllowOverride all
#
# Controls who can get stuff from this server.
#
# onlineoffline tag - don't remove
Order Deny,Allow
# Deny from all
Allow from all
</Directory>
</VirtualHost>
4. 提示没有权限 修改httpd.conf 文档
<Directory />
#AllowOverride none
#Require all denied
Options Indexes FollowSymLinks
AllowOverride None
</Directory>