[ https://issues.apache.org/jira/browse/YARN-7935?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16418095#comment-16418095 ]
Eric Yang commented on YARN-7935: --------------------------------- [~mridulm80] There is some concerns to expose the variables correctly, but the value of this variable may be relative depending on looking outside into docker, or inside docker transmitting out. If we agree on that the value of CONTAINER_HOSTNAME needs to be what is visible inside the container. I am not confident that computing InetAddress.getLocalHost().getHostName() in node manager and net=host would provide the desired result in all scenarios (think multi-homed environment). Can CONAINER_HOSTNAME be preset to match --hostname on all conditions while satisfy the result? I think it's closer to what is required, and only dependency is to make sure that RegistryDNS is deployed. > Expose container's hostname to applications running within the docker > container > ------------------------------------------------------------------------------- > > Key: YARN-7935 > URL: https://issues.apache.org/jira/browse/YARN-7935 > Project: Hadoop YARN > Issue Type: Sub-task > Components: yarn > Reporter: Suma Shivaprasad > Assignee: Suma Shivaprasad > Priority: Major > Attachments: YARN-7935.1.patch, YARN-7935.2.patch, YARN-7935.3.patch > > > Some applications have a need to bind to the container's hostname (like > Spark) which is different from the NodeManager's hostname(NM_HOST which is > available as an env during container launch) when launched through Docker > runtime. The container's hostname can be exposed to applications via an env > CONTAINER_HOSTNAME. Another potential candidate is the container's IP but > this can be addressed in a separate jira. -- 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