ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 175 - DCA discussion

Report
Export

You want to create a container that is reachable from its host's network.

Does this action accomplish this?

Solution: Use network attach to access the container on the bridge network.

A.

Yes

Answers
A.

Yes

B.

No

Answers
B.

No

Suggested answer: A

Explanation:

Docker's bridge network allows containers connected to the same bridge network to communicate, while providing isolation from containers that aren't connected to that bridge network1. By using the network attach command, you can connect a container to the bridge network, making it reachable from the host's network12. However, it's important to note that containers on the default bridge network can only access each other by IP addresses, unless you use the --link option, which is considered legacy2. For better isolation and automatic DNS resolution between containers, it's recommended to use user-defined bridge networks12.

asked 08/11/2024
Glen Teis
34 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first