diff --git a/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/nodemanager-generate-script.sh b/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/nodemanager-generate-script.sh index 286443dfab..858dd19dd9 100644 --- a/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/nodemanager-generate-script.sh +++ b/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/nodemanager-generate-script.sh @@ -53,6 +53,7 @@ sed -i "s/{TIMELINE_SERVER_ADDRESS}/${TIMELINE_SERVER_ADDRESS}/g" $HADOOP_CONF_ sed -i "s#{HOST_YARN_NODEMANAGER_STORAGE}#${HOST_YARN_NODEMANAGER_STORAGE}#g" $HADOOP_CONF_DIR/yarn-site.xml sed -i "s#{HOST_HADOOP_TMP_STORAGE}#${HOST_HADOOP_TMP_STORAGE}#g" $HADOOP_CONF_DIR/yarn-site.xml sed -i "s#{CURRENT_IMAGE_NAME}#${CURRENT_IMAGE_NAME}#g" $HADOOP_CONF_DIR/yarn-site.xml +sed -i "s/{POD_IP}/${POD_IP}/g" $HADOOP_CONF_DIR/yarn-site.xml sed -i "s/{HDFS_ADDRESS}/${HDFS_ADDRESS}/g" $HADOOP_CONF_DIR/core-site.xml diff --git a/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/yarn-site.xml.template b/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/yarn-site.xml.template index 8d31e111e1..3e6b609101 100644 --- a/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/yarn-site.xml.template +++ b/src/hadoop-node-manager/deploy/hadoop-node-manager-configuration/yarn-site.xml.template @@ -92,7 +92,7 @@ yarn.nodemanager.hostname - {{ host_config['ip'] }} + {POD_IP} @@ -137,7 +137,7 @@ yarn.nodemanager.address - {{ host_config['ip'] }}:8041 + {POD_IP}:8041 diff --git a/src/hadoop-node-manager/deploy/hadoop-node-manager.yaml.template b/src/hadoop-node-manager/deploy/hadoop-node-manager.yaml.template index 417e59705d..2d3f4a1da5 100644 --- a/src/hadoop-node-manager/deploy/hadoop-node-manager.yaml.template +++ b/src/hadoop-node-manager/deploy/hadoop-node-manager.yaml.template @@ -103,6 +103,10 @@ spec: value: "3072" - name: NV_DRIVER value: /var/drivers/nvidia/current + - name: POD_IP + valueFrom: + fieldRef: + fieldPath: status.podIP imagePullSecrets: - name: {{ cluster_cfg["cluster"]["docker-registry"]["secret-name"] }} volumes: