From 2973b57264e46e314d310ae365e211ad2eafaca3 Mon Sep 17 00:00:00 2001 From: Lee Mills <8024370+millnut@users.noreply.github.com> Date: Sat, 11 May 2024 12:33:56 +0100 Subject: [PATCH 1/4] ci: use drupalci webdriver image --- .lando.dist.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.lando.dist.yml b/.lando.dist.yml index c601d78..42b2f0f 100644 --- a/.lando.dist.yml +++ b/.lando.dist.yml @@ -23,8 +23,9 @@ services: environment: DRUSH_OPTIONS_ROOT: '/app/web' DRUSH_OPTIONS_URI: 'https://localgov.lndo.site' + SIMPLETEST_BASE_URL: 'https://localgov.lndo.site' SIMPLETEST_DB: 'mysql://database:database@database/database' - MINK_DRIVER_ARGS_WEBDRIVER: '["chrome", { "chromeOptions": { "w3c": false } }, "http://chromedriver:4444/wd/hub"]' + MINK_DRIVER_ARGS_WEBDRIVER: '["chrome", {"browserName":"chrome","chromeOptions":{"args":["--disable-gpu","--headless","--no-sandbox"]}}, "http://chromedriver:9515"]' BROWSERTEST_OUTPUT_DIRECTORY: '/app/web/sites/simpletest/browser_output' BROWSERTEST_OUTPUT_BASE_URL: 'https://localgov.lndo.site' # Support debugging CLI with Xdebug. @@ -57,16 +58,14 @@ services: - '3050:3050' chromedriver: type: compose + scanner: false services: - image: robcherry/docker-chromedriver:latest - environment: - CHROMEDRIVER_WHITELISTED_IPS: "" - CHROMEDRIVER_URL_BASE: "/wd/hub" + image: drupalci/webdriver-chromedriver:production + ports: + - "9515:9515" security_opt: - seccomp:unconfined - expose: - - '4444' - command: ["/usr/local/bin/supervisord", "-c", "/etc/supervisord.conf"] + command: chromedriver --verbose --allowed-ips= --allowed-origins=* solr-sitewide: type: solr:8 core: sitewide From 6fceeb8693114061a9bc98ceaac4d69223a5a5d5 Mon Sep 17 00:00:00 2001 From: Richard Sheppard Date: Wed, 29 May 2024 12:01:56 +0100 Subject: [PATCH 2/4] Chore: Removes the version key from docker-compose file. As per: https://github.com/ddev/ddev-selenium-standalone-chrome/pull/39 . --- .ddev/docker-compose.selenium-chrome.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.ddev/docker-compose.selenium-chrome.yaml b/.ddev/docker-compose.selenium-chrome.yaml index d85d29a..584baf8 100644 --- a/.ddev/docker-compose.selenium-chrome.yaml +++ b/.ddev/docker-compose.selenium-chrome.yaml @@ -1,6 +1,5 @@ # This file comes from https://github.com/ddev/ddev-selenium-standalone-chrome # -version: '3.6' services: selenium-chrome: image: seleniarm/standalone-chromium:4.1.4-20220429 From 0a1185a8275f4ee073df3ed2589e5a14eb14f3b8 Mon Sep 17 00:00:00 2001 From: Lee Mills <8024370+millnut@users.noreply.github.com> Date: Tue, 25 Jun 2024 22:11:36 +0100 Subject: [PATCH 3/4] ci: update lando commands --- .lando.dist.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.lando.dist.yml b/.lando.dist.yml index 42b2f0f..bf0e12f 100644 --- a/.lando.dist.yml +++ b/.lando.dist.yml @@ -23,11 +23,11 @@ services: environment: DRUSH_OPTIONS_ROOT: '/app/web' DRUSH_OPTIONS_URI: 'https://localgov.lndo.site' - SIMPLETEST_BASE_URL: 'https://localgov.lndo.site' + SIMPLETEST_BASE_URL: 'http://localgov.lndo.site' SIMPLETEST_DB: 'mysql://database:database@database/database' - MINK_DRIVER_ARGS_WEBDRIVER: '["chrome", {"browserName":"chrome","chromeOptions":{"args":["--disable-gpu","--headless","--no-sandbox"]}}, "http://chromedriver:9515"]' + MINK_DRIVER_ARGS_WEBDRIVER: '["chrome", {"browserName": "chrome", "goog:chromeOptions": {"args": ["--disable-gpu","--headless", "--no-sandbox", "--disable-dev-shm-usage"]}}, "http://chromedriver:9515"]' BROWSERTEST_OUTPUT_DIRECTORY: '/app/web/sites/simpletest/browser_output' - BROWSERTEST_OUTPUT_BASE_URL: 'https://localgov.lndo.site' + BROWSERTEST_OUTPUT_BASE_URL: 'http://localgov.lndo.site' # Support debugging CLI with Xdebug. PHP_IDE_CONFIG: "serverName=appserver" XDEBUG_SESSION: "lando" From a6179661e526af9d43d6bc9d05ceab8b76d6b912 Mon Sep 17 00:00:00 2001 From: Finn Lewis Date: Tue, 2 Jul 2024 11:20:49 +0100 Subject: [PATCH 4/4] Update ddev selenium config to use drupalci/webdriver-chromedriver:production. --- .ddev/config.selenium-standalone-chrome.yaml | 5 ++--- .ddev/docker-compose.selenium-chrome.yaml | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.ddev/config.selenium-standalone-chrome.yaml b/.ddev/config.selenium-standalone-chrome.yaml index e2c7d1c..ae6110c 100644 --- a/.ddev/config.selenium-standalone-chrome.yaml +++ b/.ddev/config.selenium-standalone-chrome.yaml @@ -8,8 +8,7 @@ web_environment: # Use disable-dev-shm-usage instead of setting shm_usage # https://developers.google.com/web/tools/puppeteer/troubleshooting#tips # The format of chromeOptions is defined at https://chromedriver.chromium.org/capabilities - - MINK_DRIVER_ARGS_WEBDRIVER=[\"chrome\", {\"browserName\":\"chrome\",\"chromeOptions\":{\"w3c\":false,\"args\":[\"--disable-gpu\",\"--headless\", \"--no-sandbox\", \"--disable-dev-shm-usage\"]}}, \"http://selenium-chrome:4444/wd/hub\"] - # Nightwatch + - MINK_DRIVER_ARGS_WEBDRIVER=[\"chrome\", {\"browserName\":\"chrome\",\"w3c\":false,\"goog:chromeOptions\":{\"args\":[\"--disable-gpu\",\"--headless\", \"--no-sandbox\", \"--disable-dev-shm-usage\"]}}, \"http://selenium-chrome:4444/wd/hub\"] # Nightwatch - DRUPAL_TEST_BASE_URL=http://web - DRUPAL_TEST_DB_URL=mysql://db:db@db/db - DRUPAL_TEST_WEBDRIVER_HOSTNAME=selenium-chrome @@ -22,4 +21,4 @@ web_environment: - DRUPAL_NIGHTWATCH_OUTPUT=reports/nightwatch # DTT - DTT_BASE_URL=http://web - - DTT_MINK_DRIVER_ARGS=[\"chrome\", {\"browserName\":\"chrome\",\"chromeOptions\":{\"w3c\":false,\"args\":[\"--disable-gpu\",\"--headless\", \"--no-sandbox\", \"--disable-dev-shm-usage\"]}}, \"http://selenium-chrome:4444/wd/hub\"] + - DTT_MINK_DRIVER_ARGS=[\"chrome\", {\"browserName\":\"chrome\",\"w3c\":false,\"goog:chromeOptions\":{\"args\":[\"--disable-gpu\",\"--headless\", \"--no-sandbox\", \"--disable-dev-shm-usage\"]}}, \"http://selenium-chrome:4444/wd/hub\"] diff --git a/.ddev/docker-compose.selenium-chrome.yaml b/.ddev/docker-compose.selenium-chrome.yaml index d85d29a..f8bd69d 100644 --- a/.ddev/docker-compose.selenium-chrome.yaml +++ b/.ddev/docker-compose.selenium-chrome.yaml @@ -1,9 +1,8 @@ # This file comes from https://github.com/ddev/ddev-selenium-standalone-chrome # -version: '3.6' services: selenium-chrome: - image: seleniarm/standalone-chromium:4.1.4-20220429 + image: drupalci/webdriver-chromedriver:production container_name: ddev-${DDEV_SITENAME}-selenium-chrome expose: # The internal noVNC port, which operates over HTTP so it can be exposed