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
CircleCIを活用して AWSへの継続的デリバリーを 実践する
Search
coconala_engineer
March 27, 2024
Programming
1
360
CircleCIを活用して AWSへの継続的デリバリーを 実践する
https://trident-qa.connpass.com/event/310009/
のイベントの登壇資料です。
coconala_engineer
March 27, 2024
Tweet
Share
More Decks by coconala_engineer
See All by coconala_engineer
WafCharm導入で激変!プロダクトの未来を守るためのTips
coconala_engineer
0
16
多様なロール経験が導いたエンジニアキャリアのナビゲーション
coconala_engineer
1
220
未来を創るエンジニアを採用・育成するための制度とマインドセット
coconala_engineer
0
37
VPoE Meetup Vol.1 VPoEとして実践してきたことと反省点
coconala_engineer
3
310
エンジニアマネージャーになった理由を振り返ってみた
coconala_engineer
0
510
Developer Experienceを向上させる基盤づくりの取り組み事例集
coconala_engineer
0
220
Vue.jsで入力フォームにリアルタイムハイライト機能を自前実装した話
coconala_engineer
0
72
技術広報経験0のEMがエンジニアブランディングを始めてみた
coconala_engineer
2
250
オンコール運用をほんの少し効率的に行うためのTips
coconala_engineer
0
270
Other Decks in Programming
See All in Programming
競技プログラミングへのお誘い@阪大BOOSTセミナー
kotamanegi
0
360
Mermaid x AST x 生成AI = コードとドキュメントの完全同期への道
shibuyamizuho
1
270
KMP와 kotlinx.rpc로 서버와 클라이언트 동기화
kwakeuijin
0
190
create_tableをしただけなのに〜囚われのuuid編〜
daisukeshinoku
0
290
useSyncExternalStoreを使いまくる
ssssota
6
1.4k
PHPとAPI Platformで作る本格的なWeb APIアプリケーション(入門編) / phpcon 2024 Intro to API Platform
ttskch
0
300
PHPUnitしか使ってこなかった 一般PHPerがPestに乗り換えた実録
mashirou1234
0
330
採用事例の少ないSvelteを選んだ理由と それを正解にするためにやっていること
oekazuma
2
1.1k
各クラウドサービスにおける.NETの対応と見解
ymd65536
0
180
return文におけるstd::moveについて
onihusube
1
1.3k
LLM Supervised Fine-tuningの理論と実践
datanalyticslabo
7
1.5k
Scalaから始めるOpenFeature入門 / Scalaわいわい勉強会 #4
arthur1
1
340
Featured
See All Featured
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
810
Designing for Performance
lara
604
68k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
191
16k
Java REST API Framework Comparison - PWX 2021
mraible
28
8.3k
RailsConf 2023
tenderlove
29
940
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
The Cult of Friendly URLs
andyhume
78
6.1k
Building a Scalable Design System with Sketch
lauravandoore
460
33k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
6
450
Making the Leap to Tech Lead
cromwellryan
133
9k
The World Runs on Bad Software
bkeepers
PRO
66
11k
Transcript
Copyright coconala Inc. All Rights Reserved. CircleCIΛ׆༻ͯ͠ AWSͷܧଓతσϦόϦʔΛ ࣮ફ͢Δ ΠϯϑϥɾSREνʔϜ
TeamManager ٢ݟ
Copyright coconala Inc. All Rights Reserved. 2 ࣗݾհ ٢ݟʢΑ͔͠Θ ͨ͘Έʣ
• ੜ·Ε ੩Ԭ → จܥେֶ͔ΒΤϯδχΞ • ܦྺ ۚ༥SIer → ελʔτΞοϓ → ίίφϥ • झຯ ϥΠϒɾΠϕϯτʹߦ͘
Vision Ϗδϣϯɺϛογϣϯʹج͍ͮͨࣄۀΛల։ νʔϜ͕ߏங͍ͨ͠ͱࢥ ͏࠷ྑͳະདྷͷΠϝʔδ νʔϜ͕ߏங͍ͨ͠ͱࢥ ͏࠷ྑͳະདྷͷΠϝʔδ Mission νʔϜ͕࣮ݱ͍ͨ͠த৺ తͳతʢଘࡏҙٛʣ ҰਓͻͱΓ͕ʮࣗͷετʔϦʔʯΛੜ͖͍ͯ͘ੈͷதΛ࡞Δ
ݸਓͷࣝɾεΩϧɾܦݧΛՄࢹԽ͠ɺ ඞཁͱ͢Δͯ͢ͷਓʹ݁ͼ͚ͭɺ ݸਓΛΤϯύϫʔϝϯτ͢ΔϓϥοτϑΥʔϜΛఏڙ͢Δ ࣝɾεΩϧɾܦݧͷϚονϯάαʔϏεΛల։ ࣄۀ༰ 3
ϚονϯάαʔϏε ֓ཁ 4
Copyright coconala Inc. All Rights Reserved. 5 ΞδΣϯμ • CI/CDͱ
◦ ͳͥඞཁͳͷ͔ • CircleCIͷಛ • ίίφϥͰͷར׆༻ ◦ ͪΐͬͱͨ͠ςΫχοΫ
Copyright coconala Inc. All Rights Reserved. 6 CI/CDͱ
Copyright coconala Inc. All Rights Reserved. 7 CI/CDͱ • ݫີʹCIͱCDผͰ͋Δ͕ɺͻͱ͘͘ΓͰઆ໌͞ΕΔ͜ͱ͕ଟ͍
◦ CIɿܧଓతΠϯςάϨʔγϣϯ ◦ CDɿܧଓతσϦόϦʔ
Copyright coconala Inc. All Rights Reserved. 8 CI/CDͱ • ݫີʹCIͱCDผͰ͋Δ͕ɺͻͱ͘͘ΓͰઆ໌͞ΕΔ͜ͱ͕ଟ͍
◦ CIɿܧଓతΠϯςάϨʔγϣϯ ◦ CDɿܧଓతσϦόϦʔ • ͷͬ͘͘͢͟͝ΓҰݴઆ໌͢Δͱ ◦ CIɿࣗಈςετ ◦ CDɿࣗಈσϓϩΠ ɹ→ Ұ࿈ͷྲྀΕʢύΠϓϥΠϯʣ͕͋Δ
Copyright coconala Inc. All Rights Reserved. 9 ͳͥCI/CDύΠϓϥΠϯ͕ ඞཁͳͷ͔
Copyright coconala Inc. All Rights Reserved. 10 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔
Copyright coconala Inc. All Rights Reserved. 11 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔ ɾϑΥʔϚοτਖ਼͍͠ʁ ɾςετ͞Ε͍ͯΔʁ
ɾϏϧυͰ͖Δʁ
Copyright coconala Inc. All Rights Reserved. 12 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔ ɾϑΥʔϚοτਖ਼͍͠ʁ ɾςετ͞Ε͍ͯΔʁ
ɾϏϧυͰ͖Δʁ ։ൃऀϨϏϡΞʔ ෛ୲͕େ͖͍
Copyright coconala Inc. All Rights Reserved. 13 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔ push͢Δ͚ͩͰࣗಈ࣮ߦ →
݁ՌΛ֬ೝ͢Δ͚ͩͰ OK
Copyright coconala Inc. All Rights Reserved. 14 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔ • ίʔυ࣭ͷ্
◦ खಈ࡞ۀΛ͕શͯࣗಈԽ͢Δ͜ͱʹΑΔώϡʔϚϯϦεΫɾίετͷݮ ◦ ςετϓϩηεΛ௨͢͜ͱʹΑΔόάͷൃݟ • ϦϦʔεαΠΫϧͷߴԽ ◦ ϝΠϯϒϥϯνͷঢ়ଶͰରڥʹϦϦʔε͞ΕΔ
Copyright coconala Inc. All Rights Reserved. 15 ͳͥCI/CDύΠϓϥΠϯΛΉͷ͔ • ίʔυ࣭ͷ্
◦ खಈ࡞ۀΛ͕શͯࣗಈԽ͢Δ͜ͱʹΑΔώϡʔϚϯϦεΫɾίετͷݮ ◦ ςετϓϩηεΛ௨͢͜ͱʹΑΔόάͷൃݟ • ϦϦʔεαΠΫϧͷߴԽ ◦ ϝΠϯϒϥϯνͷঢ়ଶͰରڥʹϦϦʔε͞ΕΔ ɹ ։ൃੜ࢈ੑͷ্
Copyright coconala Inc. All Rights Reserved. 16 CircleCIͱ
Copyright coconala Inc. All Rights Reserved. 17 ଟछଟ༷ͳCI/CDπʔϧ
Copyright coconala Inc. All Rights Reserved. 18 CircleCIͰओʹͰ͖Δ͜ͱ • ੩తղੳʢLintʣ
• ୯ମςετʢTestʣ • ϦιʔεϏϧυʢBuildʣ • ίʔυͷσϓϩΠʢReleaseʣ etc…
Copyright coconala Inc. All Rights Reserved. 19 CircleCIͷಛ 1. ΫϥυαʔϏεͷͨΊ࣮ߦڥΛཧ͢Δඞཁ͕ͳ͍
• ࣗಈϏϧυɺςετΛ࣮ߦ͢ΔͨΊʹαʔόΛ༻ҙ͢Δඞཁͳ͍ ◦ ઃఆϑΝΠϧΛهड़͢Εɺ࣮ߦ͞ΕΔΑ͏ʹͳΔ • ͨͩ͠ηΩϡϦςΟͷ߹্ɺΫϥυNGͱ͍͏߹ ◦ Self Hosted Runner·ͨEnterpriseϓϥϯͰରԠՄೳ 1. ͞·͟·ͳVCSʢόʔδϣϯίϯτϩʔϧγεςϜʣʹରԠ • GithubɺGitLabɺBitbucket • ྫ͑GithubActionsΛ͍͍ͨ߹GithubΛ͍ͬͯΔඞཁ͕͋Δ͕ɺ ɹɹCircleCIͰͦͷΑ͏ͳ੍΄ͱΜͲͳ͍
Copyright coconala Inc. All Rights Reserved. 20 CircleCIͷಛ 3. άάϥϏϦςΟ͕ͳ͔ͳ͔ߴ͍
• 2013ࠒ͔Β಄͍ͯ͠Δ&ݸਓͰແྉར༻ՄೳͳͷͰใ͕๛ • ࠷ۙGithubActions͔... 4. σϑΥϧτͰsshσόοάػೳ͋Γ • ઃఆϑΝΠϧΛهࡌͯ͠ɺ ࢥ͏Α͏ʹಈ͔ͳ͍ͱ͖ʹศར • printσόοάΈ͍ͨͳ͜ͱ͕ෆཁ • GithubActionsͰઐ༻ActionsΛΈࠐΉ ඞཁ͕͋Δ
Copyright coconala Inc. All Rights Reserved. 21 CircleCIͷಛ 5. Insightػೳ
• ϦϙδτϦ͝ͱͷޭɺύΠϓϥΠϯͷ࣮ߦ࣌ؒͷ֓ཁΛ֬ೝͰ͖Δ ◦ Ͳ͕͍͜ͷ͔ɺվળ༨͕͋Δͷ͔͕ҰͰΘ͔Γ͍͢
Copyright coconala Inc. All Rights Reserved. 22 CircleCIͷ֓೦ ύΠϓϥΠϯʢ㲈ϫʔΫϑϩʔʣʢԼਤͦͷͷʣ |–
δϣϒʢԼਤͷϒϩοΫʣ |– εςοϓʢӈਤͷϒϩοΫʣ |– ίϚϯυ
Copyright coconala Inc. All Rights Reserved. 23 CircleCIͷઃఆ yamlϑΝΠϧ1ͭͰ݁ʂ
Copyright coconala Inc. All Rights Reserved. 24 ίίφϥͰͷར׆༻ࣄྫ ͱςΫχοΫ
Copyright coconala Inc. All Rights Reserved. 25 πʔϧ༻ 90%ɹɹɹɹɹɹɹɹɹɹɹɹɹɹɹɹɹ10% ओཁαʔϏεྨͷςετɾσϓϩΠ
ࣾ༻πʔϧɺPRૢ࡞ܥ
Copyright coconala Inc. All Rights Reserved. 26 CircleCIΛ༻͍ͯAWSσϓϩΠ͢Δ ίίφϥͰEC2ɺECSɺLambdaͷσϓϩΠʹCircleCIΛ׆༻ •
developϒϥϯνϚʔδʹΑΓεςʔδϯάɺ masterϒϥϯνϚʔδʹΑΓຊ൪ࣗಈతʹσϓϩΠ͞ΕΔ • CircleCI্ͰLint→test→build→deploy ͕جຊϑϩʔ
Copyright coconala Inc. All Rights Reserved. 27 ͪΐͬͱͨ͠ςΫχοΫ • AWSGCPσϓϩΠ͢ΔͨΊʹΞΧϯτΩʔ͕ඞཁɾɾɾʁ
◦ ͩͬͨͷલ·Ͱͷ ◦ ݱࡏͰOpenIDConnectͱ͍͏ΈͰೝূ͢Δ͜ͱͰΩʔϨε͕Մೳ ◦ ৄ͘͠ϒϩάΛࢀর͍͖͍ͨͩͨ
Copyright coconala Inc. All Rights Reserved. 28 ͪΐͬͱͨ͠ςΫχοΫ • OrbsΛͲΜͲΜར༻
◦ OrbsͱδϣϒίϚϯυΛύοέʔδԽͨ͠ͷ ▪ ຊདྷेߦʹΔίϚϯυͳͲΛγϯϓϧʹهࡌͰ͖Δ ◦ ࣗͨͪઐ༻ʹPrivate OrbΛ࡞͢Δ͜ͱՄೳ ɹɹ ɹ→aws-cliΛར༻͍ͨͨ͠ΊΠϯετʔϧ͍ͨ͠ɻ ɹ ௨ৗwgetʙtarʙmvͳͲهࡌ͢Δඞཁ͕͋Δ͕ ɹ ͜Ε͕ͨͬͨ1ߦʢaws-cli/installʣͰࡁΜͰ͍Δ
Copyright coconala Inc. All Rights Reserved. 29 ͪΐͬͱͨ͠ςΫχοΫ • ςετฒྻԽͯ͠ߴԽ
◦ CI࣮ߦ࣌ؒͷଟ͘ͷׂ߹ΛΊΔͷ͕ςετఔ ◦ CircleCIͰࢄ࣮ߦͷઃఆ͕Մೳ ◦ ৄ͘͠ϒϩάΛࢀর͍͖͍ͨͩͨ ↓ ྻ࣮ߦͰ30͔͔͍ͬͯͨͷ͕τʔλϧ6ఔʹ
Copyright coconala Inc. All Rights Reserved. 30 CircleCIͰ CI/CDύΠϓϥΠϯΛ͑ շదͳ։ൃऀϥΠϑΛʂ
We are hiring!! ࠾༻ϗʔϜϖʔδ https://coconala.co.jp/recruit ΤϯδχΞ࠾༻ϗʔϜϖʔδ https://coconala.co.jp/recruit/engineer ίίφϥͷਓͱ৫Λ͑Δϒϩά ίίφϥLIVE https://blog.coconala.co.jp/m/m4e4abe8b17e5
ਓੜͷՄೳੑΛ͛ͨϢʔβʔετʔϦʔ Θͨ͠ͷεΩϧղ์ه https://blog.coconala.co.jp/m/me8a586112ad2 ίίφϥʹॴଐ͢ΔΤϯδχΞʹΑΔϒϩά ςοΫϒϩά https://zenn.dev/coconala 31