Docker 캐주얼 토크 #1 (2014-10-15)에서 발표하기 위해 만든 자료.
원래 'Docker 실서비스 도입기'를 발표하려고 했으나, 아직 도입이 마무리되지 못한 관계로 그 과정에서 의미 있는 부분을 찾아보았다.
그래서 Chef와 Docker가 도입되면 StudyGPS에서 어플리케이션을 업데이트하는 기존의 방식이 어떻게 변화하는지에 대해 설명하고, 그 변화의 의미에 대해서 생각해보고 정리하였다.
7. 4 Difference of Data Amount between Versions
(40MB)
ADD . /studygps
WORKDIR /studygps
☛ RUN NODE_ENV=production npm install
4 But it's not a Big Problem.
4 And MONEY can solve this.
11. 4 Docker makes Chef Recipes SIMPLE and TYPICAL.
docker_image 'kjunine/mongodb' do
tag 'latest'
cmd_timeout 600
action :pull
end
docker_container 'mongod' do
image 'kjunine/mongodb:latest'
container_name 'mongod'
entrypoint 'mongod'
command "--dbpath /data --replSet #{node['mongodb']['replset']}"
detach true
port '27017:27017'
volume '/data'
cmd_timeout 300
action :run
end
12. 4 But, you should write
Dockerfiles
additionally.
4 It is much EASIER to write a Dockerfile than writing a
Chef Recipe.