This document discusses containers and container orchestration on Azure. It begins with an introduction to containers and their advantages over virtual machines. It then covers building Dockerfiles, container commands, and hosting container registries and applications on Azure. Container orchestration with Kubernetes is discussed as a way to deploy and scale containerized applications on the cloud, providing capabilities like auto-scaling, self-healing, service discovery and load balancing. The document points to additional future content on using Azure Kubernetes Service.
4. So now they had questions on the monolithic architecture
1. How can we put the softwares update on the cloud.
2. If we ghost the server how to create a data recovery?
3. On making the updates how to rerun the instances?
4. After running how to get the customers back for the working?(as both the
software and hardware was updated)
5. After releasing how to document it?
6. What software dependency can be used later?
5. Then came the SOA (Service Oriented Architecture)
1. How to make the people know the potential of the hardware that they are
using?
2. How to make the engineers learn the networking?
3. What if the security goes wrong?
4. What if the users don't know how to deploy the application?
6. So now when everything became coarse grain what next?
Ease the developer to just look at the business problem statement and the
cloud thus microservices came in.
7. All lead to some nice questions and they were getting
solved and then what
8.
9.
10. Agenda
● Containers Introduction
● Container commands
● Building a Dockerfile
● Containers on cloud
● Scaling containers apps on the cloud - Kubernetes
● Q&A
12. All of it started as a problem statement to make life easier
Lot of questions that they asked?
● When to pach
● When to create a backup
● When to upgrade the service
13. Getting started with container
1. Why containers?
2. What is the purpose of Building containers and Docker mainly
3. What is the main reason behind doing it?
16. Container are very light weight
SERVER
HOST OS
GUEST OS
HYPERVISOR
LIBRARIES/Bin
APP A
GUEST OS
LIBRARIES/Bin
APP B
VM
SERVER
HOST OS
APP A APP B
LIBRARIES LIBRARIES
CONTAINER
S
• Containers are isolated but share OS
• Increase the compute density and
memory utilization
DOCKER ENGINE
19. Scalable by Design
● Containers are industry leaders in the time to start new instance
● Container spin time for new instance takes seconds
● Provisioning and starting new Virtual Machines takes from 5 to 20 minutes
20. Container + Microservice
● One microservice application = one container
● Granular fast scalability
● Similar experience on workstation and production
● Hybrid environments: deploy to cloud and on-premise
29. Dockerfile instruction or argument
FROM
LABEL
RUN
WORKDIR
ADD
CMD
Thus study the documentation you will all lie it : Dockerfile reference | Docker
Documentation
30. From Dev To Ops
PHYSICAL VIRTUAL CLOUD
Any Application
31. Docker Platform
Docker Image
Docker Engine
Registry Service (Docker Hub or Docker Trusted Registry)
Cloud or server based storage and distribution service for images
Docker Container
32.
33. Docker Hub: Build, Ship, Run Applications
Build Ship
Run
Dev
QA
Source
Staging
Physical
Virtual
Cloud
InfrastructureManagement
InfrastructureManagement
DockerFile
Source Code
Repository
TEST
TEST
TEST
TEST
TEST
GCE RAX Azure
Mac/Win Dev
Machine
Boot2Docker
Docker
Analytics
DB
Prod
Machine
Linux OS
Docker
Docker
++
Users Collab
Provenance Policy
Docker Hub
Registries
Public Curated Private
Docker Hub API
Third Party Tools
Prod
Machine
Linux OS
Docker
Docker
Prod
Machine
Linux OS
Docker
Docker
VM
Docker
Docker
VM
Docker
Docker
VM
Docker
Docker
QA Machine
Linux OS
Docker
Docker
Docker Hub provides a centralized resource for container image discovery,
distribution and change management, user and team collaboration, and workflow
automation
34. Docker Hub: Build, Ship, Run Applications
Build Ship
Run
Dev
QA
Source
Staging
Physical
Virtual
Cloud
InfrastructureManagement
InfrastructureManagement
DockerFile
Source Code
Repository
TEST
TEST
TEST
TEST
TEST
GCE RAX Azure
Mac/Win Dev
Machine
Boot2Docker
Docker
Analytics
DB
Prod
Machine
Linux OS
Docker
Docker
++
Users Collab
Provenance Policy
Docker Hub
Registries
Public Curated Private
Docker Hub API
Third Party Tools
Prod
Machine
Linux OS
Docker
Docker
Prod
Machine
Linux OS
Docker
Docker
VM
Docker
Docker
VM
Docker
Docker
VM
Docker
Docker
QA Machine
Linux OS
Docker
Docker
Docker Hub provides a centralized resource for container image discovery,
distribution and change management, user and team collaboration, and workflow
automation
35. Build Docker Image
1. Available Docker Integration Build Task
2. Docker Registry Credentials Management
3. Docker Build command
4. Docker Push command
5. Docker Run command
6. Run Docker commands
7. Docker Compose support
8. Requires private VSTS agent with Docker tools
36. So we will do some cloud in the later part but for
sure we will have to do the development of the
developer environment.
37. Setting up a Dev Environment
pip install -r requirements.txt
pip freeze > requirements.txt
38. Simple steps involved
1. Develop the code and have the required reps in the file
2. Dockerfile has to be created
3. Building the docker file
4. Deploying the docker file
39. Simple steps involved
1. Develop the code and have the required reps in the file
2. Dockerfile has to be created
3. Building the docker file
4. Deploying the docker file
docker run -p 8888:8888 devenv
“The above command depends on the port that we want to expose”
40. How to access the deployed container is by
Go to your browser and in the URL tab we have to type
localhost:8888
127.0.0.1:<port>
42. Hosting Docker Registry in azure
Docker Hub with Microsoft Azure storage driver
Uses Microsoft Azure Blob Storage for object storage.
Azure Container Registry Service
managed private Docker registry in Azure
Docker Registry on VM We will not even touch this
The Registry is a stateless, highly scalable server side application that
stores and lets you distribute Docker images.
43. Docker Hub with the Storage Registry
Target VM
docker
push
docker pull
docker
run
dotnet build
docker
build
CI/CD server
Github
Read/Write
Images
pull
image
Docker
Registry
Microsoft Azure
44. Azure Container Registry Service
1. Store and manage container images across all types of Azure deployments
2. Maintain Windows and Linux container images in a single Docker registry
3. Use familiar, open-source Docker command line interface (CLI) tools
4. Simplify registry access management with Azure Active Directory
5. Pricing: Blob storage pricing model. No addition price for the Registry service
45. Azure Container Registry Service
DOCKER REGISTRY API
AZURE STORAGE ACCOUNT (LRS)
PRIVATE CONTAINER (NAME OF REGISTRY)
BLOCK BLOBS
46. On deployment part
1. Application Deployment, including rollouts and rollbacks
2. Horizontal Scaling(just like spark and other frameworks)
3. Self-healing
4. Discovery and load balancing
5. Configuration management
6. Monitoring
48. Azure Container Service
● Optimized provisioning of open-source container orchestration tools
○ Kubernetes
○ DC/OS
○ Docker Swarm
● Full automation of all orchestration platform components
● Compatible with standard open-source “orchestration API”
● ACS is a free service that clusters Virtual Machines (VMs) into a container
● Hybrid deployment for applications
49. So moral of the Story is that
Container instance is different from the Container
Registry.
That's it nothing more nothing less.
53. Scaling containers apps on the cloud - Kubernetes
Kubernetes is a very huge orchestrator thus we will touch on it in the future.(an
exclusive content on Azure Kubernetes Service)
54.
55.
56. Lets just do some demo
The github repository is mentioned here:
https://github.com/vishwas1234567/reactorfile.git