update the yaml example based on review

This commit is contained in:
Alpha
2020-03-30 13:28:22 +08:00
committed by GitHub
parent 07fd1c617f
commit ff4ebc4fea
@@ -546,11 +546,11 @@ spec:
app: MyApp app: MyApp
ports: ports:
- port: 80 - port: 80
# By default and for convenience, the targetPort is set to the same value as the port field.
targetPort: 80 targetPort: 80
# `targetPort` is the port of pod, you would like to expose # By default and for convenience, the `targetPort` is set to the same value as the `port` field.
NodePort: 30007 nodePort: 30007
# `NodePort` is the port of node, you would like to expose # Optional field
# By default and for convenience, the Kubernetes control plane will allocates a port from a range (default: 30000-32767)
``` ```
### Type LoadBalancer {#loadbalancer} ### Type LoadBalancer {#loadbalancer}