The description 
might help: " Exposing a port here gives the system additional information 
about the network connections a container uses, but is primarily 
informational. Not specifying a port here DOES NOT prevent that port from 
being exposed. Any port which is listening on the default "" address 
inside a container will be accessible from the network."

On Tuesday, February 13, 2018 at 1:51:46 PM UTC-5, adoyt wrote:
> Hi,
> In my yaml file below, 8080 doesn't work because nginx is configured to 
> listen on port 80.  Also, doing a curl against the IP of POD works (curl 
> http://podid:80).  So what's the point of containerPorts?
> apiVersion: v1
> kind: Pod
> metadata:
>   name: hello-pod
>   namespace: default
> spec:
>   containers:
>   - name: hello-ctr
>     image: nginx
>     ports:
>     - containerPort: 8080

You received this message because you are subscribed to the Google Groups 
"Kubernetes user discussion and Q&A" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
To post to this group, send email to
Visit this group at
For more options, visit

Reply via email to