SlideShare una empresa de Scribd logo
1 de 54
AKS: Kubernetes e Azure
alla massima potenza
Alessandro Melchiori // @amelchiori
Monolith vs
microservice(s)
Monolith
The Good
● Fewer moving parts enables easy
deployment
Monolith
The “Good”
● Fewer moving parts enables easy
deployment
The “Bad”
● Longer Release cycles
● Update to one functionality requires
redeployment of the entire codebase
The biggest questions ever asked (some of)
● Is the universe deterministic?
The biggest questions ever asked (some of)
● Is the universe deterministic?
● What happens after you die?
The biggest questions ever asked (some of)
● Is the universe deterministic?
● What happens after you die?
● What is life?
The biggest questions ever asked (some of)
● Is the universe deterministic?
● What happens after you die?
● What is life?
● What is a microservice?
Microservice architecture
The “Good”
● An application is sum of its
components
● Better fault isolation
● Components can be spread across
multiple servers
The “Bad”
● Many components, many moving
parts
● Difficult to manage inter-
communication
● Manual management can be
difficult
Microservice architecture
The “Good”
● An application is sum of its
components
● Better fault isolation
● Components can be spread across
multiple servers
The “Bad”
● Many components, many moving
parts
● Difficult to manage inter-
communication
● Manual management can be
difficult
Welcome
Kubernetes
Kubernetes
Greek for “Helmsman” < the person who steers a ship
Kubernetes
Greek for “Helmsman” < the person who steers a ship
K8s
Greek for “Helmsman” < the person who steers a ship
● Born in Google
● Donated to CNCF in 2014
● Open source (Apache 2.0)
● v1.0 July 2015
● Written in Go/Golang
● Code is on GitHub (where otherwise?)
K8s: some infos
K8s: big picture view
● The Master is responsible for
managing the cluster
K8s: big picture view
● The Master is responsible for
managing the cluster
● A node is a VM or a physical
computer that serves as a worker
machine in a Kubernetes cluster.
Master(s)
The K8s control plane
K8s: master components
K8s: master components
kube-apiserver
Component on the master that exposes the
Kubernetes API. It is the front-end for the
Kubernetes control plane.
It is designed to scale horizontally
K8s: master components
etcd
Consistent and highly-available key value
store used as Kubernetes’ backing store for
all cluster data.
K8s: master components
kube-scheduler
Component on the master that watches
newly created pods that have no node
assigned, and selects a node for them to
run on.
K8s: master components
kube-controller-manager
Component on the master that runs
controllers:
● Node controller
● Replication controller
● Endpoints controller
● Service Account & Token controller
Node(s)
The K8s workers
K8s: node components
K8s: master components
kubelet
An agent that runs on each node in the
cluster. It makes sure that containers are
running in a pod.
K8s: master components
kube-proxy
It is like the network brain of the node. It is
a network proxy which reflects Kubernetes
networking services on each node.
K8s: master components
Container runtime
It’s the software that is responsible for
running containers. Kubernetes supports
several runtimes: Docker, rkt, runc and any
OCI runtime-spec implementation.
K8s objects
K8s objects overview
Kubernetes contains a number of abstractions that represent the state of your
system: deployed containerized applications and workloads, their associated
network and disk resources, and other information about what your cluster is
doing.
These abstractions are represented by objects in the Kubernetes API
K8s objects
Basic Kubernetes objects:
● Pod
● Service
● Volume
● Namespace
K8s objects
Basic Kubernetes objects:
● Pod
● Service
● Volume
● Namespace
Higher-level abstraction (controllers):
● ReplicaSet
● Deployment
● StatefulSet
● DaemonSet
● Job
Declarative model
&
Desired state
Management techniques
The kubectl command-line tool supports several different ways to create and
manage Kubernetes objects:
● Imperative commands
● Imperative object configuration
● Declarative object configuration
Imperative commands
The simplest way to get started or to run a one-off task in a cluster.
kubectl run nginx --image nginx
Imperative commands
Pro:
● Commands are simple, easy to
learn and easy to remember.
● Commands require only a single
step to make changes to the
cluster
Cons:
● Commands do not integrate with
change review processes.
● Commands do not provide an
audit trail associated with
changes.
Imperative object configuration
In imperative object configuration, the kubectl command specifies the
operation (create, replace, etc.), optional flags and at least one file name.
The file specified must contain a full definition of the object in YAML or JSON
format.
kubectl create -f nginx.yaml
Imperative object configuration
Pro:
● Object configuration can be stored
in a source control system such as
Git (vs. imperative commands)
● It’s simpler and easier to
understand (vs. declarative object
configuration)
Cons:
● Object configuration requires
basic understanding of the object
schema (vs. imparative commands)
● It works best on files, not
directories (vs. declarative object
configuration)
● Updates to live objects must be
reflected in configuration files, or
they will be lost during the next
replacement (vs. declarative object
configuration)
Declarative object configuration
Using declarative object configuration, a user operates on object configuration
files stored locally, however the user does not define the operations to be
taken on the files.
Create, update, and delete operations are automatically detected per-object by
kubectl.
kubectl apply -f configs/
Declarative object configuration
Pro:
● Changes made directly to live
objects are retained, even if they
are not merged back into the
configuration files
● It has better support for operating
on directories and automatically
detecting operation types per-
object
Cons:
● Declarative object configuration is
harder to debug
Pods, Services and
Deployment
Pod overview
● Is the basic building block of Kubernetes
● Represents a running process on the
cluster
● Consists of either a single container or a
small number of containers that are
tightly coupled and that share resources
Pod phases
Pods are mortal
The phase of a Pod is a simple, high-level
summary of where the Pod is in its lifecycle:
● Pending
● Running
● Succeeded
● Failed
● Unknown
Service overview
P frontend
10.0.0.12
P frontend
10.0.0.83
P frontend
10.0.0.25
P frontend
10.0.0.39
P backend
10.0.0.41
P backend
10.0.0.44
Service overview
P frontend
10.0.0.12
P frontend
10.0.0.83
P frontend
10.0.0.25
P frontend
10.0.0.39
P backend
10.0.0.41
P backend
10.0.0.44
Service overview
P frontend
10.0.0.12
P frontend
10.0.0.83
P frontend
10.0.0.25
P frontend
10.0.0.39
P backend
10.0.0.41
P backend
10.0.0.81
Service overview
P frontend
10.0.0.12
P frontend
10.0.0.83
P frontend
10.0.0.25
P frontend
10.0.0.39
P backend
10.0.0.41
P backend
10.0.0.44
P DNS:
be.myservice
10.0.0.27
Service overview
● Service is an abstraction which defines a logical
set of Pods and a policy by which to access
them
Service overview
● Service is an abstraction which defines a logical
set of Pods and a policy by which to access
them
● The set of Pods targeted by a Service is
(usually) determined by a Label Selector
Deployment overview
● It provides declarative updates for Pods
and ReplicaSets.
● You describe a desired state in a
Deployment object, and the Deployment
controller changes the actual state to
the desired state at a controlled rate.
K8s + Azure = AKS
Self-hosting K8s cluster
Manually install master
and worker nodes
Need to consider master HA,
adding additional worker
nodes, patching, updates, ...
Azure Kubernetes Service
● Simplifies deployment, management and
operations of K8s
● Makes it quick and easy to deploy and manage
containerized applications without container
orchestration expertise
● Eliminates the burden of ongoing operations and
maintenance by provisioning, upgrading and
scaling resources on demand

