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
Jenkinsで伺かしてみる
Search
matuyuji
April 05, 2013
Technology
0
5.4k
Jenkinsで伺かしてみる
SSP(伺か)とその通信プロトコルであるSSTPを用いて、JenkinsからSSPへのビルド失敗時の通知などを行います。
matuyuji
April 05, 2013
Tweet
Share
More Decks by matuyuji
See All by matuyuji
Emacs × Touch Bar
matuyuji
2
1.7k
ARKit + SceneKitでMinesweeperを作ってみた
matuyuji
1
770
Go + QtでiOS アプリ開発
matuyuji
0
380
@_specialized なお話し
matuyuji
0
470
Xcode Souce Code Extensionを使ってみた
matuyuji
0
350
Codebeatを 試してみた
matuyuji
0
730
React Nativeで UIコンポーネントをつくる
matuyuji
0
990
React Nativeを使ってみた
matuyuji
0
1.3k
SwiftでLens
matuyuji
1
940
Other Decks in Technology
See All in Technology
DUSt3R, MASt3R, MASt3R-SfM にみる3D基盤モデル
spatial_ai_network
3
450
ハイテク休憩
sat
PRO
2
190
ガバナンスを支える新サービス / New Services to Support Governance
sejima1105
1
840
10年もののバグを退治した話
n_seki
0
130
メンタル面でもつよつよエンジニアになる/登壇資料(井田 献一朗)
hacobu
0
160
スケールし続ける事業とサービスを支える組織とアーキテクチャの生き残り戦略 / The survival strategy for Money Forward’s engineering.
moneyforward
0
210
プロダクト組織で取り組むアドベントカレンダー/Advent Calendar in Product Teams
mixplace
0
630
Oracle Base Database Service 技術詳細
oracle4engineer
PRO
6
54k
AWS re:Invent 2024 ふりかえり勉強会
yhana
0
670
生成AIによるテスト設計支援プロセスの構築とプロセス内のボトルネック解消の取り組み / 20241220 Suguru Ishii
shift_evolve
0
150
開発生産性向上! 育成を「改善」と捉えるエンジニア育成戦略
shoota
2
810
C++26 エラー性動作
faithandbrave
2
870
Featured
See All Featured
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
29
940
GraphQLとの向き合い方2022年版
quramy
44
13k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
1
150
Faster Mobile Websites
deanohume
305
30k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
45
2.3k
Adopting Sorbet at Scale
ufuk
74
9.1k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2k
Designing for humans not robots
tammielis
250
25k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
111
50k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
A better future with KSS
kneath
238
17k
Transcript
JenkinsͰ ͔ ͯ͠ΈΔ @matuyuji 2013.4.9 ୈ3ճ Jenkinsେࡕษڧձ 134݄5༵ۚ
͓ͬ͞Μͱձ͍ͨ͠ Ϗϧυ͕յΕ·ͨ͠ ͲΕ? (Πϝʔδը૾) ͜ΕͰ͢ ͓͍ͯͨ͠ Ϗϧυ͓͖ͯ͠·͢Ͷ 134݄5༵ۚ
Agenda γεςϜߏ SSP/SSTPʹ͍ͭͯ Jenkins࿈ܞ ͦͷଞ & ·ͱΊ Jenkinsͷ΄ͱΜͲ͋Γ·ͤΜ 134݄5༵ۚ
ࣗݾհ @matuyuji safx-dev.blogspot.jp 134݄5༵ۚ
SSPΞϓϦ ΰʔετ γεςϜߏ 134݄5༵ۚ
σεΫτοϓϚείοτ ِϖϧιφΣΞ Կ͔ɻ(Ծ) → ͔ SAKURA Script Player → SSP
ِྛޝ (Mac OS X 10.6·Ͱ) 134݄5༵ۚ
ΰʔετ Jenkins Hudson 134݄5༵ۚ
γεςϜߏ Jenkins SSP SomeProject NotifyWithSSTP Ghost SSTP Ghost 134݄5༵ۚ
SSTPϓϩτίϧ SakuraεΫϦϓτ SSP/SSTP ʹ͍ͭͯ 134݄5༵ۚ
ΒͤΔ ϙʔτ9801ʹจࣈྻΛૹΓࠐΉ $ cat notify NOTIFY SSTP/1.1 Charset: UTF-8 Sender:
Jenkins-Server Script: \0Ϗϧυʹࣦഊ͠·ͨ͠ɻ\e $ nc 127.0.0.1 9801 < notify SSTP/1.1 200 OK 134݄5༵ۚ
Demo 134݄5༵ۚ
SakuraεΫϦϓτ \0 ϝΠϯΩϟϥΫλΛࢦఆ \1 αϒΩϟϥΫλΛࢦఆ \v ΰʔετΛશ໘ʹҠಈ \w# ΣΠτ \s#
αʔϑΣε ද มߋ \_a[] ΞϯΧʔ࡞ \q[] ࣭࡞ ΄͔ɺͨ͘͞Μ 134݄5༵ۚ
දΛม͑Δ 0: ૉ 1: রΕ 2: ڻ͖ 3: ෆ҆ 4:
མͪࠐΈ 5: ඍসΈ 6: ด͡ 7: ౖΓ 8: ྫྷস 9: রΕౖΓ 134݄5༵ۚ
SSTP IANAͷRegistered Port Numbersʹొ͋Γ sstp-1 7743/tcp Sakura Script Transfer Protocol
sstp-1 7743/udp Sakura Script Transfer Protocol sstp-2 9801/tcp Sakura Script Transfer Protocol-2 sstp-2 9801/udp Sakura Script Transfer Protocol-2 134݄5༵ۚ
Jenkinsͱͷ ࿈ܞ 134݄5༵ۚ
Jenkins → SSP SomeProject NotifyWithSSTP Parameterized Trigger plugin 134݄5༵ۚ
\0\v\s4\f[height,36]...Ϗϧυʹࣦഊ͠·ͨ͠ɻ \w9\s7\![move,300,0,1000,me]\![move,-300,0,1000,me] \s0\1\f[height,24]\ͤɻ\n \_a[${UPSTREAM_BUILD_URL}]${UPSTREAM_JOB_NAME}\_a\e 134݄5༵ۚ
ΰʔετͷߏ MacͰಈ͔͢ ͦͷଞ 134݄5༵ۚ
ΰʔετͷߏ Shiori Event OnBoot OnAITalk Shiori.dll ཬʑ YAYA (C-like) ը૾ͷఆٛ
ணͤସ͑ Ξχϝʔγϣϯ shell ghost 134݄5༵ۚ
MouseDoubleClick_0Head { ! "\1\s[10]\0\s[0] \![execute,http-get,http://127.0.0.1:8080/job/ AlwaysFailed/build?token=foobar] ಄ΛμϒϧΫϦοΫ͞ΕͨͷͰɺϏϧυΛ։࢝͠·͢ɻ\e" } ΠϕϯτఆٛϑΝΠϧʹهड़ Πϕϯτ
$ nc -l 127.0.0.1 8080 GET /job/AlwaysFailed/build?token=foobar HTTP/1.1 Host: 127.0.0.1:8080 User-Agent: SSP/2.2.99 (20130204-14; Windows NT 5.1) Accept-Encoding: gzip,deflate Connection: close Accept-Charset: utf-8,* Accept: text/*,*/* 134݄5༵ۚ
ಠࣗΠϕϯτ OnBuildFailed { "\0\vϏϧυʹࣦഊ͠·ͨ͠ɻ\1ͳΜͱ͔͠Ζ\e" } $ nc 127.0.0.1 9801 <<EOF
NOTIFY SSTP/1.1 Sender: Jenkins-Server Event: OnBuildFailed EOF SSTP/1.1 200 OK ΠϕϯτఆٛϑΝΠϧʹهड़ 134݄5༵ۚ
ڥม MouseDoubleClick_1 { ! "\0ࢲͷ໊લ%selfnameͰ͢ɻ\n ࠓ %month ݄ %day Ͱ͢ɻ\e"
} 134݄5༵ۚ
Mac্ͰSSPΛಈ͔͢ ॳճىಈ࣌ͳͲʹਅͬ ࠇʹͳΔͷΛ͙ JenkinsͷσϑΥϧτγΣϧΛzshʹ͢Δ ($JOB_NAME͕ͳ͔ۭͥʹͳΔରࡦ) എܠΛಁաʹ 134݄5༵ۚ
·ͱΊ 134݄5༵ۚ
·ͱΊ SSPΛར༻ͯ͠JenkinsͷΰʔετΛ࡞ͨ͠ JenkinsͷϏϧυࣦഊΛ௨Ͱ͖ΔΑ͏ʹͨ͠ 134݄5༵ۚ
ࢀߟࢿྉ SSP: http://ssp.shillest.net/ YAYA: http://emily.shillest.net/ayaya/index.php UkaDoc: https://ukadoc.googlecode.com/svn/ trunk/manual/index.html 134݄5༵ۚ
͓͠·͍ 134݄5༵ۚ