File tree Expand file tree Collapse file tree 4 files changed +32
-9
lines changed Expand file tree Collapse file tree 4 files changed +32
-9
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ metadata:
9
9
10
10
spec :
11
11
` ` `
12
- - **API Objects Reference:** https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.18/#pod-v1-core
12
+ - **Pod API Objects Reference:** https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.18/#pod-v1-core
13
13
14
14
## Step-02: Create Simple Pod Definition using YAML
15
15
- We are going to create a very basic pod definition
@@ -71,3 +71,8 @@ http://<WorkerNode-Public-IP>:<NodePort>
71
71
http://<WorkerNode-Public-IP>:31231
72
72
```
73
73
74
+ ## API Object References
75
+ - ** Pod** : https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.18/#pod-v1-core
76
+ - ** Service** : https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.18/#service-v1-core
77
+
78
+
Original file line number Diff line number Diff line change 1
- apiVersion :
2
- kind :
1
+ apiVersion :
2
+ kind :
3
3
metadata :
4
-
4
+
5
5
spec :
6
6
7
7
# Types of Kubernetes Objects
Original file line number Diff line number Diff line change
1
+ apiVersion : v1 # String
2
+ kind : Pod # String
3
+ metadata : # Dictionary
4
+ name : myapp-pod
5
+ labels : # Dictionary
6
+ app : myapp
7
+ spec :
8
+ containers : # List
9
+ - name : myapp
10
+ image : stacksimplify/kubenginx:1.0.0
11
+ ports :
12
+ - containerPort : 80
13
+
14
+
15
+
Original file line number Diff line number Diff line change 1
1
apiVersion : v1
2
2
kind : Service
3
3
metadata :
4
- name : myapp-pod-nodeport-service
4
+ name : myapp-pod-nodeport-service # Name of the Service
5
5
spec :
6
6
type : NodePort
7
7
selector :
8
+ # Loadbalance traffic across Pods matching this label selector
8
9
app : myapp
9
- ports :
10
- - port : 80
11
- targetPort : 80
12
- nodePort : 31231
10
+ # Accept traffic sent to port 80
11
+ ports :
12
+ - name : http
13
+ port : 80 # Service Port
14
+ targetPort : 80 # Container Port
15
+ nodePort : 31231 # NodePort
You can’t perform that action at this time.
0 commit comments