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
110
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
4
890
マイ隙間家具OSSたちのご紹介
karupanerura
2
250
Mustache Template 話 2024
karupanerura
0
16
1つの言語を原点に色々な言語を学ぶということ
karupanerura
4
2.8k
Javaの実装をPerlでテストする
karupanerura
0
1.1k
Go Generics Overview
karupanerura
0
1.3k
Japan.pm 2021 開催まで至る道
karupanerura
0
2.1k
Perl MongersのためのAWS_CDK入門
karupanerura
0
130
Webシステムのパフォーマンス・チューニング
karupanerura
2
820
Other Decks in Programming
See All in Programming
Amazon CloudWatchの地味だけど強力な機能紹介!
itotsum
0
190
Vibe Coding の話をしよう
schroneko
12
3.2k
Deoptimization: How YJIT Speeds Up Ruby by Slowing Down / RubyKaigi 2025
k0kubun
1
1.4k
20250429 - CNTUG Meetup #67 / DevOps Taiwan Meetup #69 - Deep Dive into Tetragon: Building Runtime Security and Observability with eBPF
tico88612
0
130
Youtube Lofier - Chrome拡張開発
ninikoko
0
2.5k
七輪ライブラリー: Claude AI で作る Next.js アプリ
suneo3476
1
130
設計の本質:コード、システム、そして組織へ / The Essence of Design: To Code, Systems, and Organizations
nrslib
9
3.3k
AIコーディングの理想と現実
tomohisa
33
35k
AHC045_解説
shun_pi
0
560
[NG India] Event-Based State Management with NgRx SignalStore
markostanimirovic
1
170
Making TCPSocket.new "Happy"!
coe401_
1
2.1k
The Nature of Complexity in John Ousterhout’s Philosophy of Software Design
philipschwarz
PRO
0
140
Featured
See All Featured
How STYLIGHT went responsive
nonsquared
100
5.5k
Speed Design
sergeychernyshev
29
910
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
52
2.4k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.2k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
45
9.5k
Reflections from 52 weeks, 52 projects
jeffersonlam
349
20k
Statistics for Hackers
jakevdp
798
220k
Navigating Team Friction
lara
185
15k
Git: the NoSQL Database
bkeepers
PRO
430
65k
Why You Should Never Use an ORM
jnunemaker
PRO
56
9.3k
Documentation Writing (for coders)
carmenintech
69
4.7k
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