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の活用事例とCI高速化/circleci-community-meetup3-...
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
bungoume
April 23, 2019
Technology
1.6k
3
Share
CircleCIの活用事例とCI高速化/circleci-community-meetup3-speedup
bungoume
April 23, 2019
More Decks by bungoume
See All by bungoume
djangocongressjp2023_password_hash
bungoume
2
1.6k
日経電子版でのDjango活用事例紹介 / djangocongressjp2022-nikkei
bungoume
4
7k
Password Hashing djangocongress 20180519
bungoume
5
4.2k
OSSで始めるセキュリティログ収集/oss-securitylog-builderscon2017
bungoume
29
11k
日経電子版のアプリ開発を支えるログ活用術/nikkei-log-201609
bungoume
1
1.4k
Kibanaで秒間1万件のアクセスを可視化した話/nikkei-kibana-loganalyst2015
bungoume
20
17k
uwsgi-docker-pycon2015
bungoume
10
60k
Ansibleを結構使ってみた/ansible-nikkei-2015
bungoume
32
15k
Dynamic Inventoryと参照変数
bungoume
2
5k
Other Decks in Technology
See All in Technology
大学生が本気でDatabricksを活用してDiscordサークルをデータ駆動させてみた
phantomjuju
1
270
Oracle AI Database@Google Cloud:サービス概要のご紹介
oracle4engineer
PRO
6
1.5k
Dynamic Workersについて
yusukebe
1
410
ポスター発表&デモと総括 / Poster Presentations & Demonstrations and Summary
ks91
PRO
0
150
美味しいスイスチーズを作ろう🧀🐭
taigamikami
1
140
インフラが苦手でも大丈夫! 紙芝居 Kubernetes -WWGT 10周年編-
aoi1
1
300
権限管理設計を完全に理解した
rsugi
2
230
Datadog 認定試験の概要と対策
uechishingo
0
180
大規模災害時でも高い信頼性を維持するアプリケーション基盤の実現/nikkei-tech-talk46
nikkei_engineer_recruiting
0
110
なぜハノーバーメッセに行くべきなのか 〜初参加だから語れること〜
tanakaseiya
0
170
サプライチェーンセキュリティの空白地帯 - 信頼できる”依存性”の未来を考える
rung
PRO
1
270
Agentic AI時代における メルカリのAIガバナンスとガードレール実装
naoichihara
16
17k
Featured
See All Featured
How to make the Groovebox
asonas
2
2.2k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.2k
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.8k
How Software Deployment tools have changed in the past 20 years
geshan
0
34k
First, design no harm
axbom
PRO
2
1.2k
A Tale of Four Properties
chriscoyier
163
24k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
62k
Navigating Weather and Climate Data
rabernat
0
200
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
How STYLIGHT went responsive
nonsquared
100
6.1k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
1
330
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.5k
Transcript
ຊܦࡁ৽ฉࣾ ക࡚ ༟ར $JSDMF$* ϢʔβʔίϛϡχςΟϛʔτΞοϓ
n r . )( iK p A ZUok ,(
- W s P EabC DY , ( Mc htSe l OI
• I • • • C
AWS Elastic Beanstalk AWS Lambda S3 push, merge
300ϦϙδτϦ͕ CircleCIΛར༻ • Unit test • Deploy • E2E test
AWS Elastic Beanstalk ECR push, merge • Unit
test • Deploy • E2E test Docker image Production Standby StandbyʹσϓϩΠ͠ E2E͕௨ͬͨΒSwap 300ϦϙδτϦ͕ CircleCIΛར༻
) ( (
) (
) ( AWS Elastic Beanstalk ECR 1. Spin up 10s
3. Setup remote docker 7s 4. Restore Docker cache 10s 5. Docker build 10s, 150s Production Standby 2. checkout 1s 6. Push Docker image 20~60s 7. Deploy 60s 8. E2E 60s 9. SWAP 8s ॲཧ࣌ؒҰྫͰ͢
• • ։ൃऀͷ࣌ؒΛୣ͏ •
ςετ͕མͪͨͱ͖ͷଛࣦײ͕૿͑Δʢࣗௐʣ • • ͙͢ϦϦʔε͍ͨ͠ͷʹͰ͖ͳ͍ • • CircleCIʹ͓͕͔͔ۚΔ
•
• • • •
• • executor imageʹssh, gitؚ·Ε͍ͯ·͔͢ʁ • Fallback࣌checkout͕େ෯ʹ͘ͳͬͨࣄྫ͋Γ
• . • OrbsΛ͏ͱ؆୯ • 5GB(head1GB)ϦϙδτϦͰ90s -> 60s • .
• ٯޮՌͷέʔε! • ↓5GBͷϦϙδτϦྫ • Cacheͳ͠ • Checkout code: 70-100ඵ • Cache͋Γ • Restoring cache: 73ඵ • Checkout code: 16ඵ • Saving cache: 139ඵ
• • )$! (
• )&"# '% *+
•
, ) ( 1 •
• ! • •
• DockerfileͰ `COPY . /usr/src/app` ͍ͯ͠Δ߹ .dockerignore Λ༻ҙ • deploy_env/ .git/ .circleci/ ͳͲΞϓϦ࣮ߦʹෆཁͳϑΝΠϧؚ͕·Εͯͳ͍͔
, ) (2 R I 1) ) 3 ) -
( . 3 D.1) I • (pull, cache-from) &3 ) ) -.2 • CircleCIʹ࿈བྷͯ͠༗ྉΦϓγϣϯΛ༗ޮʹ
& • 8 : B • 2 1 +, 4
, +5
• (1 ) (1 - )
• 1 , 0 2 : 5
• • C
I • !
• - + .1 0 + • L O
C 9 OK EI RI • U_ aTRI • B 8 B R D
• C I • 5Ҏ͙Β͍͕ඪ • • ֬ೝ͠ͳ͕ΒೖΕ·͠ΐ͏ •