You want to create a container that is reachable from its host’s network. Does this action accomplish this?

You want to create a container that is reachable from its host’s network. Does this action accomplish this?

Solution: Use –link to access the container on the bridge network.
A . Yes
B . No

Answer: B

Explanation:

= The action of using –link to access the container on the bridge network does not accomplish the goal of creating a container that is reachable from its host’s network. The –link option allows you to connect containers that are running on the same network, but it does not expose the container’s ports to the host1. To create a container that is reachable from its host’s network, you need to use the –network host option, which attaches the container to the host’s network stack and makes it share the host’s IP address2. Alternatively, you can use the –publish or -p option to map the container’s ports to the host’s ports3.

Reference: Legacy container links | Docker Documentation : Networking using the host network |

Docker Documentation: docker run reference | Docker Documentation

Latest DCA Dumps Valid Version with 55 Q&As

Latest And Valid Q&A | Instant Download | Once Fail, Full Refund

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments