Docker
WHAT IS IN IT FOR MY TEAM
Why do we need Docker?
Developer/Test Concerns:
 Imagine time taken to request for new Desktop or OS upgrade
 Imagine setting up different OS environments for testing
 Imagine setting up variations of services, databases on these environments
Business concerns:
 Power, Storage and equipment costs for the above
 % of utilization of the equipment setup
 % of time taken on Infra request, setup and configuration
Docker Advantage:
 Agility: simplifies infra setup – lot of kits available
 Portability: Works here, definitely works there
 Security: Isolates from attacks/vulnerabilities
 Cost saving: Shared resources reduces investment and faster deployments reduces time/effort
What is Docker
 Docker – Build, Ship, and Run any App, Anywhere
 Old way – Development cycle
1. Develop applications in Dev environment
(Identify OS/Networking requirements, configure dev environment)
2. Deploy in production environment
3. Refine the dev environment to match production environment
Ex: install zlib
4. Re-deploy fixes, patches and releases
5. Repeat step 1 to 4 for each upgrade/migration/feature enhancement
 Docker way – Development cycle
A. Build infrastructure and the app
(Download docker container with dependencies)
B. Validate with development configurations
C. Deploy with production configurations
Minimal tuning of Step A & B – post deployment
What are fundamentals of Docker
 Virtualization:
 Creation of multiple guest context on the physical computer
 Sharing of resources – Network, storage and compute
 Containerization
 Package software into std units for dev, shipment and deployment
 Micro Services
 Architectural pattern to maintain
app(s) through multiple services
instead of a single monolithic
application
Where is Docker used?
 Docker is widely used
 within enterprises like Cisco, Technicolor
 For services such as Expedia, Paypal etc.
 For cloud dev on Amazon, Azure
 Two license types available
 Opensource: Docker Community Edition
Suggested to use this for 9 out of 10 times
 Subscription: Docker Enterprise Edition
 Available on all platforms – Windows, Linux, Mac
 Available in different forms
 Docker service
 Docker toolbox (Legacy)
What are components of Docker?
How does Docker work?
 Docker
 Docker Engine – the container manager
 Docker CLI – client which interacts through REST APIs with the Docker engine
 Example commands:
docker images
docker ps
 docker-machine
 Tool to provision multiple Docker engines
How can one start using Docker
 Install Docker on your Ubuntu desktop
(other OS also supported refer Get Docker section)
 Follow pre-requisites/commands in
https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-ce
 sudo apt-get install docker-ce
 Test your docker setup
 sudo docker run hello-world
Need internet connection
 Sudo docker run –e “http_proxy=<http url:port>” hello-world
 Explore Dockerfile to build Docker images
 For example: Dockerfile to fetch centos and to copy scripts from local directory
FROM centos
RUN mkdir -p /bin/scripts
COPY scripts /bin/scripts
 Execute: docker build .
 Explore docker-compose.yml to compose multiple images. Example of docker-compose.yml
version: '3‘
services:
app:
build: ./
image: app:v4
couchdb_service:
build: ./couchdb
image: couchdb:v1.7
 Execute
docker-compose build
or
docker-compose build app
“
”
This reduces the risk of
"worked in dev, now an ops
problem.
JAMES TURNBULL, THE DOCKER BOOK: CONTAINERIZATION IS THE NEW VIRTUALIZATION
Thank You

Docker team training

  • 1.
    Docker WHAT IS INIT FOR MY TEAM
  • 2.
    Why do weneed Docker? Developer/Test Concerns:  Imagine time taken to request for new Desktop or OS upgrade  Imagine setting up different OS environments for testing  Imagine setting up variations of services, databases on these environments Business concerns:  Power, Storage and equipment costs for the above  % of utilization of the equipment setup  % of time taken on Infra request, setup and configuration Docker Advantage:  Agility: simplifies infra setup – lot of kits available  Portability: Works here, definitely works there  Security: Isolates from attacks/vulnerabilities  Cost saving: Shared resources reduces investment and faster deployments reduces time/effort
  • 3.
    What is Docker Docker – Build, Ship, and Run any App, Anywhere  Old way – Development cycle 1. Develop applications in Dev environment (Identify OS/Networking requirements, configure dev environment) 2. Deploy in production environment 3. Refine the dev environment to match production environment Ex: install zlib 4. Re-deploy fixes, patches and releases 5. Repeat step 1 to 4 for each upgrade/migration/feature enhancement  Docker way – Development cycle A. Build infrastructure and the app (Download docker container with dependencies) B. Validate with development configurations C. Deploy with production configurations Minimal tuning of Step A & B – post deployment
  • 4.
    What are fundamentalsof Docker  Virtualization:  Creation of multiple guest context on the physical computer  Sharing of resources – Network, storage and compute  Containerization  Package software into std units for dev, shipment and deployment  Micro Services  Architectural pattern to maintain app(s) through multiple services instead of a single monolithic application
  • 5.
    Where is Dockerused?  Docker is widely used  within enterprises like Cisco, Technicolor  For services such as Expedia, Paypal etc.  For cloud dev on Amazon, Azure  Two license types available  Opensource: Docker Community Edition Suggested to use this for 9 out of 10 times  Subscription: Docker Enterprise Edition  Available on all platforms – Windows, Linux, Mac  Available in different forms  Docker service  Docker toolbox (Legacy)
  • 6.
  • 7.
    How does Dockerwork?  Docker  Docker Engine – the container manager  Docker CLI – client which interacts through REST APIs with the Docker engine  Example commands: docker images docker ps  docker-machine  Tool to provision multiple Docker engines
  • 8.
    How can onestart using Docker  Install Docker on your Ubuntu desktop (other OS also supported refer Get Docker section)  Follow pre-requisites/commands in https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-ce  sudo apt-get install docker-ce  Test your docker setup  sudo docker run hello-world Need internet connection  Sudo docker run –e “http_proxy=<http url:port>” hello-world  Explore Dockerfile to build Docker images  For example: Dockerfile to fetch centos and to copy scripts from local directory FROM centos RUN mkdir -p /bin/scripts COPY scripts /bin/scripts  Execute: docker build .  Explore docker-compose.yml to compose multiple images. Example of docker-compose.yml version: '3‘ services: app: build: ./ image: app:v4 couchdb_service: build: ./couchdb image: couchdb:v1.7  Execute docker-compose build or docker-compose build app
  • 9.
    “ ” This reduces therisk of "worked in dev, now an ops problem. JAMES TURNBULL, THE DOCKER BOOK: CONTAINERIZATION IS THE NEW VIRTUALIZATION Thank You