nginx 主要配置文件 /etc/nginx/nginx.conf
启动时 会加载 /etc/nginx/conf.d 文件夹下的所有以 .conf 结尾的配置文件
所有 在/etc/nginx/conf.d 下创建 static.conf 文件
server {
listen 80;
server_name localhost;
location /soft {
root /opt/;
autoindex on; #开启索引功能
autoindex_exact_size off; #关闭计算文件确切大小(单位bytes),只显示大概大小(单位kb、mb、gb)
autoindex_localtime on; #显示本机时间而非 GMT 时间
}
}
来源:CSDN
作者:大头圆
链接:https://blog.csdn.net/hao5511555/article/details/104258745