There's More to Docker than the Container The Docker Platform Kendrick Coleman {code} by Dell EMC @KendrickColeman github.com/kacole2 Fabio Chiodini dotnext Team Dell EMC @FabioChiodini github.com/fabiochiodini
Open source at Dell EMC {code} by Dell EMC is a group of passionate open source engineers and advocates working to build a community around software-based infrastructure. Contribute to meaningful OSS projects Create new thought leading OSS applications Drive awareness of OSS opportunities with Dell EMC product teams Participate in relevant community engagement projects Act in the interest of building a community Platinum Sponsor 2
3
4
Monolithic vs. Microservices 5
Applications Are Changing ~2000 Today Monolithic Slow changing Loosely Coupled Services Rapidly updated Big Servers Many Small Servers 6
Challenge: The Matrix From Hell Static Website User DB Analytics DB Background Workers Web Front End Queue API Endpoint Development Test & QA Production Scale Out Virtual machines Server Cluster Disaster Recovery Developer Laptop Server Data Center Public Cloud 7
2013: Enter The Docker Container Packages up software binaries and dependencies Isolates software from each other Container is a standard format Easily portable across environment Allows ecosystem to develop around its standard 8
Eliminating The Matrix Background Workers User DB Analytics DB Static Website Web Front End API Endpoint Queue Any App Anywhere Composable Dynamic Portable 9
Docker Basics Docker Image The basis of a Docker container Docker Container The standard unit in which the application service resides Docker Engine Creates, ships and runs Docker containers deployable on physical or virtual host locally, in a datacenter or cloud service provider Docker Registry/Hub On-premises registry or Docker Hub for image storing and collaboration 10
DEMO Docker basics
What Just Happened? docker run d -name webserver p 5000:80 nginx Dockerfile ############################################################ FROM debian:jessie MAINTAINER NGINX Docker Maintainers "docker-maint@nginx.com" ENV NGINX_VERSION 1.9.15-1~jessie Docker Hub Github RUN apt-key adv --keyserver hkp://pgp.mit.edu:80 --recv-keys 573BFD6B3D8FBC641079A6ABABF5BD827BD9BF62 \ && echo "deb http://nginx.org/packages/mainline/debian/ jessie nginx" >> /etc/apt/sources.list \ && apt-get update \ && apt-get install --no-install-recommends --no-install-suggests -y \ ca-certificates \ nginx=${nginx_version} \ nginx-module-xslt \ nginx-module-geoip \ nginx-module-image-filter \ nginx-module-perl \ nginx-module-njs \ gettext-base \ && rm -rf /var/lib/apt/lists/* # forward request and error logs to docker log collector RUN ln -sf /dev/stdout /var/log/nginx/access.log \ && ln -sf /dev/stderr /var/log/nginx/error.log EXPOSE 80 443 CMD ["nginx", "-g", "daemon off;"] 12
Cui Prodest? DEV - Build once, run anywhere Clean and portable runtime environment No missing dependencies during deployments Run each app in its own isolated container Improves speed and reliability of CI/CD systems Eliminates overhead issues normally associated with VMs OPS - Configure once, run anything Universal Packaging Built-in orchestration Secure by default App centric networking and service discovery Extensible architecture to work with 3 rd party integrations like storage and networking with no code changes 13
Containers vs VMs V M s App A Bins/ Libs Guest OS App A Guest OS Hypervisor Infrastructure App A Bins/ Libs Guest OS App A Bins/ Libs Original app App A Copy of app Container Runtime Operating System Infrastructure App A Modified app C O N T A I N E R S 14
!= CONTAINERS 15 DOCKER
Docker =! Containers Docker (Engine) provides application life cycle capabilities docker build. docker push. docker pull docker run... Docker Engine Registry Linux Container Containers provide a mechanism to instantiate the code (shipped as a docker image) 16 *Borrowed from@mreferre
!= DOCKER 17 DOCKER
3/2/17 https://news.ycombinator.com/item?id=13774295 18
CONTAINERD!= DOCKER 19
CONTAINERD SUPPORTS THE DOCKER PLATOFRM 20
DOCKER!= CLOUD NATIVE 21
THE CLOUD NATIVE LANDSCAPE 22 *From Cloud Native Computing Foundation (CNCF)
Docker in 2017 The docker Project Open Source Project* 3300 contributors 43K+ GitHub stars 900K+ Dockerized apps 240 Meetups in 70 countries 95K Meetup members 12B+ Docker Image Downloads 14M Docker hosts Docker Inc Containers as a Service provider Integrated platform for dev and IT Commercial technical support Docker project sponsor Primary sponsor of Docker project Supports project maintainers Dockercon 2017 Closed with 5500 attendees (4k in 2016) 23 *The original docker project is now under the name of Moby: https://github.com/moby/moby
CE vs EE DOCKER COMMUNITY EDITION FEATURES The latest Docker version with integrated tooling to build, test and run container apps Available for free with software maintenance for the latest shipping version Integrated and optimized for developer desktops, Linux servers and clouds Monthly Edge and quarterly Stable release channels available Native desktop or cloud provider experience for easy onboarding Unlimited public and one free private repo storage as a service * Automated builds as a service * Image scanning and continuous vulnerability monitoring as a service * 24
CE vs EE DOCKER ENTERPRISE EDITION FEATURES 25 Certified Infrastructure provides an integrated environment for enterprise Linux (CentOS, Oracle Linux, RHEL, SLES, Ubuntu) Windows Server 2016 and Cloud providers like AWS and Azure Certified Containers provide trusted ISV products packaged and distributed as Docker containers - built with secure best practices cooperative support Certified Plugins provide networking and volume plugins and easy to download and install containers to the Docker EE environment. REX-Ray in the Docker Store!
Why Does Dell EMC Care? Databases Postgres, MongoDB, MySQL, MariaDB, Redis, Cassandra Search, Analytics, Messaging ElasticSearch, LogStash, Kafka, RabbitMQ Content Management Wordpress, Joomla, Drupal, SugarCRM Service Discovery Consul, Zookeeper, etcd Continuous Integration and Delivery Jenkins, GitLab, SonarQube, Selenium, Nexus Custom Applications That Java app your company built Stateful and persistent applications 26
What's the problem? When I run a persistent application in a container, where does my data get stored? The container holds the data directory and structure of the entire application Optionally use local volumes Stateless applications work well nginx, httpd, kibana, haproxy, memcached, solr, celery redisdata /etc /var /bin /opt /data $ docker r un - v r edi sdat a: /data r edi s 27
What's the problem? Lose a container Lose the data Lose a server Lose the data /etc /var /bin /opt /data Local data storage Failed hard drives or failed RAID Can not scale beyond the physical limit of the server 28
Introducing REX-Ray The leading container storage orchestration engine enabling persistence for cloud native workloads Cloud Native Interoperability Open Source 29 REX-Ray rexray.codedellemc.com Enterprise Ready High Availability CLI Intuitiveness Effortless Deployment Architectural Choices Multi-Platform Storage Management Storage agnostic (block/file/object)
Solving the problem REX-Ray is installed and configured on all hosts in the cluster as a stateless service REX-Ray acts as storage plug-in and container engines re-direct storage operations to REX-Ray Create/Mount/Unmount/Delete/Sna pshot /etc /var /bin /opt /data /redisdata $ docker r un --vol ume- dr i ver =r exr ay - v r edi sdat a: / dat a r edi s 30
Solving the problem Lose the container or lose the server Data persists and remains intact on the remote storage platform /etc /var /bin /opt /redisdata 31
Solving the problem Attach the volume to a new container on a different host Equivalent of a hard reset. Application starts and resumes from the last write to disk Container schedulers can perform automated failover Scalability Application data can scale to the maximum supported by the storage platform /etc /var /bin /opt /data /redisdata 32
DEMO REX-Ray = Container Persistence
Docker For 34
35
Introducing Docker Infrakit Common Infrastructure Experience Declarative, Self-Healing Configuration
Declarative & Self-Healing Infrastructure Groups Instances Flavors Cluster Configuration Comprised of Instances & Flavor Combination Logical Cluster Instance. i.e. EC2 Image, Vagrant VM, Physical Host Role & Healthcheck. i.e. Zookeeper, Swarm Node, etc.
Consistent User Experience for Docker Everywhere RackHD
What Makes RackHD Different? RackHD Capabilities DISCOVERY & CATALOGING TELEMETRY & GENEALOGY DEVICE MANAGEMENT CONFIGURATION PROVISIONING FIRMWARE MANAGEMENT LOGGING ENVIRON- MENTALS FAULT DETECTION ANALYTICS DATA
Docker Infrakit + RackHD Process Flow DOCKER INFRAKIT INFRAKIT GROUP INSTANCE FLAVOR RACKHD WORKFLOW API MONGODB IPMI / OBM DHCP PXE / TFTP SYSLOG RABBITMQ 40 https://github.com/codedellemc/infrakit.rackhd
How to get Started Discover Hardware 1. PXE Boot Bare Metal for Passive Discovery 2. Define a server SKU Provision Clusters 1. Configure an Infrakit Cluster Configuration 2. Run Infrakit Provisioning 3. Create a custom workflow, if needed 41 https://github.com/codedellemc/infrakit.rackhd
DOCKER SWARM (swarmkit) Provides native clustering capabilities to turn a group of Docker engines into a single, virtual Docker Engine. Scale out your application as if it were running on a single, huge computer 42
DEMO Docker Swarm
Learn More Cloud Native Training https://github.com/dotnext/training {code} Labs https://github.com/codedellemc/labs Join {code} Community community.codedellemc.com/ 44
Kendrick Coleman @KendrickColeman github.com/kacole2 Fabio Chiodini @FabioChiodini github.com/fabiochiodini HOL01 Use REX-Ray & ScaleIO w/ Docker, Mesos and Kubernetes rexray.codedellemc.com codedellemc.com community.codedellemc.com @codedellemc {code} by Dell EMC is a group of passionate open source engineers and advocates working to build a community around software-based infrastructure. blog.codedellemc.com github.com/codedellemc/labs 45