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
boot2docker 사용시 컨테이너에서 생성한 데이터를 유지하기
Search
seapy
January 26, 2015
Programming
0
79
boot2docker 사용시 컨테이너에서 생성한 데이터를 유지하기
Docker 코리아 캐주얼 토크에서 발표한 자료
seapy
January 26, 2015
Tweet
Share
More Decks by seapy
See All by seapy
Lambda + S3 썸네일 생성 및 운영 - AWSKRUG 정기 세미나 (2016년 9월)
seapy
1
550
형태소 분석기를 적용한 elasticsearch 운영
seapy
0
450
Amazon ec2 container service 소개
seapy
0
82
Elasticsearch + fluentd for Log analysis
seapy
3
9.9k
ActiveRecord Associations(2) - RORLab Season 3-8
seapy
0
45
ActiveRecord Associations(1) - RORLab Season 3-7
seapy
0
64
ActiveRecord Observers - RORLab Season 3-6
seapy
0
45
ActiveRecord Callbacks - RORLab Season 3-5
seapy
0
41
Rails Database Migrations - RORLab Season 3-3
seapy
2
97
Other Decks in Programming
See All in Programming
「今のプロジェクトいろいろ大変なんですよ、app/services とかもあって……」/After Kaigi on Rails 2024 LT Night
junk0612
5
2.1k
Enabling DevOps and Team Topologies Through Architecture: Architecting for Fast Flow
cer
PRO
0
320
Why Jakarta EE Matters to Spring - and Vice Versa
ivargrimstad
0
1.1k
2024/11/8 関西Kaggler会 2024 #3 / Kaggle Kernel で Gemma 2 × vLLM を動かす。
kohecchi
5
910
イベント駆動で成長して委員会
happymana
1
320
Kaigi on Rails 2024 〜運営の裏側〜
krpk1900
1
200
Amazon Qを使ってIaCを触ろう!
maruto
0
400
Creating a Free Video Ad Network on the Edge
mizoguchicoji
0
120
as(型アサーション)を書く前にできること
marokanatani
9
2.6k
3 Effective Rules for Using Signals in Angular
manfredsteyer
PRO
0
100
最新TCAキャッチアップ
0si43
0
140
詳細解説! ArrayListの仕組みと実装
yujisoftware
0
580
Featured
See All Featured
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
169
50k
Ruby is Unlike a Banana
tanoku
97
11k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
131
33k
Making the Leap to Tech Lead
cromwellryan
133
8.9k
Automating Front-end Workflow
addyosmani
1366
200k
It's Worth the Effort
3n
183
27k
How to Think Like a Performance Engineer
csswizardry
20
1.1k
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
Optimizing for Happiness
mojombo
376
70k
Statistics for Hackers
jakevdp
796
220k
VelocityConf: Rendering Performance Case Studies
addyosmani
325
24k
Transcript
Docker ܻই ந ష : boot2docker ࢎਊद ஶపց ীࢲ ࢤࢿೠ
ؘఠܳ ਬೞӝ
# boot2docker ࢎਊद ஶపցীࢲ ࢤࢿೠ ؘఠܳ ਬೞח ߑߨ * ഐझ
ஹೊఠ /Users ಫ؊ী ݃ * boot2docker о࢚ݠन ղࠗ ಫ؊ী ݃ * ࠅܬ ஶపց ࢎਊ
# ഐझ ஹೊఠ /Users ಫ؊ী ݃ ``` $ docker run
\ -p 5432:5432 \ -v ~/postgresql:/var/lib/postgresql/data \ postgres:9.4 ``` ``` initdb: could not create directory "/var/lib/postgresql/data/global": Permission denied ```
boot2docker ח `bootdocker up` प೯द җ э ഐझ ಫ؊ܳ VM
ਵ۽ ݃ * Users share at /Users * /Users share at /Users * c/Users share at /c/Users * /c/Users share at /c/Users * c:/Users share at /c/Users
boo2docker ীࢲ /Users ܳ docker:staff ҅ਸ ࢎਊ೧ زਵ۽ ݃ ஶపցীࢲ
࢜۽ ҅ ࢤࢿद boot2docker ৬ ܲ UID/GID ܳ оѱػ. ੌ ࢤࢿҗ ઁח ಫ؊ ӂೠਸ 777۽ ߸҃೧ ೧Ѿ ೞ݅ ೞ݂٘ ࢤࢿ VirtualBox ߡӒ۽ (https://www.virtualbox.org/ticket/818) ৈ زೞ ঋח. ҙ۲ ग : https://github.com/boot2docker/boot2docker/issues/581#issuecomm ent-60309186 > ഐझ ؘఠܳ ߄۽ ੍ਸ ҃ ਬਊ > ࠛਃೞѱ ഐझ ੌ ߂ ಫ؊ ӂೠਸ ߸҃೧ঠ ೧ঠ ೠ
# boot2docker о࢚ݠन ղࠗ ಫ؊ী ݃ ``` $ docker run
\ -p 5432:5432 \ -v /var/lib/boot2docker/postgresql:/var/lib/postgresql/data \ postgres:9.4 ``` `boot2docker init` ݺ۸য प೯द 2ѐ о࢚٣झܳ ࢤࢿೞҊ VMী ݃ * /var/lib/docker * /var/lib/boot2docker > о࢚ ٣झח `boot2docker delete` ݺ۸য प೯द ઁ
# ࠅܬ ஶపց ࢎਊ ``` $ docker run --name pg-data
\ -v /var/lib/postgresql/data \ busybox $ docker run \ -p 5432:5432 \ --volumes-from pg-data \ postgres:9.4 ``` > ࠅܬ ஶపց ؘఠח `/var/lib/docker` о ਕ ঋחೠ ਬ
# Ѿۿ DB ؘఠܳ ਬ दఃח ਊب۽ ࠅܬ ஶపց ࢎਊ,
ഐझ ؘఠܳ ੍ӝ ਤೠ ਊب۽ /Users ݃