Más contenido relacionado

La actualidad más candente

Introduction to Kubernetes
Introduction to KubernetesIntroduction to Kubernetes
Introduction to KubernetesAmy Chen
 
Truemotion Adventures in Containerization
Truemotion Adventures in ContainerizationTruemotion Adventures in Containerization
Truemotion Adventures in ContainerizationRyan Hunter
 
Deploying your first application with Kubernetes
Deploying your first application with KubernetesDeploying your first application with Kubernetes
Deploying your first application with KubernetesOVHcloud
 
Service Discovery In Kubernetes
Service Discovery In KubernetesService Discovery In Kubernetes
Service Discovery In KubernetesKnoldus Inc.
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopBob Killen
 
Kubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleKubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleStephen Gordon
 
Container orchestration and microservices world
Container orchestration and microservices worldContainer orchestration and microservices world
Container orchestration and microservices worldKarol Chrapek
 
K8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingK8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingPiotr Perzyna
 
Demystifying the Nuts & Bolts of Kubernetes Architecture
Demystifying the Nuts & Bolts of Kubernetes ArchitectureDemystifying the Nuts & Bolts of Kubernetes Architecture
Demystifying the Nuts & Bolts of Kubernetes ArchitectureAjeet Singh Raina
 
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas Hoppe
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas HoppeOSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas Hoppe
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas HoppeNETWAYS
 
Kubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewKubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewBob Killen
 
Brief Introduction To Kubernetes
Brief Introduction To KubernetesBrief Introduction To Kubernetes
Brief Introduction To KubernetesAvinash Ketkar
 
Learn kubernetes in 90 minutes
Learn kubernetes in 90 minutesLearn kubernetes in 90 minutes
Learn kubernetes in 90 minutesLarry Cai
 
Architectural caching patterns for kubernetes
Architectural caching patterns for kubernetesArchitectural caching patterns for kubernetes
Architectural caching patterns for kubernetesRafał Leszko
 
Kubernetes Security Updates from Kubecon 2018 Seattle
Kubernetes Security Updates from Kubecon 2018 SeattleKubernetes Security Updates from Kubecon 2018 Seattle
Kubernetes Security Updates from Kubecon 2018 SeattleSuraj Deshmukh
 
Leveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettLeveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettDocker, Inc.
 
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStack
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStackBitfusion Saltconf16 - Seamless Docker Orchestration with SaltStack
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStackSubbu Rama
 
Kubernetes fundamentals
Kubernetes fundamentalsKubernetes fundamentals
Kubernetes fundamentalsVictor Morales
 

La actualidad más candente (20)

Introduction to Kubernetes
Introduction to KubernetesIntroduction to Kubernetes
Introduction to Kubernetes
 
Truemotion Adventures in Containerization
Truemotion Adventures in ContainerizationTruemotion Adventures in Containerization
Truemotion Adventures in Containerization
 
Deploying your first application with Kubernetes
Deploying your first application with KubernetesDeploying your first application with Kubernetes
Deploying your first application with Kubernetes
 
Service Discovery In Kubernetes
Service Discovery In KubernetesService Discovery In Kubernetes
Service Discovery In Kubernetes
 
Introduction to Kubernetes Workshop
Introduction to Kubernetes WorkshopIntroduction to Kubernetes Workshop
Introduction to Kubernetes Workshop
 
Kubernetes and OpenStack at Scale
Kubernetes and OpenStack at ScaleKubernetes and OpenStack at Scale
Kubernetes and OpenStack at Scale
 
Container orchestration and microservices world
Container orchestration and microservices worldContainer orchestration and microservices world
Container orchestration and microservices world
 
K8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals TrainingK8s in 3h - Kubernetes Fundamentals Training
K8s in 3h - Kubernetes Fundamentals Training
 
Demystifying the Nuts & Bolts of Kubernetes Architecture
Demystifying the Nuts & Bolts of Kubernetes ArchitectureDemystifying the Nuts & Bolts of Kubernetes Architecture
Demystifying the Nuts & Bolts of Kubernetes Architecture
 
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas Hoppe
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas HoppeOSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas Hoppe
OSDC 2018 | Self Hosted bare Metal Kubernetes for SMEs by Thomas Hoppe
 
Kubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive OverviewKubernetes - A Comprehensive Overview
Kubernetes - A Comprehensive Overview
 
Brief Introduction To Kubernetes
Brief Introduction To KubernetesBrief Introduction To Kubernetes
Brief Introduction To Kubernetes
 
Learn kubernetes in 90 minutes
Learn kubernetes in 90 minutesLearn kubernetes in 90 minutes
Learn kubernetes in 90 minutes
 
Kubernetes @ meetic
Kubernetes @ meeticKubernetes @ meetic
Kubernetes @ meetic
 
Architectural caching patterns for kubernetes
Architectural caching patterns for kubernetesArchitectural caching patterns for kubernetes
Architectural caching patterns for kubernetes
 
Kubernetes Security Updates from Kubecon 2018 Seattle
Kubernetes Security Updates from Kubecon 2018 SeattleKubernetes Security Updates from Kubecon 2018 Seattle
Kubernetes Security Updates from Kubecon 2018 Seattle
 
Leveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettLeveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan Hazlett
 
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStack
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStackBitfusion Saltconf16 - Seamless Docker Orchestration with SaltStack
Bitfusion Saltconf16 - Seamless Docker Orchestration with SaltStack
 
Extending Kubernetes
Extending KubernetesExtending Kubernetes
Extending Kubernetes
 
Kubernetes fundamentals
Kubernetes fundamentalsKubernetes fundamentals
Kubernetes fundamentals
 

Similar a Aks: k8s e azure

DevOps Days Boston 2017: Real-world Kubernetes for DevOps
DevOps Days Boston 2017: Real-world Kubernetes for DevOpsDevOps Days Boston 2017: Real-world Kubernetes for DevOps
DevOps Days Boston 2017: Real-world Kubernetes for DevOpsAmbassador Labs
 
A quick tour around Azure Dev Spaces
A quick tour around Azure Dev SpacesA quick tour around Azure Dev Spaces
A quick tour around Azure Dev SpacesAlessandro Melchiori
 
Introduction to kubernetes
Introduction to kubernetesIntroduction to kubernetes
Introduction to kubernetesRishabh Indoria
 
Intro to Kubernetes & GitOps Workshop
Intro to Kubernetes & GitOps WorkshopIntro to Kubernetes & GitOps Workshop
Intro to Kubernetes & GitOps WorkshopWeaveworks
 
Ultimate Guide to Microservice Architecture on Kubernetes
Ultimate Guide to Microservice Architecture on KubernetesUltimate Guide to Microservice Architecture on Kubernetes
Ultimate Guide to Microservice Architecture on Kuberneteskloia
 
Free GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsFree GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsWeaveworks
 
08 - kubernetes.pptx
08 - kubernetes.pptx08 - kubernetes.pptx
08 - kubernetes.pptxRanjithM61
 
Kubernetes presentation
Kubernetes presentationKubernetes presentation
Kubernetes presentationGauranG Bajpai
 
Introduction to kubernetes
Introduction to kubernetesIntroduction to kubernetes
Introduction to kubernetesGabriel Carro
 
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang Wang
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang WangVirtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang Wang
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang WangFlink Forward
 
Containers kuberenetes
Containers kuberenetesContainers kuberenetes
Containers kuberenetescsegayan
 
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...Puppet
 
Nugwc k8s session-16-march-2021
Nugwc k8s session-16-march-2021Nugwc k8s session-16-march-2021
Nugwc k8s session-16-march-2021Avanti Patil
 
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes Clusters
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes ClustersFrom Rollercoasters to Meerkats: 3 Generations of Production Kubernetes Clusters
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes ClustersMatthew Barker
 
