[ https://issues.apache.org/jira/browse/YARN-5168?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16687504#comment-16687504 ]
Eric Yang commented on YARN-5168: --------------------------------- [~liuxun323] {quote}What command or parameter should I use to tell YARN, Do I need to expose the service port in my container? Exposing the specified port of the service should be specified at runtime. If the port mapping needs to use the EXPOSE command in the Dockerfile, it is too difficult to use.{quote} If this is done right, by specifying bridge network and YARN automatically exposes service ports. This would be the ideal solution. EXPOSE directive in Dockerfile is the easiest way to ensure we don't have to track additional metadata or create redundant config that may have implicit conflicts else where. I can not think of a reasonable syntax for user to fill in yarnfile to express service port routes at large scale. It would be easier to use internal ports to communicate with peers, and only keep user interface like a web port exposed to outside where user can click through a hyperlink. Hence, the only reasonable solution is to automatically add "-P" when bridge network is specified with EXPOSE directive in Dockerfile. This JIRA only aggregates the service port information and display on UI for user to click on. > Add port mapping handling when docker container use bridge network > ------------------------------------------------------------------ > > Key: YARN-5168 > URL: https://issues.apache.org/jira/browse/YARN-5168 > Project: Hadoop YARN > Issue Type: Sub-task > Reporter: Jun Gong > Assignee: Eric Yang > Priority: Major > Labels: Docker > > YARN-4007 addresses different network setups when launching the docker > container. We need support port mapping when docker container uses bridge > network. > The following problems are what we faced: > 1. Add "-P" to map docker container's exposed ports to automatically. > 2. Add "-p" to let user specify specific ports to map. > 3. Add service registry support for bridge network case, then app could find > each other. It could be done out of YARN, however it might be more convenient > to support it natively in YARN. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org