-
Notifications
You must be signed in to change notification settings - Fork 50
/
Copy pathsession-67.txt
66 lines (40 loc) · 2.55 KB
/
session-67.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
K8 Architecture
------------------
master
node
API server --> it is the main component responding to all user requests. It runs on https port 443
Scheduler --> responsible to schedule the pods on to nodes. it checks multiple things while scheduling. taints and tolerations, node selectors, affinity, underlying server memory, their cpu consumption etc.
Controll manager
--------------
replica controller componen --> replicaset --> if you delete the pods, it will automatically create new pod
node controller --> checks the nodes all the time, whether they are ready, able to schedule r not. if a node is down it will make sure another node is created and shift the pods to diff nodes
ServiceAccount controller --> creates service account for every namespace created. basically under internal authentication
etcd
-----------
entire k8 cluster data is in etcd. it is very important to take frequent backup. if cloud, they are responsible for this
Node components
--------------------
kube-proxy --> on behalf of someone. it intercepts every incoming and outgoing request of node. kube-proxy maintains network rules on nodes. hese network rules allow network communication to your Pods
kubelet --> it connects nodes to control plane. An agent that runs on each node in the cluster. it pulls the information from control plane and runs the pods.
container run time --> it is on every node, it basically runs the images into containers. containerd is the runtime usually.
Add-ons
-----------
kube-dns --> provides DNS to the pods. http://backend:8080. kubedns provides IP address to the service when one pod wants to connect with other pod.
networking plugins --> VPC CNI, default network inside EKS.
aws eks update-kubeconfig --region us-east-1 --name expense-dev
DB
------
check the schema created or not
check the tables created or not to store the data
check the users created or not
create namespace
kubectl create namespace expense
configure EKS ingress controller
Dockerfile --> build and push the images
manifest --> how to run the image
aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 315069654700.dkr.ecr.us-east-1.amazonaws.com
docker build -t 315069654700.dkr.ecr.us-east-1.amazonaws.com/expense-backend:latest .
docker push 315069654700.dkr.ecr.us-east-1.amazonaws.com/expense-backend:latest
imagePullBackOff --> your k8 node is unable to pull the image
crashLoopBackoff --> pod is not able to run... if Backend is not able to connect DB
pending --> PV and PVC setup and config are not proper. pod is not able to mount the volume.