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
telepresence で始める k8s 時代のローカル開発
Search
shiro16
March 29, 2019
Technology
10
5.6k
telepresence で始める k8s 時代のローカル開発
2019.03.29 Cloud Native Meetup Tokyo #7
shiro16
March 29, 2019
Tweet
Share
More Decks by shiro16
See All by shiro16
minne のアーキテクチャの進化とこれから
shiro16
1
3.1k
minne の開発環境の変革と今後
shiro16
0
1k
Rails6 upgrade タイムアタック
shiro16
2
2.4k
minne での検索改善の歴史
shiro16
1
2.2k
minne でのハイブリッドクラウド運用
shiro16
1
1.7k
マイクロサービス事始め@技術編
shiro16
0
1.1k
Other Decks in Technology
See All in Technology
Efficient zero-copy networking using io_uring
ennael
PRO
0
320
MLOpsの「あるある」課題の解決と、そのためのライブラリgokart
mski_iksm
1
160
YAPC::Hakodateの映像記録を支える技術
godan
4
180
過去のインプットとアウトプットを振り返る
diggymo
0
100
O'Reilly Superstream: Building a RAG App to Chat with Your Data
pamelafox
0
110
エンジニアは伝え方が9割/90% of what engineers need is communication skills
ykanoh
2
170
Oracle Database 23ai 新機能#4 Real Application Clusters
oracle4engineer
PRO
0
130
Slackbot × RAG で実現する社内情報検索の最適化
howdy39
2
300
エムスリーマネジメントチーム紹介資料 / Introduction of M3 Management Team
m3_engineering
0
260
【shownet.conf_】コンピューティング資源を統合した分散コンテナ基盤の進化
shownet
PRO
0
350
Product Utilization of Large Language Models Starting Today
ymatsuwitter
3
1k
【インフラエンジニアbooks】30分でわかる「AWS継続的セキュリティ実践ガイド」
hssh2_bin
4
1.4k
Featured
See All Featured
The Invisible Customer
myddelton
119
13k
Bash Introduction
62gerente
608
210k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
44
2k
Building a Scalable Design System with Sketch
lauravandoore
459
32k
Building Better People: How to give real-time feedback that sticks.
wjessup
360
19k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
26
1.9k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
41
9.2k
Design by the Numbers
sachag
278
19k
Six Lessons from altMBA
skipperchong
26
3.4k
Navigating Team Friction
lara
183
14k
The Brand Is Dead. Long Live the Brand.
mthomps
53
38k
Happy Clients
brianwarren
97
6.7k
Transcript
ޙ౻རത(.01FQBCP *OD $MPVE/BUJWF.FFUVQ5PLZP UFMFQSFTFODFͰ࢝ΊΔ LT࣌ͷϩʔΧϧ։ൃ
νʔϑςΫχΧϧϦʔυ 5PTIJIJSP(PUP!@TIJSP NJOOFࣄۀ෦!(.0ϖύϘ
None
ຊͷ͓ͷ༰ wUFMFQSFTFODFͱ wUFMFQSFTFODFͷ͍ํ wUFMFQSFTFODFΛಋೖ͢ΔࡍͷϋϚΓϙΠϯτ wUFMFQSFTFODFͷॲཧͷྲྀΕ
ຊ͞ͳ͍༰ wLVCFSOFUFTDMVTUFSͷ͓ wLVCFSOFUFTͷجຊతͳ͓ wEPDLFSͷ͍ํ w3BJMTʹ͍ͭͯ wTTIʹ͍ͭͯ
UFMFQSFTFODFͱ
UFMFQSFTFODFͱ w୯ҰͷαʔϏεΛϦϞʔτͷ,VCFSOFUFTΫϥελʹଓ͠ͳ͕Βɺ ͦͷαʔϏεΛϩʔΧϧͰ࣮ߦ͢Δ͜ͱ͕ՄೳʹͳΔ wͦͷαʔϏε͕ΫϥελͷଞͷαʔϏεʹґଘ͍ͯ͠Δ߹Ͱɺ ୯ҰͷαʔϏεͷਝͳϩʔΧϧ։ൃΛߦ͏͜ͱ͕ՄೳʹͳΔ wϩʔΧϧͷ։ൃϚγϯΛ,VCFSOFUFTΫϥελͷҰ෦ͷΑ͏ʹಈ࡞͞ ͤΔ͜ͱ͕ՄೳʹͳΔ
LVCFSOFUFTDMVTUFS NBD
LVCFSOFUFTDMVTUFS UFMFQSFTFODF NBD
Ͳ͏͍͏͕ղܾͰ͖Δ͔ʁ
ղܾͰ͖Δ wJNBHFCVJMEQVTIQPEͷJNBHFߋ৽ͷखؒΛল͘͜ͱ͕Մೳ wϦϞʔτͷ,VCFSOFUFTΫϥελʹଓ͠ͳ͕Β։ൃͰ͖ΔΑ͏ʹͳ ΔͷͰɺϩʔΧϧ͔ΒଞͷαʔϏε ϚΠΫϩαʔϏεతͳଞͷαʔ Ϗε%# ʹଓ͕ՄೳʹͳΔ wLVCFSOFUFTͷαʔϏεͷҰ෦ͱͯ͠ػೳ͢ΔͷͰɺΞΫηεͨ͠ ࡍͷωοτϫʔΫܦ࿏͕΄΅ಉ͡ʹͳΔ
ͭ·Γշదʹ։ൃ͕Ͱ͖Δ
UFMFQSFTFODFͷ͍ํ
લఏ wIUUQ T ͰΞΫηε͕Ͱ͖ΔQPE͕͋Δ wDPOUBJOFS1PSUͰΛ։͚͍ͯΔ w͜Ε3BJMTTFSWFSͷσϑΥϧτͷQPSU͕ͦ͏ͳ͚ͩͰมߋͯ͠ ͳ͍
·ͣJOTUBMM # homebrew Λ͏ $ brew cask install osxfuse $
brew install datawire/blackbird/telepresence # ιʔε͔Β $ git clone
[email protected]
:telepresenceio/telepresence.git $ cd telepresence $ PREFIX=/path/to/install ./install.sh # bin/ ʹͰ͖Δ
UFMFQSFTFODFͷ͍ํͦͷᶃ
ϩʔΧϧͰىಈͨ͠TFSWFSʹ ΞΫηεΛྲྀ͢
ϩʔΧϧTFSWFS # k8s-deployment-name ஔ͖͍͑ͨ deployment ͷ໊લ $ telepresence --swap-deployment k8s-deployment-name
\ --run bundle exec rails s
UFMFQSFTFODFͷ͍ํͦͷᶄ
ϩʔΧϧͰىಈͨ͠EPDLFS্Ͱ ىಈ͍ͯ͠ΔTFSWFSʹΞΫηεΛྲྀ͢
ϩʔΧϧEPDLFS # k8s-deployment-name ஔ͖͍͑ͨ deployment ͷ໊લ $ telepresence --swap-deployment k8s-deployment-name
\ --docker-run --rm -it test-image:0.0.1 bundle exec rails s
ͦͷଞͷ͍ํ
ͦͷଞͷ͍ํ wࠓճհͨͭ͠Ҏ֎ʹLVCFSOFUFTDMVTUFSʹଓͯ͠৭ʑͰ ͖Δ wྫ͑UFMFQSFTFODFSVODVSMIUUQNZTFSWJDFͱΔͱQPE ্ཱ͕͕ͪΓNZTFSWJDFʹΞΫηεͨ݁͠Ռ͕ฦͬͯདྷͨΓ wIUUQTXXXUFMFQSFTFODFJPIPXUPʹશͯ ʁ ॻ͍ͯ͋Δ
ϋϚΓϙΠϯτ
QPSUΛ͍ͬͯΔ߹
QPSUΛ͍ͬͯΔ߹ wUFMFQSFTFODFΛىಈ͢ΔͱରͷQPEͷEFGBVMUͷDPOUBJOFS ͕ஔ͖ΘΔ wஔ͖ΘͬͨDPOUBJOFSͰطʹQPSUΛ༻͍ͯ͠Δҝ DPOUBJOFS1PSUͰΞΫηεΛड͚͍ͯͯͦΕΛϩʔΧϧʹྲྀͦ͏ ͱࢥͬͯग़དྷͳ͍
ղܾํ๏ w͓ͦΒ͘ݱঢ়ແ͍ͷͰҎ֎Λ͏͔͠ͳ͍
QPEʹෳίϯςφ
QPEʹෳίϯςφΛؚΊΔ߹ wUFMFQSFTFODFΛىಈ͢ΔͱରͷQPEͷEFGBVMUͷDPOUBJOFS ͕ஔ͖ΘΔ wͳͷͰEFGBVMUDPOUBJOFSҎ֎ͰDPOUBJOFS1PSUΛͬͯͦͷ QPSUͷ௨৴ΛϩʔΧϧʹஔ͖͑Δͱ͔Ζ͏ͱࢥͬͯग़དྷͳ͍
ղܾํ๏ wૉʹEFGBVMUΛ͍·͠ΐ͏ wTXBQEFQMPZNFOULTEFQMPZNFOUOBNFUBSHFUDPOUBJOFSͷ ܗࣜͰࢦఆՄೳ
EPDLFSΛ͏߹
EPDLFSΛ͏߹ wUFMFQSFTFODFͱ͍͏ΑΓશʹEPDLFSͷ wجຊతʹEPDLFSSVOͷPQUJPOͦͷ··͑Δ wͳͷͰWͱ͔ͰNPVOU͍ͨ͠ w͔͠͠EPDLFSͷNPVOU͍ NPVOU͢ΔTJ[FʹΑΔ
ղܾํ๏ wEPDLFSTZODΛ͏ wDBDIFEPQUJPOΛ͏ wEPDLFSͷϝϞϦׂΓͯΛ૿͢
UFMFQSFTFODFͷॲཧͷྲྀΕ
UFMFQSFTFODFͷॲཧͷྲྀΕᶃ wLVCFDUMWFSTJPODPOpHΛۦͯ͠ઃఆΛऔಘ͢Δ wLVCFDUMDPOUFYUA্هͰऔಘͨ͠DVSSFOUDPOUFYUPSBSHTͷDPOUFYUAHFU OTEFGBVMUͰLTDMVTUFSͱͷૄ௨֬ೝ w˞ҎԼग़ͯ͘ΔLVCFDUMͷPQUJPOʹશͯADPOUFYUIPHF OBNFTQBDFEFGBVMUA͕ண͕͍͘ͷͰলུ wLVCFDUMHFUEFQMPZNFOUPKTPOFYQPSUABSHTͷEFQMPZNFOUAͰ EFQMPZNFOUͷใΛऔಘ
UFMFQSFTFODFͷॲཧͷྲྀΕᶄ wऔಘͯ͠อ࣋ͨ͠EFQMPZNFOUͷEFGBVMUDPOUBJOFSͷใΛॻ͖͑Δ wPQUJPOͰDPOUBJOFSΛࢦఆͨ͠߹ࢦఆ͞ΕͨDPOUBJOFS wॻ͖͑ͨ༰ͰLVCFDUMBQQMZGΛߦ͍ஔ͖͑ΔQPEΛ࡞ wLVCFDUMTDBMFEFQMPZNFOUATXBQEFQMPZFNFOUͷEFQMPZNFOUA SFQMJDBTͰطଘͷQPEΛআ wLVCFDUMQPSUGPSXBSEAஔ͖͑ͨQPEOBNFA w͜ΕͰQPEͷDPOUBJOFSʹTTIͰ͖ΔΑ͏ʹͳΔ
͜͜·ͰઌͰઆ໌ͨ͠ ύλʔϯͷ͍ํͰڞ௨
·ͣϩʔΧϧͰىಈͨ͠ TFSWFSΛ͏߹
ϩʔΧϧTFSWFSΛ͏߹ᶃ wTTI Ұ෦ུ /QUFMFQSFTFODF!3 wTTI Ұ෦ུ /QUFMFQSFTFODF! -3
w্هΛߦ͏͜ͱͰQPEͱͷํͷΞΫηεΛՄೳʹ͍ͯ͠Δ
ϩʔΧϧTFSWFSΛ͏߹ᶄ wߋʹTTIVUUMFUFMFQSFTFODFͱ͍͏πʔϧ TTIVUUMFΛ UFMFQSFTFODF༻ʹΧελϚΠζͨ͠ͷ ΛͬͯLVCFSOFUFT্ ͷଞͷαʔϏεͷΞΫηεΛՄೳʹ͍ͯ͠Δ
࣍ʹϩʔΧϧͰىಈͨ͠ EPDLFSΛ͏߹
ϩʔΧϧEPDLFSΛ͏߹ᶃ wTTI Ұ෦ུ /QUFMFQSFTFODF! -3 wEPDLFSSVOͰEBUBXJSFUFMFQSFTFODFMPDBMΛͬͯEPDLFS DPOUBJOFSΛ্ཱͪ͛Δ w͜ͷDPOUBJOFSQSPYZ༻Ͱ͜ͷޙʹىಈ͢ΔDPOUBJOFSͱQPE Λͭͳׂ͙Λ͍ͯ͠ΔΑ͏Ͱ͢ɻ
ϩʔΧϧEPDLFSΛ͏߹ᶄ wTTI Ұ෦ུ /QSPPU!3 wTTI Ұ෦ུ /QUFMFQSFTFODF!3
wEPDLFSSVOҎ߱ͷΦϓγϣϯΛࢦఆͯ͠࠷ऴతʹΞΫηεΛྲྀ͢ EPDLFSDPOUBJOFSΛىಈ͢Δ
࠷ޙʹ
ͱΓ͋͑ͣͲΜͳײ͔͡ࢼ͍ͨ͠ਓ͚
ͱΓ͋͑ͣࢼ͍ͨ͠ wIUUQTHJUIVCDPNUFMFQSFTFODFJPUFMFQSFTFODFUSFF NBTUFSFYBNQMFTHVFTUCPPL w্هʹ(,&༻ͷॾʑ͕͋ΔͷͰࢼͤͦ͏ ˞ࣗ(,&ͬͯͳ ͍ͷͰࢼͯ͠ͳ͍ wIUUQTHJUIVCDPNTIJSPUFMFQSFTFODFFYBNQMFT wͪ͜ΒͰ͓खܰʹ͓ࢼ͍͚ͨͩ͠·͢ɻ
Ҏ্UFMFQSFTFODFͷհͰͨ͠
͋Γ͕ͱ͏͍͟͝·ͨ͠