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
Configurable Slack bot firestarterのつかいかた
Search
Jumpei Takiyasu
February 27, 2018
Technology
0
400
Configurable Slack bot firestarterのつかいかた
https://github.com/juntaki/firestarter
Jumpei Takiyasu
February 27, 2018
Tweet
Share
More Decks by Jumpei Takiyasu
See All by Jumpei Takiyasu
BIRのアーキテクチャと データ処理
juntaki
0
840
BIRのアーキテクチャと 技術選定
juntaki
0
610
ROSでSLAMラジコンをつくる
juntaki
0
3.1k
6足歩行ロボットをつくった
juntaki
0
550
GoでAPIサーバをはやくつくる
juntaki
26
12k
Undocumented!? firebase
juntaki
0
180
3Dプリンタと4足歩行プロトタイプ
juntaki
0
6.4k
アンケートの集計システムを作った
juntaki
0
3k
Goならわかる Linuxのメモリ管理
juntaki
13
6k
Other Decks in Technology
See All in Technology
プログラム検証入門
riru
6
870
プロダクトエンジニアを支えるための開発生産性向上施策
tsukakei
0
140
Creative UIs with Compose: DroidKaigi 2024
chrishorner
1
580
スタッフエンジニアの道: The Staff Engineer’s Path
snoozer05
PRO
44
14k
JEP 480: Structured Concurrency
aya_ebata
0
130
Functional TypeScript
naoya
11
4.8k
Analytics-Backed App Widget Development - Served with Jetpack Glance
miyabigouji
0
610
不動産 x AIことはじめ~データの真価を拓くために
estie
0
110
OSTという文化を組織に根付かせてみた
sansantech
PRO
2
390
GC24 Recap: Interface Internals
task4233
0
140
DroidKaigi 2024 たすけて!ViewModel
mhidaka
5
940
サーバレスでモバイルアプリ開発! NTTコム「ビジネスdアプリ」のアーキテクチャ / The architecture of business d app
nttcom
12
240
Featured
See All Featured
What’s in a name? Adding method to the madness
productmarketing
PRO
21
3k
Building Better People: How to give real-time feedback that sticks.
wjessup
359
19k
Speed Design
sergeychernyshev
22
430
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
502
140k
Visualization
eitanlees
142
15k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
28
1.6k
Building Adaptive Systems
keathley
36
2.1k
Into the Great Unknown - MozCon
thekraken
29
1.4k
Stop Working from a Prison Cell
hatefulcrawdad
267
20k
Rebuilding a faster, lazier Slack
samanthasiow
78
8.6k
The Brand Is Dead. Long Live the Brand.
mthomps
53
38k
Statistics for Hackers
jakevdp
794
220k
Transcript
Configurable Slack bot firestarterのつかいかた @juntaki
Slackでいろいろ実行したいがbotつくるのは面倒 Bot やりたいことは、だいたい 単なるPOSTだけ SlackのAPI / Bot frameworkを調査 Docker化して、デプロイまわりを・・・ POST
“do something”
juntaki/firestarter POST /something firestarter Configurable slack bot with simple Web
UI https://github.com/juntaki/firestarter “do something” Regexp URL template ^do (.*)$ http://jenkins/{{index .matched 1}} ^build (.*)$ http://gitlab/{{index .matched 1}}
システム構成 firestarter(bot) Real Time Messaging Interactive messages firestarter(UI) config.json 社内
API nginx POST 社外 社内
firestarterの仕組み 1. channel名 && regexpでマッチ 2. (選択肢があれば) メニューを出して選択 3. (確認が必要なら)確認メニューを出して選択
4. 設定されたURLへPOSTする POSTのURLとBodyはtext/template、入力は下記 • regexpのマッチ結果(配列) • メニューの選択(文字列)
設定方法 発火条件 応答 POSTリクエスト
firestarterでできること
ふつうのBot “deploy app” と書いたら、appブランチのDeployをはじめる
Interactive Message ブランチ名typoするので、”deploy” で選択肢を出してほしい ※ブランチ一覧は事前にAPIで登録する
Interactive Message + 確認 選択した後に、確認でワンクッション置きたい
つかってみて https://github.com/juntaki/firestarter