-
Notifications
You must be signed in to change notification settings - Fork 82
/
Copy pathEKS-Kubernetes.txt
51 lines (45 loc) · 1.84 KB
/
EKS-Kubernetes.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
Ubuntu
-------
AWS
EKS (Elastic Kubernetes Service) - Cluster
kubectl --> Kubernetes command line
https://docs.aws.amazon.com/eks/latest/userguide/install-kubectl.html
aws cli -- AWS commannd Line
https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html
EKSCTL --> AWS EKS Command line --> eksctl create cluster
https://docs.aws.amazon.com/eks/latest/userguide/eksctl.html
Master node --> control plane
Nodegroup (m5.large)- 2 worker nodes
root@ip-172-31-14-122:~# history
1 apt update -y
2 curl -o kubectl https://s3.us-west-2.amazonaws.com/amazon-eks/1.24.7/2022-10-31/bin/linux/amd64/kubectl
3 curl -o kubectl.sha256 https://s3.us-west-2.amazonaws.com/amazon-eks/1.24.7/2022-10-31/bin/linux/amd64/kubectl.sha256
4 openssl sha1 -sha256 kubectl
5 chmod +x ./kubectl
6 mkdir -p $HOME/bin && cp ./kubectl $HOME/bin/kubectl && export PATH=$PATH:$HOME/bin
7 echo 'export PATH=$PATH:$HOME/bin' >> ~/.bashrc
8 kubectl version --short --client
9 unzip awscliv2.zip
10 apt install unzip
11 curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
12 unzip awscliv2.zip
13 sudo ./aws/install
14 /usr/local/bin/aws --version
15 curl --silent --location "https://github.com/weaveworks/eksctl/releases/latest/download/eksctl_$(uname -s)_amd64.tar.gz" | tar xz -C /tmp
16 sudo mv /tmp/eksctl /usr/local/bin
17 eksctl version
18 aws configure
19 eksctl create cluster
20 kubectl get nodes
21 touch nginx-pod.yaml
22 vi nginx-pod.yaml
23 clear
24 ls -l
25 cat nginx-pod.yaml
26 kubectl apply -f nginx-pod.yaml
27 kubectl get pods
28 kubectl get po
29 kubectl get po -o wide
30 kubectl describe pod nginx-pod
31 kubectl exec -it nginx-pod -- /bin/bash
32 history