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
RancherOS - for containers, by containers
Search
Kazumichi Yamamoto
August 07, 2017
Technology
5
810
RancherOS - for containers, by containers
Rancher Meetup Fukuoka(福岡) #1 での発表資料。
RancherOSの概要、利用方法、内部動作(主に起動関連)、最近の開発状況について扱っています。
Kazumichi Yamamoto
August 07, 2017
Tweet
Share
More Decks by Kazumichi Yamamoto
See All by Kazumichi Yamamoto
オートスケールにおけるオブザーバビリティへの取り組み / Observability with autoscale
yamamotofebc
1
360
からあげの町からお届けするフルリモートSREの日常 / 2023-06-21 tech lunch
yamamotofebc
0
200
「合意のない期待」を防ぐためのドラッカー風エクササイズ
yamamotofebc
3
1k
さくらのクラウド向けオートスケーラー / autoscaler for SAKURA cloud
yamamotofebc
1
1.8k
sacloud tools
yamamotofebc
1
88
Rioでコンテナを楽しくする / Rio − Make Containers Fun!
yamamotofebc
2
670
Rancher 2.0 HA with Terraform
yamamotofebc
3
3.5k
Rancher Meetup Hiroshima #1 LT - カタログを使ってみよう // Rancher Meetup Hiroshima 2018-05-11
yamamotofebc
2
610
Rancher Meetup KYOTO #1 LT - 外からコンテナに繋ぐには? // Rancher Meetup Kyoto 2018-04-27
yamamotofebc
4
420
Other Decks in Technology
See All in Technology
プロダクト活用度で見えた真実 ホリゾンタルSaaSでの顧客解像度の高め方
tadaken3
0
190
iOSチームとAndroidチームでブランチ運用が違ったので整理してます
sansantech
PRO
0
150
rootlessコンテナのすゝめ - 研究室サーバーでもできる安全なコンテナ管理
kitsuya0828
3
390
Python(PYNQ)がテーマのAMD主催のFPGAコンテストに参加してきた
iotengineer22
0
520
AWS Lambdaと歩んだ“サーバーレス”と今後 #lambda_10years
yoshidashingo
1
180
Platform Engineering for Software Developers and Architects
syntasso
1
520
Introduction to Works of ML Engineer in LY Corporation
lycorp_recruit_jp
0
140
IBC 2024 動画技術関連レポート / IBC 2024 Report
cyberagentdevelopers
PRO
1
110
AGIについてChatGPTに聞いてみた
blueb
0
130
Incident Response Practices: Waroom's Features and Future Challenges
rrreeeyyy
0
160
AWS Media Services 最新サービスアップデート 2024
eijikominami
0
200
飲食店データの分析事例とそれを支えるデータ基盤
kimujun
0
170
Featured
See All Featured
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
28
2k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.3k
Optimizing for Happiness
mojombo
376
70k
Ruby is Unlike a Banana
tanoku
97
11k
Facilitating Awesome Meetings
lara
50
6.1k
Measuring & Analyzing Core Web Vitals
bluesmoon
4
130
Adopting Sorbet at Scale
ufuk
73
9.1k
Stop Working from a Prison Cell
hatefulcrawdad
267
20k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Documentation Writing (for coders)
carmenintech
65
4.4k
Speed Design
sergeychernyshev
25
620
Transcript
3BODIFS.FFUVQ'6,60," !ZBNBNPUP@GFCD GPSDPOUBJOFST CZDPOUBJOFST
ࢁຊ ಓ !ZBNBNPUP@GFCD üେݝࡏॅɺϐΞϊ ҆৺ӃϫΠϯ -PWFS ü͘͞ΒͷΫϥυؔ࿈ͷΦʔϓϯιʔε։ൃ 8IP
1SPEVDUTGPS͘͞ΒͷΫϥυ ͘͞ΒͷΫϥυ ެೝ$-*ʮVTBDMPVEʯ 5FSSBGPSNGPS ͘͞ΒͷΫϥυ 1BDLFSGPS ͘͞ΒͷΫϥυ %PDLFS.BDIJOF *OGSB,JU 8PSE1SFTT
ΦϒδΣΫτετϨʔδ 8PSE1SFTT ΣϒΞΫηϥϨʔλ .BDLFSF౷߹πʔϧ ʮ4BDLFSFMʯ LVCFTBDMPVE $PNJOH4PPO
ࡢ ɺ3BODIFS04ͷ ίϯτϦϏϡʔλʹͳΓ·ͨ͠ʂʂ
3BODIFS
None
։ൃݩ
ίϯςφཧϓϥοτϑΥʔϜ
ίϯςφ͚ܰྔ04
ࢄϒϩοΫετϨʔδ
0WFSWJFX
Α͋͘Δצҧ͍ 3BODIFS04 3BODIFSΛಈ͔ͨ͢Ίͷ04
Α͋͘Δצҧ͍ 3BODIFS04 3BODIFSΛಈ͔ͨ͢Ίͷ04
0WFSWJFX ü ίϯςφʹΑΔ ü ίϯςφͷͨΊͷ ü γϯϓϧܰྔͳ04
• %PDLFSʹಛԽ͍ͯ͠Δ • αΠζ͕খ͘͞ىಈ͕ૣ͍ • 4ZTUFN6TFSͷͭͷ%PDLFSΠϯελϯε • JOJUγεςϜʹ%PDLFSΛར༻ 0WFSWJFX
ྨɿίϯςφϗετ͚04
%PDLFSʹಛԽͨ͠04
αΠζ͕খ͍͞ .# ˞ W࣌ͰͷWNMJOV[ JOJUSEͷαΠζ
-JOVY,FSOFM 4ZTUFN%PDLFS OUQ OFUXPSL VEFW BDQJE TZTMPH DPOTPMF EPDLFS VTFSEPDLFS
͕ͯ͢%PDLFS
4ZTUFNͱ6TFSɺͭͷ%PDLFS
1*% 1*% JOJUγεςϜ%PDLFS
• %PDLFSʹಛԽ͍ͯ͠Δ • αΠζ͕খ͘͞ىಈ͕ૣ͍ • 4ZTUFN6TFSͷͭͷ%PDLFSΠϯελϯε • JOJUγεςϜʹ%PDLFSΛར༻ 0WFSWJFX
0WFSWJFX ü ίϯςφʹΑΔ ü ίϯςφͷͨΊͷ ü γϯϓϧܰྔͳ04
GPSDPOUBJOFST CZDPOUBJOFST
*OTUBMMBUJPO
• *40Πϝʔδ $%30. ͔Βىಈ • σΟεΫʹΠϯετʔϧͯ͠ىಈ • ֤छΫϥυϓϩόΠμ͕ఏڙ͢ΔΠϝʔδΛར༻ ࣮ߦΠϯετʔϧํ๏ ˞0QFO4UBDL19&ʹରԠ͍ͯ͠·͢
ϓϩϏδϣχϯά DMPVEDPOGJHZNM Χʔωϧύϥϝʔλ ϝλσʔλαʔϏε $POGJH %SJWF config-2
"ENJOJTUSBUJPO
ཧίϚϯυ SPT $ sudo ros [global options] command [command options]
[arguments...] ίϚϯυ આ໌ DPOGJH ઃఆͷมߋ DPOTPMF ίϯιʔϧͷΓସ͑ FOHJOF 6TFS%PDLFSͷόʔδϣϯΓସ͑ TFSWJDF αʔϏε ίϯςφ ͷཧ PT 3BODIFS04ࣗମͷόʔδϣϯΞοϓ JOTUBMM 3BODIFS04ΛσΟεΫͷΠϯετʔϧ SPTίϚϯυͷओͳػೳ ίϚϯυ
SPT DPOGJHίϚϯυ $ sudo ros config command [arguments...] ίϚϯυ આ໌
HFU ࢦఆΩʔͷݱࡏͷઃఆΛऔಘ TFU ࢦఆΩʔͷΛઃఆ FYQPSU ݱࡏͷઃఆΛZBNMܗࣜͰදࣔ WBMJEBUF ࢦఆͷϑΝΠϧͷݕূ SPT DPOGJHίϚϯυ ઃఆؔ࿈ͷૢ࡞
SPT DPOTPMFίϚϯυ $ sudo ros console command [arguments...] ίϚϯυ આ໌
TXJUDI ίϯιʔϧͷΓସ͑ ଈସ FOBCMF ίϯιʔϧͷΓସ͑ ࣍ճ࠶ىಈ࣌ʹସ MJTU ར༻ՄೳͳίϯιʔϧͷҰཡදࣔ SPT DPOTPMFίϚϯυ ίϯιʔϧؔ࿈ͷૢ࡞ • EFGBVMU • BMQJOF • DFOUPT • EFCJBO • GFEPSB • VCVOUV ˞W࣌
3BODIFS04ͰͷDPOTPMF -JOVY,FSOFM 4ZTUFN%PDLFS OUQ OFUXPSL VEFW BDQJE TZTMPH DPOTPMF EPDLFS
• 3BODIFS04ʹ͓͚ΔγΣϧɺHFUUZTTIEΛఏڙ • σϑΥϧτ#VTZ#PYϕʔε • ίϯςφ͔ͩΒସΠϝʔδΛࠩ͠ସ͑Δ͚ͩ
SPT FOHJOFίϚϯυ $ sudo ros engine command [arguments...] ίϚϯυ આ໌
TXJUDI %PDLFSͷΓସ͑ ଈସ FOBCMF %PDLFSͷΓସ͑ ࣍ճ࠶ىಈ࣌ʹସ MJTU ར༻Մೳͳ%PDLFSΤϯδϯͷҰཡදࣔ SPT FOHJOFίϚϯυ FOHJOF %PDLFS ؔ࿈ͷૢ࡞
3BODIFS04ͰͷFOHJOF EPDLFS -JOVY,FSOFM 4ZTUFN%PDLFS OUQ OFUXPSL VEFW BDQJE TZTMPH DPOTPMF
EPDLFS • VTFSEPDLFSTZTUFNEPDLFS্ͷίϯςφ • ίϯςφ͔ͩΒ ҎԼུ
%&.0
6TBHF
TFSWJDFͱ 㲈 service • EPDLFSDPNQPTFܗࣜͰఆٛ͞Εͨίϯςφ ৗறΞϓϦ 8FCαʔόͳͲ ϘϦϡʔϜͷఏڙ ίϚϯυͷఏڙ command
TFSWJDFͷׂ
TFSWJDFͱ -JOVY,FSOFM 4ZTUFN%PDLFS OUQ OFUXPSL VEFW BDQJE TZTMPH DPOTPMF EPDLFS
• ओཁͳσʔϞϯྨTFSWJDFͱͯ͠ఏڙ͞Ε͍ͯΔ • VTFSEPDLFS্ͰՔಇ͢ΔTFSWJDF͋Δ SBODIFSTFSWFSαʔϏεͳͲ
SPT TFSWJDFίϚϯυ $ sudo ros service command [arguments...] SPT TFSWJDFίϚϯυ
αʔϏεؔ࿈ͷૢ࡞ ίϚϯυ આ໌ MJTU αʔϏε ఆٛ ͷҰཡදࣔ FOBCMFEJTBCMFEFMFUF αʔϏε ఆٛ ͷ༗ޮແޮԽআ QVMMCVJME αʔϏεͰར༻͢ΔΠϝʔδͷऔಘϏϧυ VQTUBSUSFTUBSUTUPQ αʔϏεͷىಈఀࢭ QT ىಈ͍ͯ͠ΔαʔϏε ίϯςφ ͷҰཡදࣔ MPHT αʔϏεͷϩάදࣔ ˞Ұ෦ͷίϚϯυͷΈൈਮ
αʔϏεͷఆٛ $ sudo ros service enable [docker-compose.yaml] # ϑΝΠϧύεΛࢦఆ $
sudo ros service enable /var/lib/rancher/conf/example.yml # 63-Λࢦఆ $ sudo ros service enable https://example.com/example.yml ࣮ߦྫ ˞SPTίϚϯυͷΘΓʹDMPVEDPOGJHZNMΛ༻͍ͯఆٛ͢Δ͜ͱՄೳ
αʔϏεͷར༻ $ sudo ros service up <service name>... αʔϏεͷىಈ $
sudo ros service logs <service name>... αʔϏεͷϩάදࣔ $ sudo ros service ps ىಈ͍ͯ͠ΔαʔϏεͷҰཡ
%&.0
ಠࣗϦϙδτϦ͔ΒͷαʔϏεՃ 8FC্ͷϦϙδτϦ͔ΒαʔϏεఆٛΛऔಘ͢Δ͜ͱ͕Մೳ ྫɿ 3BODIFS04ࠐαʔϏεɿ https://github.com/rancher/os-services ಠࣗϦϙδτϦͷαϯϓϧɿ https://roastlink.github.io
ࢀߟಠࣗϦϙδτϦ͔ΒͷαʔϏεՃ [repo root] ├── index.yml ├── n │ └── nginx.yml
├── o │ └── open-vm-tools.yml └── r └── rancher-server.yml ϦϙδτϦͷϑΝΠϧߏ ΠϯσοΫεϑΝΠϧ services: - nginx - open-vm-tools - rancher-server
ࢀߟಠࣗϦϙδτϦ͔ΒͷαʔϏεՃ 8FCϦϙδτϦΛ͏ͨΊͷઃఆ SPTίϚϯυͷ߹ $ sudo ros config set rancher.repositories.<name>.url <repo-url>
DMPVEDPOGJHZNMͰઃఆ͢Δ߹ #cloud-config.yml rancher: repositories: <name>: url: <repo-url>
"EWBODFEUPQJD
ىಈͷΈ 2 TZTUFNEPDLFS 1*% ͬͯ Ͳ͏ͬͯىಈͯ͠Δͷʁ
ىಈͷΈ " HPͰॻ͔ΕͨಠࣗͷJOJUͰॲཧ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
࣮ମSPTόΠφϦ HPͷಠࣗόΠφϦ VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS 1*% %JTL 3". 3".%JTL γεςϜίϯςφىಈ ࣮ମSPTόΠφϦ NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF 3BODIFS04ಠࣗͷͷ ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ిݯೖʙϒʔτϩʔμ ˞σϑΥϧτTZTMJOVYɺ17(36#બΔ ˞ओͳॲཧͷΈൈਮ
ϒʔτϩʔμ CPPU ˞ಡΈ͘͢͢ΔͨΊ*/$-6%&Λల։͍ͯ͠·͢
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF -;." DQJP JOJUSBNGT ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ΧʔωϧΠϝʔδJOJUSEల։ɺJOJU࣮ߦ -;." DQJP JOJUSBNGT ˞ओͳॲཧͷΈൈਮ
JOJUSEͷ༰ SPT • SPTίϚϯυHPͰॻ͔Εͨ3BODIFS04ͷίΞ • ࣮ߦϑΝΠϧ໊ BSHW<> Ͱಈ࡞Λସ •
JOJUVTSCJOTZTUFNEPDLFSͷ࣮ମSPTίϚϯυ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF Ϛϯτ EFWUNQGTQSPDɺTZT ΧʔωϧϞδϡʔϧϩʔυͳͲ ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF TUBUFʹσΟεΫΛϚϯτ DISPPU ˞Χʔωϧύϥϝʔλ SBODIFSTUBUFEFW͕༩͑ΒΕ͍ͯͨ߹ ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF γεςϜίϯςφͷىಈ ࣮ମSPTίϚϯυ ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS %JTL 3". 3".%JTL NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF TZTUFNEPDLFSΛFYFD 1*% 1*% ˞ओͳॲཧͷΈൈਮ
ىಈͷྲྀΕ #*046&'* .#3 ϒʔτϩʔμ TZTMJOVY WNMJOV[ JOJUSE JOJU WNMJOV[ JOJUSE
࣮ମSPTόΠφϦ HPͷಠࣗόΠφϦ VTSCJOSPTTZTJOJU FYFD TZTUFNEPDLFS 1*% %JTL 3". 3".%JTL γεςϜίϯςφىಈ ࣮ମSPTόΠφϦ NPVOU DISPPU TUBSU ଈϦλʔϯ TUBUF 3BODIFS04ಠࣗͷͷ ˞ओͳॲཧͷΈൈਮ
ىಈͷΈͷϙΠϯτ • SPTίϚϯυΛJOJUͱ࣮ͯ͠ߦ • JOJUͷ࠷ޙͰTZTUFNEPDLFSΛFYFD SPT ͷίΞ
࠷ۙͷঢ়گ
W͚ͯ 8JUIXFXJMMTIJGUUIFGPDVTGSPN %PDLFSUPDPOUBJOFSE 0$* BOE-JOVY,JU Ҿ༻ݩIUUQTOFXTZDPNCJOBUPSDPNJUFN JE
W͚ͯ &YQFSJNFOUBM
W͚ͯ ΄΅ຖίϛοτɺ ׆ൃʹ։ൃத
&OKPZ IUUQTHJUIVCDPNSBODIFSPT GPSDPOUBJOFST CZDPOUBJOFST