Prometheus笔记-设置Basic_auth登录校验
密码是采用bcrypt加密
创建web.yml配置文件
basic_auth_users:
# 密码生成地址:https://www.bejson.com/encrypt/bcrpyt_encode/,格式为 [ 用户名:密码 ]
admin: $2y$10$wUvMZwoFs4/PFTZAAysAGe.c5gSqU9.9DHinCtG3ec83e9fSeuoBi
校验配置
promtool.exe check web-config web.yml
# 出现以下内容就代表配置格式正确
# web.yml SUCCESS
重启Prometheus
prometheus.exe --config.file=prometheus.yml --web.config.file=web.yml
本文来自博客园,作者:Jruing,转载请注明原文链接:https://www.cnblogs.com/jruing/p/17164063.html