Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Docker Engine: from one to hundreds nodes

Docker Engine: from one to hundreds nodes

# Docker Engine: from one to hundreds nodes.
## An introduction to the new Docker Engine "Swarm mode".

The recent DockerCon in Seattle has been really amazing.
Among the many announcements made by the Docker team, for sure the most incredible one has been the presentation of the new Docker Engine "Swarm mode" that will be shipped in Docker 1.12.
This feature has really shocked the container orchestration solutions community pushing Docker Swarm from a follower technology to be a potential leader of the competition.
In this talk we will dive into the features of the new Docker Engine "Swarm mode" comparing it to the previous implementation of Docker Swarm.
We will also talk about tools and tips to test the "Swarm Mode" at scale.

Andrea Tosatto

July 07, 2016
Tweet

More Decks by Andrea Tosatto

Other Decks in Technology

Transcript

  1. Docker Engine From one to hundres nodes Andrea Tosatto -

    @_hilbert_ 07/07/2016 - 1st Docker Rome Meetup
  2. Docker Engine From one to hundres nodes Andrea Tosatto -

    @_hilbert_ 07/07/2016 - 1st Docker Rome Meetup An introduction to the new Docker Engine “Swarm Mode”
  3. Docker Engine From one to hundres nodes Andrea Tosatto -

    @_hilbert_ 07/07/2016 - 1st Docker Rome Meetup Why the new Docker Engine “Swarm Mode” is so cool
  4. $ whoami > Andrea Tosatto § System and Platform Operations

    @ http://www.purpleocean.it/ § OpenSource Code Monkey @ https://github.com/opsfactory
  5. # orchestration without orchestrators $ cat docker-up.sh for i in

    {0..10} do ssh dck-dev$(printf %02d $i) \ docker run --name myapp -d myapp:latest done
  6. # orchestration without orchestrators $ cat playbook.yml --- - name:

    "Provision myapp" hosts: dckdev tasks: - name: "run myapp with docker" docker: name: myapp image: myapp:latest state: started
  7. # docker swarm # Run the consul to act as

    swarm key/value backend $ docker run -d -p 8500:8500 --name=consul progrium/consul -server -bootstrap # Initialize the first swarm manager $ docker run -d -p 4000:4000 swarm manage -H :4000 --replication --advertise <manager0_ip>: 4000 consul://<consul_ip>:8500 # Initialize another swarm manager $ docker run -d -p 4000:4000 swarm manage -H :4000 --replication --advertise <manager1_ip>: 4000 consul://<consul_ip>:8500 # Join a worker node to the cluster $ docker run -d swarm join --advertise=<node_ip>:2375 consul://<consul_ip>:8500
  8. # docker “swarm mode” # init a new swarm cluster

    $ docker swarm init # join the node as a manager $ docker swarm join --manager <leader_ip>:2377 # join the node as worker $ docker swarm join <leader_ip>:2377
  9. # docker “swarm mode” # accept a new joining manager

    $ docker node accept <node_id> # list cluster nodes $ docker node ls
  10. # docker “swarm mode” # cluster level overlay networking $

    docker network create -d overlay <netname> # new clustered application creation $ docker service create --name <svcname> --network <netname> -p <portmapping> <image> # listing all the application in the cluster $ docker service ls
  11. # docker “swarm mode” # swarmkit’s tasks !!!!! :-) $

    docker service tasks <svcname> # up&down scaling $ docker service update --replicas 30 <svcname> # build-in routing mesh $ curl http://<any-node-ip>:<public-port>/
  12. # what’s next? § docker 1.12 is still rc3 $

    kubernetes 1.3 has been released with improved scaling and autoscaling support http://blog.kubernetes.io/2016/07/kubernetes-1.3-bridging-cloud-native-and-enterprise- workloads.html § hashicorp is pushing nomad claiming it can scale millions of containers on 5k hosts under 5 minutes https://www.hashicorp.com/c1m.html
  13. # what’s next? "We believe that we can provide a

    better user experience by integrating orchestration features into the platform itself" Mike Goelzer, Product lead for Docker Core