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 + peco + tmux + ssh
Search
Yuuki Tsubouchi (yuuk1)
April 27, 2017
Programming
0
8.2k
mkr + peco + tmux + ssh
Mackerel Meetup #10 Tokyo
Yuuki Tsubouchi (yuuk1)
April 27, 2017
Tweet
Share
More Decks by Yuuki Tsubouchi (yuuk1)
See All by Yuuki Tsubouchi (yuuk1)
エンジニアのためのSRE論文への招待 / Introduction to SRE Papers for Engineers
yuukit
1
5.5k
博士課程での研究まとめ 2023年1月版 / Summary of my research in the PhD course
yuukit
1
150
AI時代に向けたクラウドにおける信頼性エンジニアリングの未来構想 / DICOMO2022 6A-1
yuukit
7
2.5k
AIOps研究録―SREのための システム障害の自動原因診断 / SRE NEXT 2022
yuukit
9
11k
Interactive AIOps
yuukit
0
1.8k
Meltria: マイクロサービスにおける 異常検知・原因分析のための データセットの動的生成システム / Meltria in IOTS2021
yuukit
1
1.4k
AIOpsの研究動向と AIOps向けデータセットの動的生成の研究 / Introducing AIOps and A Dynamic Datasets Generating System
yuukit
1
640
分散アプリケーションの高信頼化のための 運用技術に関する研究 / A Study on Operation Technology for High Reliability of Distributed Applications
yuukit
1
700
ネットワークサービスの依存発見に向いた TCP/UDP通信の低負荷なトレース手法 / Low Overhead TCP-UDP Tracing in Kernel
yuukit
5
3.9k
Other Decks in Programming
See All in Programming
Honoとhtmx
yusukebe
6
1.2k
上手な探索的テストとその上達方法について
matsu802
4
650
WinUI 3デモ - "CommunityToolkit.Mvvm"NuGetパッケージ編
andrewkeepcoding
0
130
Why 1 + 1 = 2 in Swift?
1plus4
1
240
Understanding Ast By Looking
inouehi
0
120
品質が高いコードって何?Rev2.1
ickx
1
490
Prepare for Jakarta EE 11 - Performance and Developer Productivity
ivargrimstad
0
480
15分間でふんわり理解するDocker @ Matsuriba MAX
ukwhatn
PRO
1
330
デザインシステムで Tailwind CSSとCSS in JSに分散投資をしたら良かった話
fsubal
14
3k
The Future of C++ Interoperability: Insights from Porting a Game to Swift
teamhimeh
0
260
GitHub Copilot Tips and Tricks
yuichielectric
26
7.4k
ファイル先頭の use の意味、説明できますか? 〜PHP の namespace と autoloading の関係を正しく理解しよう〜 / namespace and autoloading in php
okashoi
2
470
Featured
See All Featured
What's in a price? How to price your products and services
michaelherold
236
11k
Building Better People: How to give real-time feedback that sticks.
wjessup
350
18k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
352
28k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
501
140k
Principles of Awesome APIs and How to Build Them.
keavy
119
16k
The Mythical Team-Month
searls
214
42k
What the flash - Photography Introduction
edds
64
11k
Into the Great Unknown - MozCon
thekraken
10
830
How to Ace a Technical Interview
jacobian
272
22k
Designing for Performance
lara
601
67k
Building a Scalable Design System with Sketch
lauravandoore
455
32k
Debugging Ruby Performance
tmm1
68
11k
Transcript
mkr + peco + tmux + ssh ͯͳ id:y_uuki Mackerel
Meetup #10 Tokyo
αʔϏεɾϩʔϧ໊Λ ͠΅Γ͜Έબͭͭ͠ɺ બΜͩϩʔϧͷϗετ܈ʹ ಉ࣌ϩάΠϯ
αʔϏεɾϩʔϧ໊Λ ͠΅Γ͜Έબͭͭ͠ɺ બΜͩϩʔϧͷϗετ܈ʹ ಉ࣌ϩάΠϯ 5ඵ
http://blog.yuuk.io/entry/tmux-ssh-mackerel
mkr + tmux + ssh
$ mkr hosts —service bookmark --role proxy
$ mkr hosts —service bookmark --role proxy | jq -rM
“.[].name"
tssh = tmux + ssh https://github.com/yuuki/opstools/blob/master/tssh
$ tssh $(mkr hosts —service bookmark --role proxy | jq
-rM “.[].name")
$ tssh $(roles bookmark proxy) (zsh functionԽ)
ͯͳʹϩʔϧ͕ͨ͘͞Μʂ 1000+ roles
ϩʔϧ໊֮͑ͯͳ͍
mkr + peco + tmux + ssh
function peco-mkr-roles() { local selected_role=$(mkr services | jq -rM '[.[]
| .name as $name | .roles // [] | map("\($name) \ (.)")] | flatten | .[]' | peco) if [ -n "${selected_role}" ]; then local BUFFER="tssh \`roles "$ {selected_role}"\`" fi zle clear-screen } zle -N peco-mkr-roles
$ mkr services | jq -rM '[.[] | .name as
$name | .roles // [] | map("\($name) \(.)")] | flatten | .[]' | peco
pecoͰ ϩʔϧͷ͠΅Γ͜ΈΛ͔͚ͨޙ $ tssh $(roles bookmark proxy) Λ࣮ߦ
1. Ctrl + w (ҙ) 2. ϩʔϧҰཡදࣔ 3. ͠΅Γ͜Έબ 4.
tssh࣮ߦ
1. Ctrl + w (ҙ) 2. ϩʔϧҰཡදࣔ 3. ͠΅Γ͜Έબ 4.
tssh࣮ߦ 5ඵ
None
Mackerel API ☓ ͍͍ͭͬͯΔ πʔϧ
Mackerel API ☓ ͍͍ͭͬͯΔ πʔϧ ΤϯδχΞΛ ϫΫϫΫͤ͞Δ