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
かびさん@あおかびん
July 11, 2018
Technology
0
890
Kubernetes始めてみた
沖縄・宜野湾エンジニア勉強会(大LT大会) のトーク資料です
https://connpass.com/event/90184/
かびさん@あおかびん
July 11, 2018
Tweet
Share
More Decks by かびさん@あおかびん
See All by かびさん@あおかびん
K8s進捗報告
aokabin
0
350
Okinawa.go Tour of Go! 説明資料
aokabin
0
860
フリーランスの良さ悪さ
aokabin
1
420
2018年LT大会
aokabin
0
120
将来のためのコミュニティ活動
aokabin
0
110
Other Decks in Technology
See All in Technology
DynamoDB でスロットリングが発生したとき_大盛りver/when_throttling_occurs_in_dynamodb_long
emiki
1
450
Exadata Database Service on Dedicated Infrastructure(ExaDB-D) UI スクリーン・キャプチャ集
oracle4engineer
PRO
2
3.2k
CysharpのOSS群から見るModern C#の現在地
neuecc
2
3.6k
Making your applications cross-environment - OSCG 2024 NA
salaboy
0
200
インフラとバックエンドとフロントエンドをくまなく調べて遅いアプリを早くした件
tubone24
1
430
Engineer Career Talk
lycorp_recruit_jp
0
190
SDNという名のデータプレーンプログラミングの歴史
ebiken
PRO
2
120
なぜ今 AI Agent なのか _近藤憲児
kenjikondobai
4
1.4k
【Startup CTO of the Year 2024 / Audience Award】アセンド取締役CTO 丹羽健
niwatakeru
0
1.4k
The Rise of LLMOps
asei
9
1.8k
AGIについてChatGPTに聞いてみた
blueb
0
130
ExaDB-D dbaascli で出来ること
oracle4engineer
PRO
0
3.9k
Featured
See All Featured
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
126
18k
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
Practical Orchestrator
shlominoach
186
10k
It's Worth the Effort
3n
183
27k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
364
24k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
0
110
Done Done
chrislema
181
16k
How GitHub (no longer) Works
holman
310
140k
Scaling GitHub
holman
458
140k
Transcript
Kubernetes࢝ΊͯΈͨ ͔ͼ @d_ishitaka
ࣗݾհ • ͔ͼ͞Μˏੴߴେհ Twitter: @d_ishitaka ԾطࠗऀͰ͢ʂʂ Ծࠗ͠·ͨ͠ʂ • ླྀٿେֶʹฤೖ͖ͯͨ͠4ੜ(3ճ)Ͱ͢ɻ •
ڈ·Ͱٳֶͯͯ͠ϑϦʔϥϯεΤϯδχΞͨ͠ΓɺΞϧόΠτͨ͠Γͯ͠·ͨ͠(ࠓ) • ʮࢦథܳਓʯ • Ϋϥυٕज़͕͖ͰɺJAWSUGͱGCPUGʹΑ͘ߦͬͯ·͢ɻ • ͖ͳݴޠGoͰɺ࠷ۙΑ͘RubyΛॻ͍͍ͯ·͢ɻ • ۤखͳͷԾ௨՟Ͱ͢ɻ
ࣗݾհ
ࣗݾհ • ͔ͼ͞Μˏੴߴେհ Twitter: @d_ishitaka ԾطࠗऀͰ͢ʂʂ Ծࠗ͠·ͨ͠ʂ • ླྀٿେֶʹฤೖ͖ͯͨ͠4ੜ(3ճ)Ͱ͢ɻ •
ڈ·Ͱٳֶͯͯ͠ϑϦʔϥϯεΤϯδχΞͨ͠ΓɺΞϧόΠτͨ͠Γͯ͠·ͨ͠(ࠓ) • ʮࢦథܳਓʯ • Ϋϥυٕज़͕͖ͰɺJAWSUGͱGCPUGʹΑ͘ߦͬͯ·͢ɻ • ͖ͳݴޠGoͰɺ࠷ۙΑ͘RubyΛॻ͍͍ͯ·͢ɻ • ۤखͳͷԾ௨՟Ͱ͢ɻ
ࠓ͢͜ͱ •Kubernetesͱʁ(ͬ͘͞Γ) •Ͳ͏͍͍ͷʁ •͡ΊͯΈͨ •ݱঢ়ɺKubernetesΛऔΓר͘ڥ •·ͱΊ
ࠓճͷͷτʔΫͷςʔϚ Kubernetes
KubernetesͬͯΔਓʁ
ΫόωςεͬͯΔਓʁ
ΫϕϧωςεͬͯΔਓʁ
ΫʔϕϧωΠςεͬͯΔਓʁ
ͪͳΈʹਖ਼͍͠ಡΈํ
None
͜ΕӕͰ͠ΐʂ
͜ͷதͰ ۀͰKubernetesΛ͍ͬͯΔਓʁ
͜ͷதͰ ۀͰKubernetesΛ͍ͬͯΔਓʁ ϚαΧϦ࠷ޙʹ·ͱΊ͓ͯ͛Լ͍͞
Kubernetesͱʁ •͍ΘΏΔຊ൪ڥʹ͑Δʮίϯςφʯͷ ʮΦʔέετϨʔγϣϯπʔϧʯͰ͢ɻ →
Kubernetesͱʁ •͍ΘΏΔຊ൪ڥʹ͑Δʮίϯςφʯͷ ʮΦʔέετϨʔγϣϯπʔϧʯͰ͢ɻ → Ͳ͏ͬͯ͏ͷ͔ͳʁ
ͦͦίϯςφͱʁ
ͦͦίϯςφͱʁ •Α͘Θ͔Βͳ͍͚ͲɺΠϝʔδ͜Μͳײ͡ͷ ԾԽٕज़ͷҰͭͩͱଊ͍͑ͯ·͢ɻ
ΦʔέετϨʔγϣϯπʔϧͱʁ •(ଟ)ChefͷKnife(ଟ)AnsibleͷΑ͏ʹɺओʹ ϚγϯͷηοτΞοϓใΛهड़ͨ͠Կ͔͠ΒͷϑΝ Πϧ͕͋ΓɺͦΕΒͷϑΝΠϧΛݩʹ࡞ΒΕͨαʔ όʔΛཧ͢ΔͨΊͷΈ(←ͱղऍ͍ͯ͠Δ) •ͦΕͷίϯςφ൛ (Ͳ͏ΒLXDͷDockerҎ֎ͷίϯςφٕज़ʹ ͑͢ΔΒ͍͠)
ͭ·ΓKubernetes αʔόʔ্ʹ͋ΔίϯςφΛ ཧͯ͘͠ΕΔͭ…ʂ
ͭ·ΓKubernetes αʔόʔ্ʹ͋ΔίϯςφΛ ཧͯ͘͠ΕΔͭ…ʂ Ұ୴ͳΔ΄Ͳ…ʁ
KubernetesͲ͏͍͍ͷʁ
ྑ͘Θ͔Γ·ͤΜʂ
ͰDockerΛ͏έʔεଟͦ͏ •ϚΠΫϩαʔϏεΞʔΩςΫνϟ͕ྲྀߦͬͯ ͖͍ͯͨΓɺ࣮ߦڥͱಉ͡ڥΛ։ൃڥ Ͱ࠶ݱͰ͖ͨΓɺςετͷ࣌αʔόʔཱͯ ͣʹDockerίϯςφΛͬͨΓ͢Δέʔε ૿͍͑ͯΔؾ͕͢Δɻ •ͦ͏͍͏χʔζͷ͜ͱΛߟ͑ΔͱɺAnsible ChefVagrantͰॏ͍ؾ͢Δɻɻɻ
DevOpsͷ྆ํ͕Ͱ͖Δ •࠷ॳ͔ΒKubernetesͰӡ༻͍ͯ͠Εɺαʔόʔ ্ͰͲͷϛυϧΣΞΛར༻͢Δ͔։ൃऀ͕ Dockerfileʹॻ͚ྑ͍͠ɺ͙͢ʹखݩͰࢼͤΔɻ •ChefΛ͍ͬͯΔͱɺϚγϯͷϛυϧΣΞಉ ࢜ͷׯবͱ͔ͱ͔ߟ͑ͳ͍ͱ͍͚ͳ͍ͷͱɺϩʔ ΧϧͰVM༻ҙ͢Δͱ͔݁ߏॏ͍ɻVagrantવ Γɻ
োੑ͕࠷ॳ͔Βߴ͍ •ͪΖΜCookbookͱ͔ʹͪΌΜͱσʔϞϯͱ͠ ͯɺམͪͨΒ࠶ىಈ͢Δͱ͔ॻ͍͍ͯΕ͍͍ ͷ͚ͩͲɺϗετʹΰϛ͕ͬͯͦͷΰϛͷ͍ͤ ͰىಈͰ͖ͳ͍ͱ͔ͩͱհ(inodeͱ͔)ɻ •KubernetesΛ͍ͬͯΕམͪͨΒίϯςφ͕ࢮ ʹɺউखʹ৽ཱͯͯ͘͘͠ΕΔͷͰɺ͋·Γͦͷ ลΛؾʹ͠ͳ͍͍ͯ͘ɺԿͳΒΞϓϦέʔγϣ ϯΤϥʔͰམͪͯɺىಈͯ͘͠ΕΔɻ
ͱ͍͏ͱ͜ΖͰͬͯΈ·ͨ͠
࣮KubernetesΛݚڀʹ Έࠐ͏ͱ͍ͯ͠Δ •ࢄॲཧΛݚڀࣨͰѻ͏ͷͰɺͦͷࢄॲཧ Λߦ͏ڥࣗମΛKubernetes+DockerͰରԠ͠ Α͏ͱ͍ͯ͠Δɻ •ͦ͏͢Δ͜ͱʹΑͬͯݚڀࣨͷ༨ϦιʔεΛ ͬͯɺڥΛԚͣ͞ʹܭࢉॲཧΛߦ͏͜ͱ͕Ͱ ͖ͦ͏ʂ •ͳͷͰKubernetesΛ࢝ΊͯΈ·ͨ͠ɻ
KubernetesͷTutorial •ͱΓ͋͑ͣKubernetesͷTutorialΛ •https://kubernetes.io/docs/tutorials/
Kubernetes Tutorialͷྑ͍ͱ͜Ζ •ϒϥβ্ͰKubernetesΛࢼͤΔʂ
Kubernetes Basics •·ͣKubernetes BasicsͷTutorialΛʂ •༰͜Μͳײ͡ʹͳ͍ͬͯΔΑ͏Ͱ͢ɻ
https://kubernetes.io/docs/tutorials/kubernetes- basics/create-cluster/cluster-interactive/
TutorialΛऴ͑ͯ… •νϡʔτϦΞϧ͘Β͍ͩͬͨΒผʹ͘͠ͳ͍͕ɺ࣮ࡍʹ͓͏ͱ͢ ΔͱɺࣗݾڥͰͷηοτΞοϓ͕໘ͳ༷ࢠ •minikubeΛ͑ϩʔΧϧͰେৎ͚ͩͲϚϧνϊʔυ·ͩରԠ ͯ͠ͳͦ͞͏ •NodeͷωοτϫʔΫઃఆɺKubernetesͷଓʑ… •ҰԠϩʔΧϧͰηοτΞοϓ͢Δํ๏ͱͯ͠bootkubeͱ͍͏πʔϧग़ ͖͍ͯͯͯɺݸਓͰ͏ͷʹෑډԼ͕͖͍ͬͯͯΔΑ͏Ͱ͕͢ɺ KubernetesͰαΫοͱαʔϏε࡞ͬͯग़͔͢ʔɺͷϋʔυϧ·ͩߴ͍ •࠷ۙͷைྲྀʁ
ͬͺΓΫϥυΛ͏ํ͕͍͍ •࠷ۙͰKubernetesʹରԠ͍ͯ͠ΔΫϥυϗεςΟϯάڥॆ࣮ ͖͍ͯͯ͠Δ •GCPͷGKE(Google Kubernetes Engine) •AzureͷAKS(Azure Kubernetes Service) logoແ͔ͬͨ
•AWSͷEKS(Elastic Kubernetes Service) •͜ͷதͩͱ࣮ӡ༻ࣄྫͰݸਓతʹΑ͘ݟΔͷGKEͰɺҙ֎ͳ͜ͱʹ AWSͷEKSҰ൪ޙൃ •ͱ͍͑ݚڀͰ͏ͷͰࣗલͰ·ͳ͍ͱ͍͚ͳ͍Ͱ͕͢ʂʂ
·ͱΊ •Kubernetesɺӡ༻Ͳ͏Βָͦ͏͚ͩͲɺࣗͰΫ ϥελΉͱ݁ߏେมͦ͏ʂ •ͰmicroserviceԽͷྲྀΕ͋Δ͔ΒɺͦΕͱͷ૬ੑ ྑͦ͞͏ʂ •͠ຊ൪ͱͯ͠͏ͳΒGKEͱ͔AKSͱ͔EKSͱ͔Λ ׆༻͢Δͷ͕͍͍͔Ͱ͢Ͷʂ •ࣗલͰΉtipsࠓޙݚڀ͕ਐΊߋ৽ͯ͠ߦ͖·͢ʂ
exit 0
ࠂ •7/17(Ր)ͷʹOkinawa.go͋Γ·͢ʂདྷͯͶʂ •https://okinawa-go.doorkeeper.jp/events/76882