cancel
Showing results for 
Search instead for 
Did you mean: 
AlessandraS
Flight Engineer
Flight Engineer
  • 217 Views

Chapter 7 Quiz: Compose Overview and Use Cases

Jump to solution

AlessandraS_0-1756980809218.png

E is a right answer, that's clear to me.

Could you explain me why F is not also true?

Thank you.

 

1 Solution

Accepted Solutions
Travis
Moderator
Moderator
  • 197 Views

@AlessandraS -

If you look closely, no containers are exposed on port 8080. When you are exposing ports, you have left_side:right_side

The left side is the host port that is being exposed and mapped to the inner "right side" port that the application in the container is running on.

So you are exposing 8082, 8081, and 8001 from the system using the compose file. Those ports do happen to map to port 8080 on two containers, but the host port that is being mapped to the container is not 8080.

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training

View solution in original post

2 Replies
Travis
Moderator
Moderator
  • 198 Views

@AlessandraS -

If you look closely, no containers are exposed on port 8080. When you are exposing ports, you have left_side:right_side

The left side is the host port that is being exposed and mapped to the inner "right side" port that the application in the container is running on.

So you are exposing 8082, 8081, and 8001 from the system using the compose file. Those ports do happen to map to port 8080 on two containers, but the host port that is being mapped to the container is not 8080.

Travis Michette, RHCA XIII
https://rhtapps.redhat.com/verify?certId=111-134-086
SENIOR TECHNICAL INSTRUCTOR / CERTIFIED INSTRUCTOR AND EXAMINER
Red Hat Certification + Training
AlessandraS
Flight Engineer
Flight Engineer
  • 194 Views

Right, thanks!

Join the discussion
You must log in to join this conversation.