Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
mkr-check-self あるいはmackerel-agentのサブセットを作る方法
Search
karupanerura
August 23, 2017
Programming
1
96
mkr-check-self あるいはmackerel-agentのサブセットを作る方法
Mackerel User Group Meeting Vol.3
karupanerura
August 23, 2017
Tweet
Share
More Decks by karupanerura
See All by karupanerura
GoでParserを書く
karupanerura
5
770
マイ隙間家具OSSたちのご紹介
karupanerura
2
220
1つの言語を原点に色々な言語を学ぶということ
karupanerura
4
2.7k
Javaの実装をPerlでテストする
karupanerura
0
1k
Go Generics Overview
karupanerura
0
1.2k
Japan.pm 2021 開催まで至る道
karupanerura
0
2k
Perl MongersのためのAWS_CDK入門
karupanerura
0
90
Webシステムのパフォーマンス・チューニング
karupanerura
2
780
WebシステムのパフォーマンスとGo
karupanerura
3
1.6k
Other Decks in Programming
See All in Programming
Jakarta EE meets AI
ivargrimstad
0
100
役立つログに取り組もう
irof
28
9.6k
cmp.Or に感動した
otakakot
3
200
Arm移行タイムアタック
qnighy
0
330
CSC509 Lecture 11
javiergs
PRO
0
180
Contemporary Test Cases
maaretp
0
140
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
480
LLM生成文章の精度評価自動化とプロンプトチューニングの効率化について
layerx
PRO
2
190
みんなでプロポーザルを書いてみた
yuriko1211
0
260
とにかくAWS GameDay!AWSは世界の共通言語! / Anyway, AWS GameDay! AWS is the world's lingua franca!
seike460
PRO
1
880
Why Jakarta EE Matters to Spring - and Vice Versa
ivargrimstad
0
1.1k
WebフロントエンドにおけるGraphQL(あるいはバックエンドのAPI)との向き合い方 / #241106_plk_frontend
izumin5210
4
1.4k
Featured
See All Featured
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
GraphQLの誤解/rethinking-graphql
sonatard
67
10k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
0
97
Code Reviewing Like a Champion
maltzj
520
39k
GraphQLとの向き合い方2022年版
quramy
43
13k
Designing Experiences People Love
moore
138
23k
Being A Developer After 40
akosma
87
590k
For a Future-Friendly Web
brad_frost
175
9.4k
Designing the Hi-DPI Web
ddemaree
280
34k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
890
Bash Introduction
62gerente
608
210k
5 minutes of I Can Smell Your CMS
philhawksworth
202
19k
Transcript
mkr-check-self ͋Δ͍mackerel-agentͷαϒηοτΛ࡞Δํ๏ id:karupanerura Mackerel User Group Meeting Vol.3
mkr-check-self ͱ • mackerel-agentͷઃఆΛΈͯ • checkࢹ߲Λ୳ͯ͠ • ·Δͬͱ࣮ߦ • Ҏ্
DEMO
ͳͥ΄͘͠ͳͬͨͷ͔ • GCPͷIaaSͰ͋ΔGoogle Compute Engine • StackdriverͰͷࢹ͕جຊ • ͍Ζ͍Ζ͋ͬͯmackerel͍ͨ͘ͳͬͨ •
େਓͷࣄͰউखʹొͯͨ͠Ί͠ʹ͍͘ • ͔͠͠ݕূ͍ͨ͠
ͭ͘Γ͔ͨ
mackerel-agent • OSSʹͳ͍ͬͯΔ • configͳͲผύοέʔδʹͳͬͯΔ • ͭ·Γ֎෦ϥΠϒϥϦͱͯ͑͠Δʂ • ͬͨʔʂ
ίʔυ
func main() { kingpin.Parse() logger := log.New(colorable.NewColorableStdout(), "", log.Ldate|log.Ltime| log.LUTC)
conf, err := config.LoadConfig(*conffile) if err != nil { logger.Fatal(err) } ok := true for name, config := range conf.CheckPlugins { checker := checks.Checker{Name: name, Config: config} report := checker.Check() logger.Printf("%s: %s\n", statusColordString(report.Status), color.BlueString(checker.String())) if *verbose { logger.Print(report.Message) } ok = ok && report.Status == checks.StatusOK } if !ok { os.Exit(1) } }
Έ͔͍͡ʂ ͓͕ͯΔʂ
ͨͩ͠ • OSSʹͳ͍ͬͯΔͱ͍͑mackerel-agentͷ தͷύοέʔδ • ϥΠϒϥϦͱͯ͑͠Δ͚ΕͲɺϥΠϒϥ Ϧͱͯ͠ར༻͢ΔͨΊʹެ։͞Ε͍ͯΔΘ͚ Ͱͳ͍ • ͏߹ࣗݾͰݸਓπʔϧ͘Β͍Ͱ
͓͠·͍ :D