生成密码
printf "your_username:$(openssl passwd -crypt your_password)\n" >> conf.d/passwd
编辑 Nginx 配置文件
location /
{
auth_basic_user_file conf.d/passwd;
}
printf "your_username:$(openssl passwd -crypt your_password)\n" >> conf.d/passwd
location /
{
auth_basic_user_file conf.d/passwd;
}