Kubernetes

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

Workers-nodes Kube-proxy

how the end user interacts w. your applications..... maintains network rules on nodes. These network rules allow network communication to your Pods from network sessions inside or outside of your cluster

Master components: etcd

Primary datastore for Kubernetes... stores all k8 info stauts certificates date of creation .. Storing and replicating all kubernetes cluster state

what are replicas

how many pods you want running if you delete on kubernetes will automatically create new one

List the nodes in your cluster, along with their labels:

kubectl get nodes --show-labels

shows pods

kubectl get pods

Kubernetes

Container Orchestration tool. Allows to easily build and manage containers. Most popular one. Manages deployment updates scales

Deployment

Desire state

command to join node to cluster -init cluster - create dir and change ownership -Calico network -command to run on worker

INIT CLUSTER kubeadm init --config kubeadm.yml in output youll see * to start using cluster* mkdir -p $HOME/.kube sudo cp -I /etc/kubernetes/admin.conf $HOME/.kube/config sudo chown $(id -u):$(id -g) $HOME/.kube/config NETWORK kubectl apply -f https://docs.projectcalico.org/v3.14/manifests/calico.yaml GIVES U COMMAND TO RUN ON WORKER kubeadm token create --print-join-command

Node

Instance of a computer. Nodes run pods

Master components: scheduler

assign unassign objects to pods, and assign pods to nodes (workers)... we don't get to choose

Master components: api-server

cannot do anything in k8 w.out it... validates and configure data for -pods, -servicers, -replicationcontrollers... all components of master and worker............................. many versions of api servers depending on deployment

go inside contINER

docker exec -it (node-id) sh

Master components: controller-manager

is a control loop that watches the shared state of the cluster through the apiserver and makes changes attempting to move the current state towards the desired state............... will automatically launch new pods, give new status

Pod

is a group of containers that exists within nodes, are deployed together on the same host.

Kubelet

is the application that is running that helps NODE communicate w. master.

to see what node your pod is connected to see IP see status- running, pending

kubctl get pods --all-namespaces -o wide

command to run on worker

kubeadm token create --print-join-command

install network plugin CALICO

kubectl apply -f https://docs.projectcalico.org/v3.14/manifests/calico.yaml

installing the ingress

kubectl apply -f https://ingressURL.yaml kubectl get ingress

.yaml create apply delete

kubectl create -f config-map.yaml kubectl apply -f config-map.yaml kubectl delete config-map.yaml

create deployment w. yml file

kubectl create -f deployment.yml (-f is for file)

create deployment nginx

kubectl create deployment nginx --tcp 80:80

create a dev namespace

kubectl create namespace dev

create service nginx

kubectl create service nodeport nginx --tcp 80:80

go inside node

kubectl exec -it (node-id) sh

shows deployment

kubectl get deployments

0check all namespacesb

kubectl get pods --all-namespaces

gets the pods for the dev namespace

kubectl get pods -n dev

get svc

kubectl get svc

ingress

loadbalancer between apps

Workers-nodes Kubelet

monitoring the Object Store for assigned Pods, will execute the Pod..................... .connection btwn worker and master

remove taint from master-

taint nodes $(hostname) node-role.kubernetes.io/master:NoSchedule

creating app apple accessing app

vi apple.yaml kubectl create -f apple.yaml kubectl apply -f apple.yaml kubectl get svc curl -kL http://custerIP/apple


Set pelajaran terkait

Chapter 6 Values, Ethics, and Advocacy

View Set

OMW Midterm (Protestant Reformation)

View Set