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
Kubernetes を利用したデプロイ自動化基盤
Search
ktr
May 20, 2017
Technology
0
910
Kubernetes を利用したデプロイ自動化基盤
ktr
May 20, 2017
Tweet
Share
More Decks by ktr
See All by ktr
Monorepo における Go テストの差分実行 / Running Differential Go Tests in a Monorepo
ktr_0731
0
100
Designing libraries in Go way
ktr_0731
6
1.5k
Go Modules and Proxy Walkthrough
ktr_0731
8
27k
ソフトウェアの複雑さに立ち向かう技術 / Tackling software complexity
ktr_0731
0
180
Fuzzy finder as a Go library
ktr_0731
3
5.7k
つよくてニューゲーム / NewGame++
ktr_0731
0
950
やはり俺の Go アプリケーション設計はまちがっている。 / My Go Application Design Is Wrong, As I Expected
ktr_0731
13
3.5k
GopherCon2018
ktr_0731
2
1.8k
Evans: more expressive gRPC client
ktr_0731
2
460
Other Decks in Technology
See All in Technology
GoogleのAIエージェント論 Authors: Julia Wiesinger, Patrick Marlow and Vladimir Vuskovic
customercloud
PRO
0
150
embedパッケージを深掘りする / Deep Dive into embed Package in Go
task4233
1
210
Building Scalable Backend Services with Firebase
wisdommatt
0
110
Docker Desktop で Docker を始めよう
zembutsu
PRO
0
170
シフトライトなテスト活動を適切に行うことで、無理な開発をせず、過剰にテストせず、顧客をビックリさせないプロダクトを作り上げているお話 #RSGT2025 / Shift Right
nihonbuson
3
2.1k
I could be Wrong!! - Learning from Agile Experts
kawaguti
PRO
8
3.4k
2024年活動報告会(人材育成推進WG・ビジネスサブWG) / 20250114-OIDF-J-EduWG-BizSWG
oidfj
0
230
Bring Your Own Container: When Containers Turn the Key to EDR Bypass/byoc-avtokyo2024
tkmru
0
860
【JAWS-UG大阪 reInvent reCap LT大会 サンバが始まったら強制終了】“1分”で初めてのソロ参戦reInventを数字で振り返りながら反省する
ttelltte
0
140
今年一年で頑張ること / What I will do my best this year
pauli
1
220
2024AWSで個人的にアツかったアップデート
nagisa53
1
110
東京Ruby会議12 Ruby と Rust と私 / Tokyo RubyKaigi 12 Ruby, Rust and me
eagletmt
3
870
Featured
See All Featured
The Pragmatic Product Professional
lauravandoore
32
6.4k
Testing 201, or: Great Expectations
jmmastey
41
7.2k
For a Future-Friendly Web
brad_frost
176
9.5k
Building Applications with DynamoDB
mza
93
6.2k
Six Lessons from altMBA
skipperchong
27
3.6k
Making Projects Easy
brettharned
116
6k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.8k
Automating Front-end Workflow
addyosmani
1366
200k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
98
18k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.9k
Measuring & Analyzing Core Web Vitals
bluesmoon
5
210
Transcript
Kubernetes Λͬͨ σϓϩΠࣗಈԽج൫ @A(izu)LT ձฤ 0x02
$ whoami • ੨ଠ (@ktr_0731) • ρ s123 • Web
• STEINS;GATEɺڹ͚ʂϢʔϑΥχΞϜ
ڥ • ਓ͕͋·Γଟ͘ͳ͍ձࣾ • WebɺαʔόɺϞόΠϧ͝ͱʹϦϙδτϦ͕ ͔Ε͍ͯΔ • खಈϏϧυɾσϓϩΠ
ڥ • ਓ͕͋·Γଟ͘ͳ͍ձࣾ • WebɺαʔόɺϞόΠϧ͝ͱʹϦϙδτϦ͕ ͔Ε͍ͯΔ • खಈϏϧυɾσϓϩΠ
ڥ • ਓ͕͋·Γଟ͘ͳ͍ձࣾ • WebɺαʔόɺϞόΠϧ͝ͱʹϦϙδτϦ͕ ͔Ε͍ͯΔ • खಈσϓϩΠ
ςετڥͷσϓϩΠ ʹ͕͔͔࣌ؒΔ
ςετڥͷσϓϩΠ ʹ͕͔͔࣌ؒΔ ↓ ࣗಈԽͷඞཁੑ
ཁૉ • Slack Bot • CI αʔό • Docker •
Kubernetes
Docker • (େࡶʹ͍͏ͱ) ڥΛίϯςφԽ͢Δٕज़ • Docker ΠϝʔδʹΞϓϦέʔγϣϯΛೖΕͯ ଞʹґଘΛٴ΅ͣ͞ʹಈ͔ͤΔ • Immutable
Infrastructure
• a.k.a. k8s • Docker ίϯςφͷΦʔέετϨʔγϣϯπʔϧ • ΫϥελϦϯά • ίϯςφ܈ͷىಈɺఀࢭɺϨϓϦέʔγϣϯ
• 1ͭҎ্ͷ Docker Πϝʔδ͔Β Pod Λ࡞ • ֤ Node ʹࢄͯ͠ஔ
• namespace ͰڥΛ͚Δ͜ͱ͕Ͱ͖Δ • ͲͷڥʹσϓϩΠ͢Δ͔ߟ͑Δඞཁ͕ͳ͍
• namespace ͰڥΛ͚Δ͜ͱ͕Ͱ͖Δ • ͲͷڥʹσϓϩΠ͢Δ͔ߟ͑Δඞཁ͕ͳ͍ • Ͳ͜Ͱಈ͍͍ͯΔ͔ߟ͑ͳͯ͘ྑ͍
• namespace ͰڥΛ͚Δ͜ͱ͕Ͱ͖Δ • ͲͷڥʹσϓϩΠ͢Δ͔ߟ͑Δඞཁ͕ͳ͍ • Ͳ͜Ͱಈ͍͍ͯΔ͔ߟ͑ͳͯ͘ྑ͍ • Ͳ͏ಈ͍͍ͯΔ͔͚ͩߟ͑Εྑ͍
αʔϏεͷެ։ apiVersion: v1 kind: Service metadata: name: sample-server labels: name:
sample-server spec: type: LoadBalancer ports: - port: 80 protocol: TCP targetPort: 8080 selector: name: sample-server
αʔϏεͷެ։ • type=LoadBalancer Ͱ LB ͕࡞͞ΕɺΞϓ Ϧέʔγϣϯ͕ެ։͞ΕΔ • AWS ͳͲͷαϙʔτ͞ΕͨҰ෦ͷΈ
• kubernetes/ingress
σϓϩΠʹඞཁͳઃఆϑΝΠϧ • service.yaml (͖ͬ͞ͷઃఆ) • deployment.yaml • ϨϓϦΧͷࢦఆ • Pod
ͷߏͷهड़
$ kubectl create -n test -f service.yaml $ kubectl create
-n test -f deployment.yaml
ཁૉ • Slack Bot • CI αʔό • Docker •
Kubernetes
Slack Bot • ChatOps • ୭ͰςετڥʹσϓϩΠ͕Ͱ͖Δ
None
Ұ࿈ͷྲྀΕ • Bot ʹσϓϩΠΛ͑Δ • CI ͕σϓϩΠϞʔυͰಈ͘ • CI ্Ͱ
Kubernetes ͷσϓϩΠεΫϦϓτ Λ࣮ߦ • σϓϩΠྃ
Ұ࿈ͷྲྀΕ • Bot ʹσϓϩΠΛ͑Δ • CI ͕σϓϩΠϞʔυͰಈ͘ • CI ্Ͱ
Kubernetes ͷσϓϩΠεΫϦϓτ Λ࣮ߦ • σϓϩΠྃ
՝ • ݱࡏςετڥͷΈͷ༻ • ͍ͣΕϓϩμΫγϣϯڥͰ͍͍ͨ • ݟ͕ཷ·͍ͬͯͳ͍ • k8s ͷجຊ֓೦Δඞཁ͕͋Δ
·ͱΊ • Kubernetes • ෳͷಠཱͨ͠ڥΛ࡞Ͱ͖Δ • Ͳ͜Ͱಈ͍͍ͯΔ͔Λߟ͑ͣʹࡁΉ • k8s ͰσϓϩΠ͕ࣗಈͰͰ͖ΔΑ͏ʹͳͬͨ
ࢀߟ • https://speakerdeck.com/koudaiii/number- devsumie • Wantedly TechBook #2
Thanks for your attention!