#
# 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.4/mod/core.html#options
# for more information.
#
options -indexs +followsymlinks
#
# allowoverride controls what directives may be placed in .htaccess files.
# it can be all, none, or any combination of the keywords:
# allowoverride fileinfo authconfig limit
#
allowoverride all
require all granted
#
# controls who can get stuff from this server.
#
# onlineoffline tag - don't remove
require local
说明:
options -indexs +followsymlinks把'+indexs'修改为'-indexs'代表不允许访问文件目录;
require all granted此行是后来加上的,加上后就可以远程访问。