8

使用popeye分析你的k8s集群

 2 years ago
source link: https://www.bboy.app/2022/08/11/%E4%BD%BF%E7%94%A8popeye%E5%88%86%E6%9E%90%E4%BD%A0%E7%9A%84k8s%E9%9B%86%E7%BE%A4/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

使用popeye分析你的k8s集群

2022-08-11kubernetes

20220811-1.webp

Popeye 是一个简单的cli工具可以帮助你分析你集群的潜在问题,并且会进行评分

https://github.com/derailed/popeye

直接使用下面的命令安装

brew install derailed/popeye/popeye

安装完成之后就可以不用加任何参数直接使用

popeye

popeye 支持生成分析报告

POPEYE_REPORT_DIR=$(pwd) popeye --save

默认是txt格式,当然你也可以生成html格式的

POPEYE_REPORT_DIR=$(pwd) popeye --save --out html --output-file report.html

popeye 还支持以下方式的报告

Format Description Default Credits
standard The full monty output iconized and colorized yes
jurassic No icons or color like it’s 1979
yaml As YAML
html As HTML
json As JSON
junit For the Java melancholic
prometheus Dumps report a prometheus scrappable metrics dardanel
score Returns a single cluster sanitizer score value (0-100) kabute

也支持把报告存入s3

popeye --s3-bucket=NAME-OF-YOUR-S3-BUCKET/OPTIONAL/SUBDIRECTORY --out=json

当然也支持自定义扫描的规则

所以你可以使用Popeye去监控你的集群的分数,当分数低于一个评分之后去告警

欢迎关注我的博客www.bboy.app

Have Fun


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK