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
Using Heroku on entrusted development
Search
Kusamao Abe
June 22, 2017
Technology
0
1.1k
Using Heroku on entrusted development
2017/6/22 Heroku Meetup #17 Heroku Strikeでお話させていただきました。受託案件でのHeroku運用についてです
Kusamao Abe
June 22, 2017
Tweet
Share
More Decks by Kusamao Abe
See All by Kusamao Abe
Vue builds
kusamao
1
460
Javascript in the past and now
kusamao
1
160
The Essence of UI Design
kusamao
1
1.9k
Make good (better) form
kusamao
0
240
Making mock-up in web application
kusamao
0
78
Keep a distance from jQuery
kusamao
0
110
Other Decks in Technology
See All in Technology
バクラクのドキュメント解析技術と実データにおける課題 / layerx-ccc-winter-2024
shimacos
2
1.2k
サービスでLLMを採用したばっかりに振り回され続けたこの一年のあれやこれや
segavvy
2
550
コンテナセキュリティのためのLandlock入門
nullpo_head
2
330
組織に自動テストを書く文化を根付かせる戦略(2024冬版) / Building Automated Test Culture 2024 Winter Edition
twada
PRO
18
5.5k
Work as an App Engineer
lycorp_recruit_jp
0
360
Oracle Cloud Infrastructure:2024年12月度サービス・アップデート
oracle4engineer
PRO
1
270
最近のSfM手法まとめ
kwchrk
2
160
GitHub Copilot のテクニック集/GitHub Copilot Techniques
rayuron
39
16k
Qiita埋め込み用スライド
naoki_0531
0
5.3k
エンジニアカフェ忘年会2024「今年やらかしてしまったこと!」
keropiyo
0
100
ゼロから創る横断SREチーム 挑戦と進化の軌跡
rvirus0817
3
280
あの日俺達が夢見たサーバレスアーキテクチャ/the-serverless-architecture-we-dreamed-of
tomoki10
0
500
Featured
See All Featured
Unsuck your backbone
ammeep
669
57k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Put a Button on it: Removing Barriers to Going Fast.
kastner
59
3.6k
Six Lessons from altMBA
skipperchong
27
3.5k
It's Worth the Effort
3n
183
28k
Producing Creativity
orderedlist
PRO
342
39k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
17
2.3k
Fireside Chat
paigeccino
34
3.1k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.9k
The Cost Of JavaScript in 2023
addyosmani
46
7k
4 Signs Your Business is Dying
shpigford
182
21k
BBQ
matthewcrist
85
9.4k
Transcript
डୗҊ݅Ͱͷ Herokuӡ༻ 2017/06/22 Heroku Meetup #17 Heroku Strike at Global
Business Hub Tokyo
גࣜձࣾλϯόϦϯWebΤϯδχΞ ҆෦ຑੜʢKusamao Abeʣ 8FCαΠτɾ8FCΞϓϦέʔγϣϯͷϚʔΫΞοϓɺ 41"8PSE1SFTTʢͭΒ͍ʣΛओʹ୲ɻϫΠϠʔ ϑϨʔϜͱ͔σβΠϯΧϯϓʹԆʑͱένΛ͚͕ͭ ͪɻઃܭͱ͔ΠϯϑϥʹटΛಥͬࠐΜͰࣗͷट ΛకΊΔͷ͕ੜۀͰ͢ɻ ࣗݾհ
λϯόϦϯ͜Μͳ੍࡞ձࣾͰ͢ w Πϯϑϥઐۀ͕͍ͳ͍ w ࣾ֎ͷύʔτφʔ͞ΜͱҰॹʹ੍ ࡞͢Δ͜ͱ͕ଟ͍ w Ҋ͔͚͕݅ͪଟ͍ w ৽نӡ༻͢Δ
w εςʔΫϗϧμʔϓϩμΫτϚ ωʔδϟʔ֎ʹ͍Δ͜ͱ͕ଟ͍
ࠓ͓͢Δ͜ͱ w ͜ͷػೳͰ͜͏มΘΓ·ͨ͠ w ͜Μͳӡ༻ͯ͠·͢
ࢦ͢͜ͱ Έͳ͞Μ͕όϯόϯ)FSPLVΛͬͯ ݟΛڞ༗ͯ͘͠ΕΔ͜ͱ
Herokuͱ ϞοΫΞοϓ 01
ϞοΫΞοϓ੍࡞ɺ Α͘Γ·͢
ैདྷ ࣾςετ ڥ master ࣗಈө ࣾςετ ڥ 4'51
ैདྷ ࣾςετ ڥ master ࣗಈө ࣾςετ ڥ 4'51 ˒ ϨϏϡʔͰ͖ͳ͍
˒ ίϯύΠϧͨ͠ίʔυΛόʔδϣϯ ཧ͢Δࠈ ˒ SFWFSUͩΔ͍
ैདྷ ࣾςετ ڥ master ࣗಈө ࣾςετ ڥ 4'51 ˒ ϨϏϡʔͰ͖ͳ͍
˒ ίϯύΠϧͨ͠ίʔυΛόʔδϣϯ ཧ͢Δࠈ ˒ SFWFSUͩΔ͍ ͜ͷੈͷऴΘΓ
ϞοΫΞοϓ੍࡞ w σβΠϯΧϯϓͱ༷ɾઃܭॻ͔Βʮঢ়ଶʯ Λ૾ͨ͠ΓσβΠφʔʹ֬ೝͨ͠Γ͠ͳ͕ Β੍࡞ w ݟ͕ͨΧϯϓ௨ΓͰ͠ΐ͏͕ͳ͍ w ҙ֎ͱ༷ॻಡΈࠐΉ͜ͱʹͳΔ w
͜ͷ͋ͱΈࠐΈΛ͢Δਓͱίϛϡχέʔ γϣϯΛͱΔ w େنͩͱҰਓͰ࡞Γ͖Εͳ͍͜ͱ͋Δ w Ͳ͏͍͏نɾํͰ࡞Δʁ w ୭ʹͲ͜Λ͓ئ͍͢Δʁ w ΫΦϦςΟνΣοΫʁ
Heroku Pipelines IUUQTEFWDFOUFSIFSPLVDPNBSUJDMFTQJQFMJOFT
Heroku Pipelines IUUQTEFWDFOUFSIFSPLVDPNBSUJDMFTQJQFMJOFT
ίʔυϕʔεΛมߋ͢Δͷʹ1VMM3FRVFTUΛग़͢ 13ʹج͍ͯ)FSPLV͕ࣗಈతʹ"QQΛ࡞ͯ͠ɺ มߋΛςετͰ͖ΔΑ͏ʹͳΔ มߋʹ͕ͳ͚ΕNBTUFSϒϥϯνʹϚʔδ͞ ΕΔ NBTUFSϒϥϯνࣗಈతʹεςʔδϯάڥʹ
ө͞Εͯɺߋʹݕূ͞ΕΔ ४උ͕ສશͳΒຊ൪ڥʹQSPNPUFʢঢ֨ʣ͠ ͯɺΤϯυϢʔβʔʹͬͯΒ͏
Heroku Review Apps master feature App: my-mockup AutoDeploy: master
Heroku Review Apps master feature App: my-mockup AutoDeploy: master
Heroku Review Apps master feature App: my-mockup AutoDeploy: master
Heroku Review Apps master feature App: my-mockup AutoDeploy: master App:
my-mockup-pr765 ParentApp: my-mockup
Heroku Review Apps master feature App: my-mockup AutoDeploy: master App:
my-mockup-pr765 ParentApp: my-mockup
Heroku Review Apps master feature App: my-mockup AutoDeploy: master App:
my-mockup-pr765 ParentApp: my-mockup App: my-mockup-pr766 ParentApp: my-mockup
w ίʔυϕʔεϨϏϡʔ(JU)VCͰ w ݟͨΠϯλϥΫγϣϯͷ ϨϏϡʔ3FWJFX"QQͰ
w ΄͔ʹ୭͕࡞ۀͯ͠Δͷ͔ؾʹ͠ ͳͯ͘ྑ͍ w (JU)VCͰNBTUFSϒϥϯνΛ QSPUFDU͢Δ͜ͱͰϨϏϡʔ͢Γൈ ͚NBTUFSQVTIͳͲͷ࣏҆ͷѱ ͍ߦҝΛېࢭͰ͖Δ w ݟͨͷࠩҟΛ֬ೝ͍͢͠
Herokuͱ ϦϦʔε 02
ܧଓతʹʜʜ w ػೳՃ w จݴௐ w ෆ۩߹मਖ਼ w ϦϦʔεࣄނͷϩʔϧόοΫ ˠ͘͘͞͞ϦϦʔε͍ͨ͠
ͱ͋Δ"84Ҋ݅ w εςʔδϯάͱຊ൪͕ଘࡏ w (JU)VCར༻ w ϦϦʔε44)Ͱೖͬͯ $ git pull
origin master
εςʔδϯάʁʁʁ w CSBODIΛΓସ͑ͯ֬ೝ͍ͯ͠Δ w NBTUFSͰͳ͍ϒϥϯνʹ͍Δ࣌ʹ Ͳ͏ͳͬͯΔͷ͔Θ͔Βͳ͍ʢ֬ ೝதʁ͠Εʁʣ w ֬ೝதʹόάमਖ਼ͨͯ͘͠ϫνϟ ϫνϟ
֬ೝڥͨΓͳ͍ʜ
શ෦·ͱΊͯ֬ೝ
ා͍ʂ
ϦϦʔεΛා͕Βͣʹߦ͏ʹʁ w ͪΌΜͱςετͯ֬͠ೝͰ͖Ε ා͘ͳ͍ w ਓඞͣϛεΛ͢Δɻى͜͞ͳ͍ ͷ͕Ұ൪͚ͩͲɺىͬͨ࣌͜ʹ͢ ͙ʹରॲͰ͖ΔΈ͕ඞཁ w ҰճʹυΧοͱΔͱࢮ͕ݦݱ
͔͠͠
͚ࣗͨͪͩͷ ϓϩμΫτ͡Όͳ͍
͓٬༷ͷ߹͋Δ w ֬ೝ͓٬͞Μʹͯ͠Β͏ w ϦϦʔελΠϛϯάίϯτϩʔ ϧ͍ͨͣ͠ w ͖ͤΓ͡Όͳͯ͘ɺڠۀͯͬ͠ ͍͖͍ͯͨ w
ຖϓϩμΫτʹுΓ͍ͯ͘Ε Δʁʁ
IUUQXXXCBDLMPHKQHJUHVJEFTUFQVQTUFQVQ@IUNM ϦϦʔεϒϥϯν
࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά
࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά
ػೳՃ# ࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά
࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά
࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά
࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master ࠩҟ
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master
࣍ճ ຊ൪ εςʔδϯά ػೳՃ$ ࣍ʑճϦϦʔε Քಇத εςʔδϯά release master
Roll back w εφοϓγϣοτͷ3PMMCBDL͕ Մೳɻ͋͘·ͰҰ࣌తʹɻ w σϓϩΠ͞Εͨॱʹͭ͘όʔδϣ ϯ൪߸ͱͦͷ࣌ͷίϛοτϋογϡ ΛνΣοΫͯͦ͠ͷϦϏδϣϯʹ ͤΔ
˞"EEPOTͷঢ়ଶมԽ͠ͳ͍
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: bbbbbbb
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ࣄނ
hash: aaaaaaa hash: bbbbbbb hash: bbbbbbb
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ࣄނ
hash: aaaaaaa hash: bbbbbbb
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ࣄނ
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa मਖ਼
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa मਖ਼
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ ⾠ෆ۩߹
hash: aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc hash: ccccccc
ػೳՃ# ࣍ճ ػೳՃ" ࣍ճϦϦʔε ຊ൪ εςʔδϯά Քಇத εςʔδϯά ࠩҟ hash:
aaaaaaa hash: bbbbbbb hash: aaaaaaa IPUpY hash: ccccccc hash: ccccccc hash: ccccccc hash: bbbbbbb !ccccccc
(JU)VCଆͷઃఆ w NBTUFSQVTIͯ͠ຊ൪ʹө ͞Εͳ͍ͷͰฏ w ߋʹฏҡ࣋Λաܹʹ͢ΔͳΒGPSL ܗࣜʹͯ͠SFMFBTFϒϥϯνΛकΔ
)FSPLVଆͷઃఆ w ຊ൪ڥ͓٬͞Μͱཧऀ͚ͩ ৮ΕΔΑ͏ʹ͢Δ w ΞυΦϯΛ৮͍͍͔ͬͯνΣοΫ w ڥมΛ֬ೝ͠ͳ͍ͱ%#Λ(6* Ͱ͍͡Εͳ͍
࣍ճ ຊ൪ εςʔδϯά Քಇத εςʔδϯά ઌํ୲ऀ ཧऀ ύʔτφʔ σΟϨΫλʔ deploy
or operate Add-ons
IUUQRJJUBDPNMMISLMMJUFNTFCCGCE खલຯḩ Ͱ͕͢
Herokuͱ ςετ 03
CI/CD Continuous Integration Continuous Delivery "HJMF
w ʮ࠷ॳʹ͓͖ͬͯ͘ʯ w ʮ࣭ཧΛ͍εύϯͰʯ w ʮςετ͕௨Βͳ͍ͷϨϏϡʔ ͠ͳ͍ʯ
͍
͍͖ͬͯ·͠ΐ͏
HerokuCI + CircleCI
HerokuCI w ඵͰམͪͯͨʢࠓվળʣ ˠ8FC"1*ͷςετ͕Ͱ͖ͳ͔ͬ ͨ w ϦϙδτϦͷ1VTIʹରԠ࣮ͯ͠ߦɻ 3FWJFXBQQͷൃੜͰͳ͘QVTI Ͱ࡞ w
EZOPΛফඅ w "EEPOTΛ͑Δ
CircleCI w ݁ՌΛ֬ೝ͍ͨ͠ͷʹ(JU)VC0SHT Ͱ0VUTJEF$PMMBCPSBUPSͩͱμϝɻ 0SHBOJ[BUJPO"DDFTT͕ඞཁʁ w ֎෦ͷύʔτφʔ͞ΜΛ.FNCFS ʹ͢ΔͱϦϙδτϦͷӾཡɾ࡞ ΛҰൠʹ։์Ͱ͖ͳ͘ͳΔ w
5FBNͰࣗͨͪͷϝϯόʔ͚ͩ ͷνʔϜΛ࡞ͬͯຖճͦΕΛׂ ΓͯΔํʹมߋ
None
–࡞ۀऀ͍Θ͘ l1)1ͰDJSDMFZNMͱ͔ॻ͘ͷ͍ͨΜʜz
·ͩ·ͩ͜Ε͔Β
ࠓޙ w εϐʔσΟʹ࡞Γ͡ΊΔͨΊͷ ϘΠϥʔϓϨʔτɾࣾυΩϡϝ ϯτ w %PDLFSͲ͏ͳͷ w ͦͦςετΛͪΌΜͱॻͧ͘ FUD
Thank you for your listening!