docker: from zero to nonzero
TRANSCRIPT
Docker
From ZERO to NONZERO
WHO AM I?
- Francesco Lo Franco - @__kekko- Software Developer
@chupamobile.com- PUG Roma member since 2014
WHAT IS DOCKER?
❏ OPEN SOURCE
❏ Powered by GOLANG
❏ Virtualization
95,000,000$ROUND - april 2015
500,000,000$Estimated Market Value
NUMBERS But, above all...
Community!
❏ ~26.000 stars❏ ~1200 contributors❏ ~1000 issues
How Docker works?
Installing Docker
❏ Docker Daemon❏ Docker Client❏ Client HTTP
What is an Image?
FROM ubuntu:14.04RUN apt-get updateRUN apt-get install -y curl nginx
Dockerfile
$ docker build .
What do we do with an image?
We create a container based on it!
What is a Container?
An instance of an image
What can we do with a Container?
❏ execute process in bg❏ execute task
Process in bg practically
$ docker run --name image_name
-p 8080:80
-d
nginx redis mysql elasticsearch ...
execute task example
Running composer install with
HHVM without having an HHVM as
dependency in my project
(HHVM is faster with composer!)
FROM ubuntu:14.04ENV HOME /root# Install DepsRUN apt-get install -y -qq git curl wget hhvm
# Install composerRUN bash -c "wget http://getcomposer.org/composer.phar && mv composer.phar /usr/local/bin/composer"
WORKDIR /srv
ENTRYPOINT ["hhvm", "/usr/local/bin/composer"]
execute task practically
$ docker run
-v `pwd`:/srv
docker-composer install
VANTAGGI? ▸ no overhead▸ very fast▸ a lot of pre-built images▸ microservices?▸ AWS, Google etc▸ Tutum, Compose,
Machine, Swarm etc...
THANKS!You can find me at▸ @__kekko▸ [email protected]