Skip to content

Commit 7864ac4

Browse files
authored
Merge pull request #639 from SeleniumHQ/remote_host_env_var
Bringing back support for -remoteHost
2 parents 210740f + f3d28ad commit 7864ac4

File tree

3 files changed

+8
-18
lines changed

3 files changed

+8
-18
lines changed

NodeBase/entry_point.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,10 @@ function shutdown {
2020
wait $NODE_PID
2121
}
2222

23+
REMOTE_HOST_PARAM=""
2324
if [ ! -z "$REMOTE_HOST" ]; then
24-
>&2 echo "REMOTE_HOST variable is *DEPRECATED* in these docker containers. Please use SE_OPTS=\"-host <host> -port <port>\" instead!"
25-
exit 1
25+
echo "REMOTE_HOST variable is set, appending -remoteHost"
26+
REMOTE_HOST_PARAM="-remoteHost $REMOTE_HOST"
2627
fi
2728

2829
if [ ! -z "$SE_OPTS" ]; then
@@ -37,6 +38,7 @@ xvfb-run -n $SERVERNUM --server-args="-screen 0 $GEOMETRY -ac +extension RANDR"
3738
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server-standalone.jar \
3839
-role node \
3940
-hub http://$HUB_PORT_4444_TCP_ADDR:$HUB_PORT_4444_TCP_PORT/grid/register \
41+
${REMOTE_HOST_PARAM} \
4042
-nodeConfig /opt/selenium/config.json \
4143
${SE_OPTS} &
4244
NODE_PID=$!

NodeDebug/debug-script.sh

Lines changed: 0 additions & 14 deletions
This file was deleted.

NodeDebug/entry_point.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ function shutdown {
2222
wait $NODE_PID
2323
}
2424

25+
REMOTE_HOST_PARAM=""
2526
if [ ! -z "$REMOTE_HOST" ]; then
26-
>&2 echo "REMOTE_HOST variable is *DEPRECATED* in these docker containers. Please use SE_OPTS=\"-host <host> -port <port>\" instead!"
27-
exit 1
27+
echo "REMOTE_HOST variable is set, appending -remoteHost"
28+
REMOTE_HOST_PARAM="-remoteHost $REMOTE_HOST"
2829
fi
2930

3031
if [ ! -z "$SE_OPTS" ]; then
@@ -40,6 +41,7 @@ DISPLAY=$DISPLAY \
4041
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server-standalone.jar \
4142
-role node \
4243
-hub http://$HUB_PORT_4444_TCP_ADDR:$HUB_PORT_4444_TCP_PORT/grid/register \
44+
${REMOTE_HOST_PARAM} \
4345
-nodeConfig /opt/selenium/config.json \
4446
${SE_OPTS} &
4547
NODE_PID=$!

0 commit comments

Comments
 (0)