配置了个nginx站点,用作研发人员传包用。
在mac主机上安装的,具体步骤就不说了,简单讲下配置文件。
server {
listen 8088;
root /tmp/webroot;
access_log /tmp/web.log;
autoindex on;
charset utf-8;
# auth_basic "password !!"; ####这段是提示输出密码用的
# auth_basic_user_file /usr/local/etc/nginx/servers/htpasswd; ####这段是密码存放位置
}
auth_basic_user_file /usr/local/etc/nginx/servers/htpasswd 格式如下 admin:passwd
autoindex_exact_size on; 显示人类可读的大小
autoindex_localtime on; 显示本地的时间
在线密码生成工具
http://tool.oschina.net/htpasswd
浙公网安备 33010602011771号