(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
Kubernetes - A Short Ride Throught the project and its ecosystem
1. KUBERNETES - A SHORT RIDE THROUGH
THE PROJECT AND ITS ECOSYSTEM
MACIEJ KWIEK, SOFTWARE ENGINEER, MIRANTIS
2. AGENDA
▸ What is Kubernetes?
▸ How does Kubernetes work?
▸ K8s from Go developer standpoint
▸ Nice projects around K8s core
3. WHAT IS KUBERNETES?
WHAT DOES KUBERNETES MEAN? K8S?
▸ The name Kubernetes originates from Greek, meaning
“helmsman” or “pilot”, and is the root of “governor” and
“cybernetic”. K8s is an abbreviation derived by replacing
the 8 letters “ubernete” with 8.
4. WHAT IS KUBERNETES?
WHAT IS KUBERNETES?
▸ Kubernetes is an open-source system for automating
deployment, scaling, and management of containerized
applications.
5. WHAT IS KUBERNETES?
WHAT IS KUBERNETES?
▸ It groups containers that make up an application into
logical units for easy management and discovery.
6. WHAT IS KUBERNETES?
WHAT IS KUBERNETES?
▸ Kubernetes can schedule and run application containers
on clusters of physical or virtual machines.
7. WHAT IS KUBERNETES?
WHAT IS KUBERNETES?
▸ Kubernetes also allows developers to ‘cut the cord’ to
physical and virtual machines, moving from a host-centric
infrastructure to a container-centric infrastructure, which
provides the full advantages and benefits inherent to
containers.
9. HOW DOES K8S WORK?
BASIC K8S CONCEPTS - POD
▸ A Pod is the basic building block of Kubernetes–the
smallest and simplest unit in the Kubernetes object model
that you create or deploy. A Pod represents a running
process on your cluster.
10. HOW DOES K8S WORK?
BASIC K8S CONCEPTS - POD
▸ A Pod encapsulates:
▸ an application container (or, in some cases, multiple
containers)
▸ storage resources
▸ a unique network IP
▸ options that govern how the container(s) should run
11. HOW DOES K8S WORK?
BASIC K8S CONCEPTS - POD
▸ A Pod represents a unit of deployment: a single instance
of an application in Kubernetes, which might consist of
either a single container or a small number of containers
that are tightly coupled and that share resources.
14. HOW DOES K8S WORK?
K8S ARCHITECTURE
▸ Two types of components:
▸ Master
▸ Node
15. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS
▸ Master components are those that provide the cluster’s
control plane. For example, master components are
responsible for making global decisions about the cluster
(e.g., scheduling), and detecting and responding to cluster
events (e.g., starting up a new pod when a replication
controller’s ‘replicas’ field is unsatisfied).
16. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS: KUBE-APISERVER
▸ kube-apiserver exposes the Kubernetes API; it is the front-
end for the Kubernetes control plane. It is designed to
scale horizontally (i.e., one scales it by running more of
them– Building High-Availability Clusters).
17. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS: ETCD
▸ etcd is used as Kubernetes’ backing store. All cluster data
is stored here.
18. HOW DOES K8S WORK?
K8S MASTER COMPONENTS: KUBE-CONTROLLER-MANAGER
▸ kube-controller-manager is a binary that runs controllers,
which are the background threads that handle routine
tasks in the cluster. Logically, each controller is a separate
process, but to reduce the number of moving pieces in the
system, they are all compiled into a single binary and run
in a single process.
19. HOW DOES K8S WORK?
K8S MASTER COMPONENTS: KUBE-CONTROLLER-MANAGER
▸ controllers include:
▸ Node Controller: Responsible for noticing & 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 (i.e., join
Services & Pods)
▸ … others
20. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS: KUBE-SCHEDULER
▸ kube-scheduler watches newly created pods that have no
node assigned, and selects a node for them to run on.
21. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS: ADDONS
▸ Addons are pods and services that implement cluster
features. The pods may be managed by Deployments,
ReplicationContollers, etc. Namespaced addon objects are
created in the “kube-system” namespace.
▸ Addon manager takes the responsibility for creating and
maintaining addon resources. See here for more details.
22. HOW DOES K8S WORK?
K8S ARCHITECTURE - MASTER COMPONENTS: ADDONS
▸ dns
▸ kube-ui (web frontend)
▸ monitoring
▸ logging
23. HOW DOES K8S WORK?
K8S ARCHITECTURE - NODE COMPONENTS
▸ Node components run on every node, maintaining
running pods and providing them the Kubernetes runtime
environment.
24. HOW DOES K8S WORK?
K8S ARCHITECTURE - NODE COMPONENTS: KUBELET
▸ primary node agent
25. HOW DOES K8S WORK?
K8S ARCHITECTURE - NODE COMPONENTS: KUBELET
▸ Watches for pods that have been assigned to its node (either by
apiserver or via local configuration file)
▸ Mounts the pod’s required volumes
▸ Downloads the pod’s secrets
▸ Runs the pod’s containers
▸ Periodically executes any requested container liveness probes.
▸ Reports the status of the pod back to the rest of the systemReports
the status of the node back to the rest of the system.
26. HOW DOES K8S WORK?
K8S ARCHITECTURE - NODE COMPONENTS: KUBE-PROXY
▸ kube-proxy enables the Kubernetes service abstraction by
maintaining network rules on the host and performing
connection forwarding
▸ done by changing iptables on node
27. HOW DOES K8S WORK?
K8S ARCHITECTURE - NODE COMPONENTS: CONTAINER RUNTIME
▸ something that will actually run containers
32. K8S FROM GO DEVELOPER STANDPOINT
CONVENTIONS
▸ https://github.com/golang/go/wiki/
CodeReviewComments
▸ https://golang.org/doc/effective_go.html
▸ https://blog.golang.org/godoc-documenting-go-code
33. K8S FROM GO DEVELOPER STANDPOINT
LANDMINES
▸ https://gist.github.com/lavalamp/4bd23295a9f32706a48f
34. K8S FROM GO DEVELOPER STANDPOINT
FUN PROJECTS AROUND THE CORE - HELM
▸ The Kubernetes Package Manager
▸ https://github.com/kubernetes/helm
35. K8S FROM GO DEVELOPER STANDPOINT
FUN PROJECTS AROUND THE CORE - HELM
▸ Allows you to
▸ Find and use popular software packaged as Kubernetes
charts
▸ Share your own applications as Kubernetes charts
▸ Intelligently manage your Kubernetes manifest files
▸ Manage releases of Helm packages
36. K8S FROM GO DEVELOPER STANDPOINT
FUN PROJECTS AROUND THE CORE - VIRTLET
▸ Kubernetes CRI implementation for running VM workloads
▸ https://github.com/Mirantis/virtlet
37. K8S FROM GO DEVELOPER STANDPOINT
FUN PROJECTS AROUND THE CORE - APPCONTROLLER
▸ AppController is a pod that you can spawn in your
Kubernetes cluster which will take care of your complex
deployments for you
▸ https://github.com/Mirantis/k8s-AppController
▸ Becoming and optional Helm release backend: https://
github.com/nebril/rudder-appcontroller