Skip to content

Commit fb976d5

Browse files
authored
Merge pull request #27364 from jailton/en/docs/tutorials/stateless-application
Fix content/en/docs/tutorials/stateless-application/guestbook.md
2 parents 8b2ecd5 + d5b1793 commit fb976d5

File tree

1 file changed

+25
-24
lines changed

1 file changed

+25
-24
lines changed

content/en/docs/tutorials/stateless-application/guestbook.md

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,14 @@ The manifest file, included below, specifies a Deployment controller that runs a
4949
1. Launch a terminal window in the directory you downloaded the manifest files.
5050
1. Apply the MongoDB Deployment from the `mongo-deployment.yaml` file:
5151

52+
<!---
53+
for local testing of the content via relative file path
54+
kubectl apply -f ./content/en/examples/application/guestbook/mongo-deployment.yaml
55+
-->
56+
5257
```shell
5358
kubectl apply -f https://k8s.io/examples/application/guestbook/mongo-deployment.yaml
5459
```
55-
<!---
56-
for local testing of the content via relative file path
57-
kubectl apply -f ./content/en/examples/application/guestbook/mongo-deployment.yaml
58-
-->
5960

6061
1. Query the list of Pods to verify that the MongoDB Pod is running:
6162

@@ -84,15 +85,15 @@ The guestbook application needs to communicate to the MongoDB to write its data.
8485

8586
1. Apply the MongoDB Service from the following `mongo-service.yaml` file:
8687

88+
<!---
89+
for local testing of the content via relative file path
90+
kubectl apply -f ./content/en/examples/application/guestbook/mongo-service.yaml
91+
-->
92+
8793
```shell
8894
kubectl apply -f https://k8s.io/examples/application/guestbook/mongo-service.yaml
8995
```
9096

91-
<!---
92-
for local testing of the content via relative file path
93-
kubectl apply -f ./content/en/examples/application/guestbook/mongo-service.yaml
94-
-->
95-
9697
1. Query the list of Services to verify that the MongoDB Service is running:
9798

9899
```shell
@@ -122,15 +123,15 @@ The guestbook application has a web frontend serving the HTTP requests written i
122123

123124
1. Apply the frontend Deployment from the `frontend-deployment.yaml` file:
124125

126+
<!---
127+
for local testing of the content via relative file path
128+
kubectl apply -f ./content/en/examples/application/guestbook/frontend-deployment.yaml
129+
-->
130+
125131
```shell
126132
kubectl apply -f https://k8s.io/examples/application/guestbook/frontend-deployment.yaml
127133
```
128134

129-
<!---
130-
for local testing of the content via relative file path
131-
kubectl apply -f ./content/en/examples/application/guestbook/frontend-deployment.yaml
132-
-->
133-
134135
1. Query the list of Pods to verify that the three frontend replicas are running:
135136

136137
```shell
@@ -160,15 +161,15 @@ Some cloud providers, like Google Compute Engine or Google Kubernetes Engine, su
160161

161162
1. Apply the frontend Service from the `frontend-service.yaml` file:
162163

164+
<!---
165+
for local testing of the content via relative file path
166+
kubectl apply -f ./content/en/examples/application/guestbook/frontend-service.yaml
167+
-->
168+
163169
```shell
164170
kubectl apply -f https://k8s.io/examples/application/guestbook/frontend-service.yaml
165171
```
166172

167-
<!---
168-
for local testing of the content via relative file path
169-
kubectl apply -f ./content/en/examples/application/guestbook/frontend-service.yaml
170-
-->
171-
172173
1. Query the list of Services to verify that the frontend Service is running:
173174

174175
```shell
@@ -179,7 +180,7 @@ kubectl apply -f ./content/en/examples/application/guestbook/frontend-service.ya
179180

180181
```
181182
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
182-
frontend ClusterIP 10.0.0.112 <none> 80/TCP 6s
183+
frontend ClusterIP 10.0.0.112 <none> 80/TCP 6s
183184
kubernetes ClusterIP 10.0.0.1 <none> 443/TCP 4m
184185
mongo ClusterIP 10.0.0.151 <none> 6379/TCP 2m
185186
```
@@ -214,8 +215,8 @@ If you deployed the `frontend-service.yaml` manifest with type: `LoadBalancer` y
214215
The response should be similar to this:
215216

216217
```
217-
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
218-
frontend ClusterIP 10.51.242.136 109.197.92.229 80:32372/TCP 1m
218+
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
219+
frontend LoadBalancer 10.51.242.136 109.197.92.229 80:32372/TCP 1m
219220
```
220221

221222
1. Copy the external IP address, and load the page in your browser to view your guestbook.
@@ -245,7 +246,7 @@ You can scale up or down as needed because your servers are defined as a Service
245246
frontend-3823415956-k22zn 1/1 Running 0 54m
246247
frontend-3823415956-w9gbt 1/1 Running 0 54m
247248
frontend-3823415956-x2pld 1/1 Running 0 5s
248-
mongo-1068406935-3lswp 1/1 Running 0 56m
249+
mongo-1068406935-3lswp 1/1 Running 0 56m
249250
```
250251

251252
1. Run the following command to scale down the number of frontend Pods:
@@ -266,7 +267,7 @@ You can scale up or down as needed because your servers are defined as a Service
266267
NAME READY STATUS RESTARTS AGE
267268
frontend-3823415956-k22zn 1/1 Running 0 1h
268269
frontend-3823415956-w9gbt 1/1 Running 0 1h
269-
mongo-1068406935-3lswp 1/1 Running 0 1h
270+
mongo-1068406935-3lswp 1/1 Running 0 1h
270271
```
271272

272273

0 commit comments

Comments
 (0)