Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add ENV var for CLI config --reject-unsupported-caps #2127

Merged
merged 1 commit into from
Feb 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,8 @@ USER ${SEL_UID}:${SEL_GID}

# Boolean value, maps "--bind-host"
ENV SE_BIND_HOST false
# Boolean value, maps "--reject-unsupported-caps"
ENV SE_REJECT_UNSUPPORTED_CAPS false

# A too high maximum number of file descriptors (with the default value
# inherited from the docker host) can cause issues with some of our tools:
Expand Down
5 changes: 5 additions & 0 deletions Distributor/start-selenium-grid-distributor.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,11 @@ if [ ! -z "$SE_REGISTRATION_SECRET" ]; then
SE_OPTS="$SE_OPTS --registration-secret ${SE_REGISTRATION_SECRET}"
fi

if [ ! -z "$SE_REJECT_UNSUPPORTED_CAPS" ]; then
echo "Appending Selenium options: --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
SE_OPTS="$SE_OPTS --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
fi

EXTRA_LIBS=""

if [ ! -z "$SE_ENABLE_TRACING" ]; then
Expand Down
5 changes: 5 additions & 0 deletions Hub/start-selenium-grid-hub.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ if [ ! -z "$SE_DISABLE_UI" ]; then
SE_OPTS="$SE_OPTS --disable-ui ${SE_DISABLE_UI}"
fi

if [ ! -z "$SE_REJECT_UNSUPPORTED_CAPS" ]; then
echo "Appending Selenium options: --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
SE_OPTS="$SE_OPTS --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
fi

EXTRA_LIBS=""

if [ ! -z "$SE_ENABLE_TRACING" ]; then
Expand Down
5 changes: 5 additions & 0 deletions Standalone/start-selenium-standalone.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ if [ ! -z "$SE_JAVA_SSL_TRUST_STORE" ]; then
SE_JAVA_OPTS="$SE_JAVA_OPTS -Djdk.internal.httpclient.disableHostnameVerification=${SE_JAVA_DISABLE_HOSTNAME_VERIFICATION:-true}"
fi

if [ ! -z "$SE_REJECT_UNSUPPORTED_CAPS" ]; then
echo "Appending Selenium options: --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
SE_OPTS="$SE_OPTS --reject-unsupported-caps ${SE_REJECT_UNSUPPORTED_CAPS}"
fi

/opt/bin/generate_config

echo "Selenium Grid Standalone configuration: "
Expand Down
4 changes: 4 additions & 0 deletions tests/charts/ci/base-tracing-values.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
hub:
extraEnvironmentVariables:
- name: SE_REJECT_UNSUPPORTED_CAPS
value: "false"
- name: SE_ENABLE_TRACING
value: "true"
- name: SE_JAVA_OPTS
value: "-Dotel.traces.exporter=jaeger -Dotel.exporter.jaeger.endpoint=http://{{ .Release.Name }}-jaeger-all-in-one-headless:14250 -Dotel.resource.attributes=service.name=selenium -Dotel.java.global-autoconfigure.enabled=true"

components:
extraEnvironmentVariables:
- name: SE_REJECT_UNSUPPORTED_CAPS
value: "false"
- name: SE_ENABLE_TRACING
value: "true"
- name: SE_JAVA_OPTS
Expand Down