Skip to content
Open
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
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ When you change them, use `bin/moodle-docker-compose down && bin/moodle-docker-c
| `MOODLE_DOCKER_DB_PORT` | no | any integer value | none | If you want to bind to any host IP different from the default 127.0.0.1, you can specify it with the bind_ip:port format (0.0.0.0 means bind to all). Username is "moodle" (or "sa" for mssql) and password is "m@0dl3ing". |
| `MOODLE_DOCKER_WEB_HOST` | no | any valid hostname | localhost | The hostname for web |
| `MOODLE_DOCKER_WEB_PORT` | no | any integer value (or bind_ip:integer)| 127.0.0.1:8000| The port number for web. If set to 0, no port is used.<br/>If you want to bind to any host IP different from the default 127.0.0.1, you can specify it with the bind_ip:port format (0.0.0.0 means bind to all) |
| `MOODLE_DOCKER_SELENIUM_REPOSITORY` | no | selenium, seleniarm | OS-dependent | The repository to use for Selenium images |
| `MOODLE_DOCKER_SELENIUM_VNC_PORT` | no | any integer value (or bind_ip:integer)| not set | If set, the selenium node will expose a vnc session on the port specified. Similar to MOODLE_DOCKER_WEB_PORT, you can optionally define the host IP to bind to. If you just set the port, VNC binds to 127.0.0.1 |
| `MOODLE_DOCKER_APP_PATH` | no | path on your file system | not set | If set and the chrome browser is selected, it will start an instance of the Moodle app from your local codebase |
| `MOODLE_DOCKER_APP_VERSION` | no | a valid [app docker image version](https://docs.moodle.org/dev/Moodle_App_Docker_images) | not set | If set will start an instance of the Moodle app if the chrome browser is selected |
Expand Down
2 changes: 1 addition & 1 deletion base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ services:
- "${ASSETDIR}/exttests/apache2_ports.conf:/etc/apache2/ports.conf"
- "${ASSETDIR}/exttests/apache2.conf:/etc/apache2/sites-enabled/000-default.conf"
selenium:
image: "selenium/standalone-firefox${MOODLE_DOCKER_SELENIUM_SUFFIX:-}:${MOODLE_DOCKER_BROWSER_TAG}"
image: "${MOODLE_DOCKER_SELENIUM_REPOSITORY}/standalone-firefox${MOODLE_DOCKER_SELENIUM_SUFFIX:-}:${MOODLE_DOCKER_BROWSER_TAG}"
volumes:
- "${MOODLE_DOCKER_WWWROOT}:/var/www/html:ro"
9 changes: 8 additions & 1 deletion bin/moodle-docker-compose
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,14 @@ then
dockercompose="${dockercompose} -f ${basedir}/moodle-app-$MOODLE_DOCKER_APP_RUNTIME.yml"
fi

# Selenium browser
# Selenium configuration.

if [[ ! -z "$(uname -m | grep arm)" ]];
then
export MOODLE_DOCKER_SELENIUM_REPOSITORY="${MOODLE_DOCKER_SELENIUM_REPOSITORY:-seleniarm}"
fi
export MOODLE_DOCKER_SELENIUM_REPOSITORY="${MOODLE_DOCKER_SELENIUM_REPOSITORY:-selenium}"

browserparts=(${MOODLE_DOCKER_BROWSER//:/ })
export MOODLE_DOCKER_BROWSER_NAME=${browserparts[0]}
export MOODLE_DOCKER_BROWSER_TAG=${browserparts[1]}
Expand Down
7 changes: 7 additions & 0 deletions bin/moodle-docker-compose.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,13 @@ IF "%MOODLE_DOCKER_BROWSER_TAG%"=="" (
)
)

IF "%MOODLE_DOCKER_SELENIUM_REPOSITORY%"=="" (
REM Default to official selenium images by default.
REM TODO: Once There is a Windows Docker Desktop for Arm64, we should make
REM this conditionally, surely checking for %PROCESSOR_ARCHITECTURE% or so.
SET MOODLE_DOCKER_SELENIUM_REPOSITORY=selenium
)

IF NOT "%MOODLE_DOCKER_BROWSER_NAME%"=="firefox" (
SET DOCKERCOMPOSE=%DOCKERCOMPOSE% -f "%BASEDIR%\selenium.%MOODLE_DOCKER_BROWSER_NAME%.yml"
)
Expand Down
2 changes: 1 addition & 1 deletion selenium.chrome.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ services:
environment:
MOODLE_DOCKER_BROWSER: chrome
selenium:
image: "selenium/standalone-chrome${MOODLE_DOCKER_SELENIUM_SUFFIX:-}:${MOODLE_DOCKER_BROWSER_TAG}"
image: "${MOODLE_DOCKER_SELENIUM_REPOSITORY}/standalone-chrome${MOODLE_DOCKER_SELENIUM_SUFFIX:-}:${MOODLE_DOCKER_BROWSER_TAG}"
volumes:
- /dev/shm:/dev/shm