(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive OverviewBob Killen
 

Similar a Aks: k8s e azure (20)

AKS: k8s e azure
AKS: k8s e azureAKS: k8s e azure
AKS: k8s e azure
 
DevOps Days Boston 2017: Real-world Kubernetes for DevOps
DevOps Days Boston 2017: Real-world Kubernetes for DevOpsDevOps Days Boston 2017: Real-world Kubernetes for DevOps
DevOps Days Boston 2017: Real-world Kubernetes for DevOps
 
A quick tour around Azure Dev Spaces
A quick tour around Azure Dev SpacesA quick tour around Azure Dev Spaces
A quick tour around Azure Dev Spaces
 
Introduction to kubernetes
Introduction to kubernetesIntroduction to kubernetes
Introduction to kubernetes
 
Intro to Kubernetes & GitOps Workshop
Intro to Kubernetes & GitOps WorkshopIntro to Kubernetes & GitOps Workshop
Intro to Kubernetes & GitOps Workshop
 
Ultimate Guide to Microservice Architecture on Kubernetes
Ultimate Guide to Microservice Architecture on KubernetesUltimate Guide to Microservice Architecture on Kubernetes
Ultimate Guide to Microservice Architecture on Kubernetes
 
Free GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOpsFree GitOps Workshop + Intro to Kubernetes & GitOps
Free GitOps Workshop + Intro to Kubernetes & GitOps
 
08 - kubernetes.pptx
08 - kubernetes.pptx08 - kubernetes.pptx
08 - kubernetes.pptx
 
Kubernetes 101
Kubernetes 101Kubernetes 101
Kubernetes 101
 
Kubernetes PPT.pptx
Kubernetes PPT.pptxKubernetes PPT.pptx
Kubernetes PPT.pptx
 
Kubernetes presentation
Kubernetes presentationKubernetes presentation
Kubernetes presentation
 
Introduction to kubernetes
Introduction to kubernetesIntroduction to kubernetes
Introduction to kubernetes
 
Containers kuberenetes
Containers kuberenetesContainers kuberenetes
Containers kuberenetes
 
Containers kuberenetes
Containers kuberenetesContainers kuberenetes
Containers kuberenetes
 
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang Wang
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang WangVirtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang Wang
Virtual Flink Forward 2020: Integrate Flink with Kubernetes natively - Yang Wang
 
Containers kuberenetes
Containers kuberenetesContainers kuberenetes
Containers kuberenetes
 
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...
PuppetConf 2017: From Rollercoasters to Meerkats: 3 Generations of Production...
 
Nugwc k8s session-16-march-2021
Nugwc k8s session-16-march-2021Nugwc k8s session-16-march-2021
Nugwc k8s session-16-march-2021
 
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes Clusters
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes ClustersFrom Rollercoasters to Meerkats: 3 Generations of Production Kubernetes Clusters
From Rollercoasters to Meerkats: 3 Generations of Production Kubernetes Clusters
 
(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview(Draft) Kubernetes - A Comprehensive Overview
(Draft) Kubernetes - A Comprehensive Overview
 

Más de Alessandro Melchiori

Developing reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSDeveloping reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSAlessandro Melchiori
 
Developing reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSDeveloping reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSAlessandro Melchiori
 
How to search...better! (azure search)
How to search...better! (azure search)How to search...better! (azure search)
How to search...better! (azure search)Alessandro Melchiori
 
Azure functions: from a function to a whole application in 60 minutes
Azure functions: from a function to a whole application in 60 minutesAzure functions: from a function to a whole application in 60 minutes
Azure functions: from a function to a whole application in 60 minutesAlessandro Melchiori
 
Monitoring docker: from zero to Azure
Monitoring docker: from zero to AzureMonitoring docker: from zero to Azure
Monitoring docker: from zero to AzureAlessandro Melchiori
 
Cooking Akka.net and Azure Service Fabric together
Cooking Akka.net and Azure Service Fabric togetherCooking Akka.net and Azure Service Fabric together
Cooking Akka.net and Azure Service Fabric togetherAlessandro Melchiori
 
ACR + ACS + VSTS: a complete ALM pipeline with docker and azure
ACR + ACS + VSTS: a complete ALM pipeline with docker and azureACR + ACS + VSTS: a complete ALM pipeline with docker and azure
ACR + ACS + VSTS: a complete ALM pipeline with docker and azureAlessandro Melchiori
 
Come ti "pusho" il web con WebSockets: da 0 a SignalR
Come ti "pusho" il web con WebSockets: da 0 a SignalR Come ti "pusho" il web con WebSockets: da 0 a SignalR
Come ti "pusho" il web con WebSockets: da 0 a SignalR Alessandro Melchiori
 
Azure service fabric: a gentle introduction
Azure service fabric: a gentle introductionAzure service fabric: a gentle introduction
Azure service fabric: a gentle introductionAlessandro Melchiori
 
From CRUD to messages: a true story
From CRUD to messages: a true storyFrom CRUD to messages: a true story
From CRUD to messages: a true storyAlessandro Melchiori
 

Más de Alessandro Melchiori (20)

Scale your (aks) cluster, luke!
Scale your (aks) cluster, luke!Scale your (aks) cluster, luke!
Scale your (aks) cluster, luke!
 
A quick introduction to AKS
A quick introduction to AKSA quick introduction to AKS
A quick introduction to AKS
 
Developing reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSDeveloping reliable applications with .net core and AKS
Developing reliable applications with .net core and AKS
 
VS Code tools for docker
VS Code tools for dockerVS Code tools for docker
VS Code tools for docker
 
Developing reliable applications with .net core and AKS
Developing reliable applications with .net core and AKSDeveloping reliable applications with .net core and AKS
Developing reliable applications with .net core and AKS
 
How to search...better! (azure search)
How to search...better! (azure search)How to search...better! (azure search)
How to search...better! (azure search)
 
How to search...better!
How to search...better!How to search...better!
How to search...better!
 
Azure functions: from a function to a whole application in 60 minutes
Azure functions: from a function to a whole application in 60 minutesAzure functions: from a function to a whole application in 60 minutes
Azure functions: from a function to a whole application in 60 minutes
 
Monitoring docker: from zero to Azure
Monitoring docker: from zero to AzureMonitoring docker: from zero to Azure
Monitoring docker: from zero to Azure
 
Cooking Akka.net and Azure Service Fabric together
Cooking Akka.net and Azure Service Fabric togetherCooking Akka.net and Azure Service Fabric together
Cooking Akka.net and Azure Service Fabric together
 
Azure data platform overview
Azure data platform overviewAzure data platform overview
Azure data platform overview
 
ACR + ACS + VSTS: a complete ALM pipeline with docker and azure
ACR + ACS + VSTS: a complete ALM pipeline with docker and azureACR + ACS + VSTS: a complete ALM pipeline with docker and azure
ACR + ACS + VSTS: a complete ALM pipeline with docker and azure
 
Docker & Azure
Docker & AzureDocker & Azure
Docker & Azure
 
Docker and Azure
Docker and AzureDocker and Azure
Docker and Azure
 
Come ti "pusho" il web con WebSockets: da 0 a SignalR
Come ti "pusho" il web con WebSockets: da 0 a SignalR Come ti "pusho" il web con WebSockets: da 0 a SignalR
Come ti "pusho" il web con WebSockets: da 0 a SignalR
 
Docker &amp; azure
Docker &amp; azureDocker &amp; azure
Docker &amp; azure
 
Azure service fabric: a gentle introduction
Azure service fabric: a gentle introductionAzure service fabric: a gentle introduction
Azure service fabric: a gentle introduction
 
From CRUD to messages: a true story
From CRUD to messages: a true storyFrom CRUD to messages: a true story
From CRUD to messages: a true story
 
Functional Reactive Programming
Functional Reactive ProgrammingFunctional Reactive Programming
Functional Reactive Programming
 
Functional DDD
Functional DDDFunctional DDD
Functional DDD
 

Último

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 

Último (20)

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 

Aks: k8s e azure

  • 1. AKS: Kubernetes e Azure alla massima potenza Alessandro Melchiori // @amelchiori
  • 3. Monolith The Good ● Fewer moving parts enables easy deployment
  • 4. Monolith The “Good” ● Fewer moving parts enables easy deployment The “Bad” ● Longer Release cycles ● Update to one functionality requires redeployment of the entire codebase
  • 5. The biggest questions ever asked (some of) ● Is the universe deterministic?
  • 6. The biggest questions ever asked (some of) ● Is the universe deterministic? ● What happens after you die?
  • 7. The biggest questions ever asked (some of) ● Is the universe deterministic? ● What happens after you die? ● What is life?
  • 8. The biggest questions ever asked (some of) ● Is the universe deterministic? ● What happens after you die? ● What is life? ● What is a microservice?
  • 9.
  • 10. Microservice architecture The “Good” ● An application is sum of its components ● Better fault isolation ● Components can be spread across multiple servers The “Bad” ● Many components, many moving parts ● Difficult to manage inter- communication ● Manual management can be difficult
  • 11. Microservice architecture The “Good” ● An application is sum of its components ● Better fault isolation ● Components can be spread across multiple servers The “Bad” ● Many components, many moving parts ● Difficult to manage inter- communication ● Manual management can be difficult
  • 13. Kubernetes Greek for “Helmsman” < the person who steers a ship
  • 14. Kubernetes Greek for “Helmsman” < the person who steers a ship
  • 15. K8s Greek for “Helmsman” < the person who steers a ship
  • 16. ● Born in Google ● Donated to CNCF in 2014 ● Open source (Apache 2.0) ● v1.0 July 2015 ● Written in Go/Golang ● Code is on GitHub (where otherwise?) K8s: some infos
  • 17. K8s: big picture view ● The Master is responsible for managing the cluster
  • 18. K8s: big picture view ● The Master is responsible for managing the cluster ● A node is a VM or a physical computer that serves as a worker machine in a Kubernetes cluster.
  • 21. K8s: master components kube-apiserver Component on the master that exposes the Kubernetes API. It is the front-end for the Kubernetes control plane. It is designed to scale horizontally
  • 22. K8s: master components etcd Consistent and highly-available key value store used as Kubernetes’ backing store for all cluster data.
  • 23. K8s: master components kube-scheduler Component on the master that watches newly created pods that have no node assigned, and selects a node for them to run on.
  • 24. K8s: master components kube-controller-manager Component on the master that runs controllers: ● Node controller ● Replication controller ● Endpoints controller ● Service Account & Token controller
  • 27. K8s: master components kubelet An agent that runs on each node in the cluster. It makes sure that containers are running in a pod.
  • 28. K8s: master components kube-proxy It is like the network brain of the node. It is a network proxy which reflects Kubernetes networking services on each node.
  • 29. K8s: master components Container runtime It’s the software that is responsible for running containers. Kubernetes supports several runtimes: Docker, rkt, runc and any OCI runtime-spec implementation.
  • 31. K8s objects overview Kubernetes contains a number of abstractions that represent the state of your system: deployed containerized applications and workloads, their associated network and disk resources, and other information about what your cluster is doing. These abstractions are represented by objects in the Kubernetes API
  • 32. K8s objects Basic Kubernetes objects: ● Pod ● Service ● Volume ● Namespace
  • 33. K8s objects Basic Kubernetes objects: ● Pod ● Service ● Volume ● Namespace Higher-level abstraction (controllers): ● ReplicaSet ● Deployment ● StatefulSet ● DaemonSet ● Job
  • 35. Management techniques The kubectl command-line tool supports several different ways to create and manage Kubernetes objects: ● Imperative commands ● Imperative object configuration ● Declarative object configuration
  • 36. Imperative commands The simplest way to get started or to run a one-off task in a cluster. kubectl run nginx --image nginx
  • 37. Imperative commands Pro: ● Commands are simple, easy to learn and easy to remember. ● Commands require only a single step to make changes to the cluster Cons: ● Commands do not integrate with change review processes. ● Commands do not provide an audit trail associated with changes.
  • 38. Imperative object configuration In imperative object configuration, the kubectl command specifies the operation (create, replace, etc.), optional flags and at least one file name. The file specified must contain a full definition of the object in YAML or JSON format. kubectl create -f nginx.yaml
  • 39. Imperative object configuration Pro: ● Object configuration can be stored in a source control system such as Git (vs. imperative commands) ● It’s simpler and easier to understand (vs. declarative object configuration) Cons: ● Object configuration requires basic understanding of the object schema (vs. imparative commands) ● It works best on files, not directories (vs. declarative object configuration) ● Updates to live objects must be reflected in configuration files, or they will be lost during the next replacement (vs. declarative object configuration)
  • 40. Declarative object configuration Using declarative object configuration, a user operates on object configuration files stored locally, however the user does not define the operations to be taken on the files. Create, update, and delete operations are automatically detected per-object by kubectl. kubectl apply -f configs/
  • 41. Declarative object configuration Pro: ● Changes made directly to live objects are retained, even if they are not merged back into the configuration files ● It has better support for operating on directories and automatically detecting operation types per- object Cons: ● Declarative object configuration is harder to debug
  • 43. Pod overview ● Is the basic building block of Kubernetes ● Represents a running process on the cluster ● Consists of either a single container or a small number of containers that are tightly coupled and that share resources
  • 44. Pod phases Pods are mortal The phase of a Pod is a simple, high-level summary of where the Pod is in its lifecycle: ● Pending ● Running ● Succeeded ● Failed ● Unknown
  • 45. Service overview P frontend 10.0.0.12 P frontend 10.0.0.83 P frontend 10.0.0.25 P frontend 10.0.0.39 P backend 10.0.0.41 P backend 10.0.0.44
  • 46. Service overview P frontend 10.0.0.12 P frontend 10.0.0.83 P frontend 10.0.0.25 P frontend 10.0.0.39 P backend 10.0.0.41 P backend 10.0.0.44
  • 47. Service overview P frontend 10.0.0.12 P frontend 10.0.0.83 P frontend 10.0.0.25 P frontend 10.0.0.39 P backend 10.0.0.41 P backend 10.0.0.81
  • 48. Service overview P frontend 10.0.0.12 P frontend 10.0.0.83 P frontend 10.0.0.25 P frontend 10.0.0.39 P backend 10.0.0.41 P backend 10.0.0.44 P DNS: be.myservice 10.0.0.27
  • 49. Service overview ● Service is an abstraction which defines a logical set of Pods and a policy by which to access them
  • 50. Service overview ● Service is an abstraction which defines a logical set of Pods and a policy by which to access them ● The set of Pods targeted by a Service is (usually) determined by a Label Selector
  • 51. Deployment overview ● It provides declarative updates for Pods and ReplicaSets. ● You describe a desired state in a Deployment object, and the Deployment controller changes the actual state to the desired state at a controlled rate.
  • 52. K8s + Azure = AKS
  • 53. Self-hosting K8s cluster Manually install master and worker nodes Need to consider master HA, adding additional worker nodes, patching, updates, ...
  • 54. Azure Kubernetes Service ● Simplifies deployment, management and operations of K8s ● Makes it quick and easy to deploy and manage containerized applications without container orchestration expertise ● Eliminates the burden of ongoing operations and maintenance by provisioning, upgrading and scaling resources on demand

Notas del editor

  1. Master components provide the cluster’s control plane. Master components make global decisions about the cluster (for example, scheduling), and detecting and responding to cluster events (starting up a new pod when a replication controller’s ‘replicas’ field is unsatisfied). Master components can be run on any machine in the cluster. However, for simplicity, set up scripts typically start all master components on the same machine, and do not run user containers on this machine.
  2. It is the brain to the master and is front-end to the master or control plane. Kube-apiserver implements the RESTful API and consumes json via a manifest file. Manifest files declare the state of the app like a record of intent and are validated and deployed on the cluster. It exposes an endpoint (by default on port 443) so that kubectl (command line utility) can issue commands/queries and run on the master.
  3. It provides persistent storage and is stateful. It uses etcd. It is distributed, consistent and watchable. etcd – etcd is open source distributed key-value store that serves as the backbone of distributed systems by providing a canonical hub for cluster coordination and state management. Kubernetes uses etcd as the “source of truth” for the cluster. It takes care of storing and replicating data used by Kubernetes across the entire cluster. It is written in Go language and uses Raft protocol, which helps etcd in recovering from hardware failure and network partitions.
  4. This is the process that watches API-server for new pods and assigns workloads to specific nodes in the cluster. It is responsible for tracking resource utilization on each host to make sure that workloads are not scheduled in excess of the available resources.
  5. Kubernetes controller manager is a daemon that implants the core control loops shipped with Kubernetes. It is the controller of controllers. It watches the shared state of the cluster through the API server and makes changes attempting to move the current state towards the desired state. Examples of controllers that ship with Kubernetes today are the replication controller, endpoints controller, namespace controller, and service accounts controller. At the point when a change is seen, the controller reads the new information and implements the procedure that fulfills the desired state. This can involve scaling an application up or down, adjusting endpoints, and so forth. A Replication controller provides a pod template for creating any number of pod copies. It provides logic for scaling pod up or down. It can also be used for rolling deployments. Node Controller: Responsible for noticing and responding when nodes go down. Replication Controller: Responsible for maintaining the correct number of pods for every replication controller object in the system. Endpoints Controller: Populates the Endpoints object (that is, joins Services & Pods). Service Account & Token Controllers: Create default accounts and API access tokens for new namespaces
  6. Node components run on every node, maintaining running pods and providing the Kubernetes runtime environment.
  7. The kubelet takes a set of PodSpecs that are provided through various mechanisms and ensures that the containers described in those PodSpecs are running and healthy. The kubelet doesn’t manage containers which were not created by Kubernetes the main Kubernetes agent on the node registers node with the cluster watches API server for work assignment instantiate pods for carrying out the work reports back to master exposes endpoint on port-10255. It lets you inspect the specs of a Kubelet.