LXC, Docker, and The Future of Software Delivery: Linuxcon - New Orleans, 2013 Jérôme Petazzoni, Dotcloud Inc
LXC, Docker, and The Future of Software Delivery: Linuxcon - New Orleans, 2013 Jérôme Petazzoni, Dotcloud Inc
Outline
Why Docker?
Where is it going?
What are
we trying
to solve?
Many payloads
databases
distributed stores
webapps
Many payloads
Go
Java
Node.js
PHP
Python
Ruby
Many payloads
CherryPy
Django
Flask
Plone
...
Many payloads
Apache
Gunicorn
uWSGI
...
Many payloads
+ your code
Many targets
bare metal
virtual machines
shared hosting
+ your dog's Raspberry Pi
Many targets
BSD
Linux
OS X
Windows
Many targets
BSD
Linux
OS X
Windows
Web
frontend
background
workers
User DB
Analytics
DB
Queue
Development
VM
QA Server
Single Prod
Server
Contributors
laptop
Customer
Servers
Real-world analogy:
containers
Many products
clothes
electronics
raw materials
wine
ships
trains
trucks
...
Linux containers...
run everywhere
run anything
Separation of concerns:
Dave the Developer
inside my container:
my code
my libraries
my package manager
my app
my data
Separation of concerns:
Oscar the Ops guy
logging
remote access
network configuration
monitoring
pid
mnt
net
uts
ipc
user
memory
cpu
blkio
devices
Efficiency: storage-friendly
unioning filesystems
(AUFS, overlayfs)
snapshotting filesystems
(BTRFS, ZFS)
copy-on-write
(thin snapshots with LVM or device-mapper)
This wasn't part of LXC at first; but you definitely want it!
Efficiency: storage-friendly
Docker
What's Docker?
Yes, but...
anywhere
multiple times
Dockerfile example
FROM ubuntu
RUN
RUN
RUN
RUN
RUN
apt-get
apt-get
apt-get
apt-get
apt-get
-y update
install -y
install -y
install -y
install -y
g++
erlang-dev erlang-manpages erlang-base-hipe ...
libmozjs185-dev libicu-dev libtool ...
make wget
RUN wget http://.../apache-couchdb-1.3.1.tar.gz | tar -C /tmp -zxfRUN cd /tmp/apache-couchdb-* && ./configure && make install
RUN printf "[httpd]\nport = 8101\nbind_address = 0.0.0.0" >
/usr/local/etc/couchdb/local.d/docker.ini
EXPOSE 8101
CMD ["/usr/local/bin/couchdb"]
private registry
or security credentials
Typical workflow
Hybrid clouds
OpenStack integration
Docker roadmap
LXC
AUFS
LXC
plugins