Ngx http autoindex module
来自Linux78|wiki
ngx_http_autoindex_module模块处理以斜线字符('/')结尾的请求并产生目录列表。 当ngx_http_index_module模块找不到索引文件时,通常会将请求传递到ngx_http_autoindex_module模块。
示例配置
location / {
autoindex on;
}
句法:autoindex开启|关闭;
默认:autoindex关闭;
语境:http,服务器,位置
启用或禁用目录列表输出。
句法:autoindex_exact_size 开启| 关闭;
默认:autoindex_exact_size 开启;
语境:http,服务器,位置
对于HTML格式,指定是否应在目录列表中输出精确的文件大小,或者将其舍入为千字节,兆字节和千兆字节。
句法:autoindex_format html | xml | json | JSONP; 默认:autoindex_format html; 语境:http,服务器,位置
设置目录列表的格式。
当使用JSONP格式时,使用callback请求参数设置回调函数的名称。如果参数丢失或具有空值,则使用JSON格式。
XML输出可以使用ngx_http_xslt_module模块进行转换。
句法:autoindex_localtime开启|关闭; 默认:autoindex_localtime关闭; 语境:http,服务器,位置
对于HTML格式,指定是否应该在本地时区或UTC中输出目录列表中的时间。