$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Drone CI
Search
Daisuke Fujita
October 20, 2015
Technology
3
490
Drone CI
社内勉強会で Drone について話した資料です
Daisuke Fujita
October 20, 2015
Tweet
Share
More Decks by Daisuke Fujita
See All by Daisuke Fujita
SREcon19 Asia/Pacific Recap
dtan4
0
150
Our Practices of Delegating Ownership in Microservices World
dtan4
4
8.8k
Kubernetes Cluster Upgrade / Mercari Meetup for Microservices Platform
dtan4
3
4.5k
KubeCon EU 2018 Recap: Multi-Tenancy in Kubernetes: Best Practices Today, and Future Directions / Kubernetes Meetup Tokyo 11 #k8sjp
dtan4
1
1.8k
Wantedly から Chef を一掃した話 / #chibadan
dtan4
24
11k
さようなら Chef こんにちは Dockerfile / Web Tech Tokyo #1
dtan4
6
7k
Docker をフル活用したインフラの紹介と成長し続けるためのインフラ戦略 / #abejameetup
dtan4
19
3.9k
Docker Compose PaaS の作り方、そして社内に導入した話 / #yapc8oji
dtan4
1
8.2k
Writing Kubenetes tools in Go
dtan4
1
3.5k
Other Decks in Technology
See All in Technology
つくってあそぼ! ユビキタス言語作文の紹介
ndadayo
1
140
Reliability Engineering at Studist
katsuhisa91
PRO
0
120
12/2(月)のBedrockアプデ速報(re:Invent 2024 Daily re:Cap #1 with AWS Heroes)
minorun365
PRO
2
310
12/4(水)のBedrockアプデ速報(re:Invent 2024 Daily re:Cap #3 with AWS Heroes)
minorun365
PRO
2
420
Password-less Journey - パスキーへの移行を見据えたユーザーの準備 @ AXIES 2024
ritou
0
200
A/Aテストにおけるサンプルサイズ/japanr2024
nikkei_engineer_recruiting
1
610
ドメインロジックで考えるテスタビリティ
leveragestech
1
280
イベントをどう管理するか
mikanichinose
1
110
アジャイルテストの4象限で考える プロダクト開発の品質への向き合い方
nagano
1
860
【AWS re:Invent 2024】Amazon Bedrock アップデート総まとめ
minorun365
PRO
7
560
密着! Bedrockerがre:Invent 2024で過ごした5日間を紹介
minorun365
PRO
3
300
深層学習のリペア技術の最新動向と実際 / DNN Repair Techniques for AI Performance Alignment for Safety Requirements
ishikawafyu
0
480
Featured
See All Featured
Faster Mobile Websites
deanohume
305
30k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
1.2k
4 Signs Your Business is Dying
shpigford
181
21k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.8k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
45
2.2k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Measuring & Analyzing Core Web Vitals
bluesmoon
4
160
Music & Morning Musume
bryan
46
6.2k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
159
15k
Into the Great Unknown - MozCon
thekraken
33
1.5k
Transcript
Drone CI 2015-10-20 @dtan4 http://www.humanitarianstudies.no/wp-content/uploads/2014/06/drone-sunset.jpg
2छྨͷ Drone CI • Drone.io • CI as a Service
• Drone • OSS • @dtan4 ͕ಋೖ͠Α͏ͱฃಆ͍ͯ͠Δͭ
Drone.io https://drone.io
None
Drone.io • CI as a Service ͱͯ͠ͷ Drone • OSS
ແྉɺPrivate Repository ༗ྉ • GitHub, Bitbucket, Google Code ରԠ • ͖ͳΑ͏ʹςετεΫϦϓτΛ͔͚Δ • ϦϙδτϦϧʔτͷ .yml ͡Όͳ͍… • S3, Heroku, Dotcloud, … ʹσϓϩΠՄೳ https://drone.io/
Drone.io
Drone.io
Drone.io … • ʢͨͿΜʣDocker Βͳ͍ & ͬͯͳ͍ • ͍·Ͳ͖ .yml
ͰεΫϦϓτॻ͚ͳ͍ͷ… • ଞΑΓ͍҆ͱ͍͏Θ͚Ͱͳ͍ • m1.small + Jenkins ΑΓ͍҆ͱ͍͏͚ͩ • ςετΛฒྻʹ͢Δͷ CircleCI ΑΓߴ͍ • Jenkins ͷ͍উखΛΫϥυαʔϏεͰɺ ͱ͍͏ਓ͚ʁ
Drone drone/drone
Drone • OSS ͷ Docker-based CI • Ϗϧυ͝ͱʹಠཱͨ͠ Docker Container
ཱ͕ͭ • DB ͱ͔Ϗϧυ͝ͱʹཱͭ • Drone.io ͷ @bradrydzewski ͕Φʔφʔ • Golang drone/drone
Drone • GitHub, GH:E, Bitbucket, GitLab ʹରԠ • ϦϙδτϦϧʔτͷ .drone.yml
ʹ ςετεΫϦϓτΛॻ͘ • OSS CI ͩͱ Drone ͱ GitLab CI ͘Β͍͔͠ ରԠͯ͠ͳ͍ • Heroku, S3, … ͷσϓϩΠରԠ • Email, HipChat, Slack, … ͷ௨ʹରԠ drone/drone
Jenkins #1 #2 #3 #4
Drone #1 #2 #3 #4
Version of Drone • Version 0.3 (master) • ݱࡏͷ stable
• 1ϲ݄͘Β͍์ஔ͞ΕͯΔ • Version 0.4 (0.4.0) • Ӷҙ։ൃத • .drone.yml ͷޓੑͳ͍ drone/drone
.drone.yml image: ruby:2.2.3 cache: - vendor/bundle env: - RAILS_ENV=test services:
- postgres script: - bundle install -j4 --path=vendor/bundle - bundle exec rake db:test:prepare - bundle exec rspec 0.3 Α͋͘Δ Rails Drone ެࣜΠϝʔδ or ެ։͞Ε͍ͯΔΠϝʔδ ͖͜͜ͳΠϝʔδ͑Δ
.drone.yml cache: mount: - vendor/bundle compose: database: image: postgres:9.4 build:
image: ruby:2.2.3 environment: - DATABASE_USER=postgres - RAILS_ENV=test commands: - bundle install -j4 --path=vendor/bundle - bundle exec rake db:test:prepare - bundle exec rspec 0.4 Α͋͘Δ Rails
ςετը໘ 0.3 Ϗϧυ్தͰ ΩϟϯηϧͰ͖ͳ͍…
ςετը໘ 0.4
Secret Variables • 0.3, 0.4 ͱʹ Web UI ্ͰઃఆՄೳ •
wercker Έ͍ͨʹӅͯ͘͠Εͳ͍ • 0.4 ͩͱ .drone.sec ͱ͍͏ϑΝΠϧʹ҉߸Խͯ͠ ϦϙδτϦʹஔ͚Δ • travis encrypt ͱ ࣅͨײ͡
Docker on Drone • جຊతʹͰ͖ͳ͍ • ςετίϯςφ͕ /var/run/docker.sock Ϛϯτͯ͠ͳ͍ͨΊ •
ଞͷςετίϯςφΛফͤͯ͠·͏ • Docker in Docker ͳΒͰ͖Δ…ʁ (#380) • ߟ͑ͳ͓ͤͱ͍͏هࣄ͋Δ • DOCKER_HOST Λผϗετʹ͚ͯ docker build docker-compose ͢Δͱ͔…ʁ http://jpetazzo.github.io/2015/09/03/do-not-use-docker-in-docker-for-ci/
ॴײ • ࣗલͰ CI ࣋ͭͳΒ͜ΕҰ • Docker ίϯςφͱͯ͠ಈ͔͢ͷ༰қ • ΠϚυΩͷ
CI as a service ͷػೳΛͪΌΜͱ ͑Δ • ·ͩ·ͩ։ൃ్্ • Drone 0.4 ͱ PostgreSQL ͷ૬ੑ͕ѱ͍ • ͍͟ͱͳͬͨΒιʔεಡΜͰͤΔ • OSS! OSS!