Skip to content

Commit

Permalink
Merge pull request #2649 from abdallahghdiri/docker-browser-additiona…
Browse files Browse the repository at this point in the history
…l-flags

Add an optional environment variable for docker images in order to easily and globally configure additional startup flags
  • Loading branch information
ptrthomas authored Feb 9, 2025
2 parents f06578b + b3e6897 commit bc1df10
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions karate-docker/karate-chrome/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ if [ -z "$KARATE_SOCAT_START" ]
export KARATE_SOCAT_START="true"
export KARATE_CHROME_PORT="9223"
fi
[ -z "$KARATE_CHROME_ADD_OPTIONS" ] && export KARATE_CHROME_ADD_OPTIONS=""
[ -z "$KARATE_WIDTH" ] && export KARATE_WIDTH="1280"
[ -z "$KARATE_HEIGHT" ] && export KARATE_HEIGHT="720"
exec /usr/bin/supervisord -c /etc/supervisord.conf
1 change: 1 addition & 0 deletions karate-docker/karate-chrome/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ command=/usr/bin/google-chrome
--force-device-scale-factor=1
--remote-allow-origins=*
--remote-debugging-port=%(ENV_KARATE_CHROME_PORT)s
%(ENV_KARATE_CHROME_ADD_OPTIONS)s
autorestart=true
priority=400

Expand Down
1 change: 1 addition & 0 deletions karate-docker/karate-chromium/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ if [ -z "$KARATE_SOCAT_START" ]
export KARATE_SOCAT_START="true"
export KARATE_CHROME_PORT="9223"
fi
[ -z "$KARATE_CHROME_ADD_OPTIONS" ] && export KARATE_CHROME_ADD_OPTIONS=""
[ -z "$KARATE_WIDTH" ] && export KARATE_WIDTH="1280"
[ -z "$KARATE_HEIGHT" ] && export KARATE_HEIGHT="720"
exec /usr/bin/supervisord -c /etc/supervisord.conf
1 change: 1 addition & 0 deletions karate-docker/karate-chromium/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ command=/usr/bin/chromium
--force-device-scale-factor=1
--remote-allow-origins=*
--remote-debugging-port=%(ENV_KARATE_CHROME_PORT)s
%(ENV_KARATE_CHROME_ADD_OPTIONS)s
autorestart=true
priority=400

Expand Down
1 change: 1 addition & 0 deletions karate-docker/karate-firefox/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ if [ -z "$KARATE_SOCAT_START" ]
export KARATE_SOCAT_START="true"
export KARATE_CHROME_PORT="9223"
fi
[ -z "$KARATE_CHROME_ADD_OPTIONS" ] && export KARATE_CHROME_ADD_OPTIONS=""
[ -z "$KARATE_WIDTH" ] && export KARATE_WIDTH="1280"
[ -z "$KARATE_HEIGHT" ] && export KARATE_HEIGHT="720"
exec /usr/bin/supervisord
1 change: 1 addition & 0 deletions karate-docker/karate-firefox/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ command=/usr/bin/firefox
--window-size=%(ENV_KARATE_WIDTH)s,%(ENV_KARATE_HEIGHT)s
--force-device-scale-factor=1
--remote-debugging-port=%(ENV_KARATE_CHROME_PORT)s
%(ENV_KARATE_CHROME_ADD_OPTIONS)s
autorestart=true
priority=400

Expand Down

0 comments on commit bc1df10

Please sign in to comment.