Skip to content

Commit a101c6f

Browse files
authored
Adding log output for SE_OPTS (#1243)
1 parent 432b8b6 commit a101c6f

9 files changed

+35
-5
lines changed

EventBus/start-selenium-grid-eventbus.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ if [ ! -z "$SE_EVENT_BUS_PORT" ]; then
1515
PORT_CONFIG="--port ${SE_EVENT_BUS_PORT}"
1616
fi
1717

18+
if [ ! -z "$SE_OPTS" ]; then
19+
echo "Appending Selenium options: ${SE_OPTS}"
20+
fi
21+
1822
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server.jar event-bus \
1923
${HOST_CONFIG} \
2024
${PORT_CONFIG} \

Hub/start-selenium-grid-hub.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,7 @@ fi
2121
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server.jar hub \
2222
--session-request-timeout ${SE_SESSION_REQUEST_TIMEOUT} \
2323
--session-retry-interval ${SE_SESSION_RETRY_INTERVAL} \
24-
--relax-checks \
25-
${SE_RELAX_CHECKS} ${HOST_CONFIG} ${PORT_CONFIG} ${SE_OPTS}
24+
--relax-checks ${SE_RELAX_CHECKS} \
25+
${HOST_CONFIG} \
26+
${PORT_CONFIG} \
27+
${SE_OPTS}

NodeBase/start-selenium-node.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ if [[ -z "${SE_EVENT_BUS_SUBSCRIBE_PORT}" ]]; then
2727
exit 1
2828
fi
2929

30+
if [ ! -z "$SE_OPTS" ]; then
31+
echo "Appending Selenium options: ${SE_OPTS}"
32+
fi
33+
3034
/opt/bin/generate_config
3135

3236
echo "Starting Selenium Grid Node with configuration: "

NodeDocker/start-selenium-grid-node-docker.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ if [[ -z "${SE_EVENT_BUS_SUBSCRIBE_PORT}" ]]; then
2020
exit 1
2121
fi
2222

23+
if [ ! -z "$SE_OPTS" ]; then
24+
echo "Appending Selenium options: ${SE_OPTS}"
25+
fi
26+
2327
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server.jar node \
2428
--publish-events tcp://"${SE_EVENT_BUS_HOST}":${SE_EVENT_BUS_PUBLISH_PORT} \
2529
--subscribe-events tcp://"${SE_EVENT_BUS_HOST}":${SE_EVENT_BUS_SUBSCRIBE_PORT} \

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ ___
367367
You can pass `SE_OPTS` variable with additional commandline parameters for starting a hub or a node.
368368

369369
``` bash
370-
$ docker run -d -p 4444:4444 -e SE_OPTS="-debug" --name selenium-hub selenium/hub:4.0.0-beta-2-20210317
370+
$ docker run -d -p 4444:4444 -e SE_OPTS="--log-level FINE" --name selenium-hub selenium/hub:4.0.0-beta-2-20210317
371371
```
372372

373373
### JAVA_OPTS Java Environment Options

Standalone/Dockerfile.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,10 @@ COPY start-selenium-standalone.sh /opt/bin/start-selenium-standalone.sh
1010
#==============================
1111
COPY selenium.conf /etc/supervisor/conf.d/
1212

13+
# Boolean value, maps "--relax-checks"
14+
ENV SE_RELAX_CHECKS true
15+
1316

1417
EXPOSE 4444
18+
19+

Standalone/start-selenium-standalone.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,10 @@
22
#
33
# IMPORTANT: Change this file only in directory Standalone!
44

5+
if [ ! -z "$SE_OPTS" ]; then
6+
echo "Appending Selenium options: ${SE_OPTS}"
7+
fi
8+
59
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server.jar standalone \
6-
--relax-checks true ${SE_OPTS}
10+
--relax-checks ${SE_RELAX_CHECKS} \
11+
${SE_OPTS}

StandaloneDocker/Dockerfile.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,5 @@ COPY start-selenium-grid-standalone-docker.sh \
1212

1313
COPY selenium-grid-standalone-docker.conf /etc/supervisor/conf.d/
1414

15+
# Boolean value, maps "--relax-checks"
16+
ENV SE_RELAX_CHECKS true

StandaloneDocker/start-selenium-grid-standalone-docker.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,12 @@ set -e
55

66
echo "Starting Selenium Grid Standalone Docker..."
77

8+
if [ ! -z "$SE_OPTS" ]; then
9+
echo "Appending Selenium options: ${SE_OPTS}"
10+
fi
11+
812
java ${JAVA_OPTS} -jar /opt/selenium/selenium-server.jar standalone \
9-
--relax-checks true \
13+
--relax-checks ${SE_RELAX_CHECKS} \
1014
--detect-drivers false \
1115
--config /opt/bin/config.toml \
1216
${SE_OPTS}

0 commit comments

Comments
 (0)