diff --git a/.docker/php/custom.ini b/.docker/php/custom.ini new file mode 100644 index 0000000..cd039a7 --- /dev/null +++ b/.docker/php/custom.ini @@ -0,0 +1 @@ +sendmail_path=/usr/sbin/sendmail -S localhost:1025 -t diff --git a/.env.dist b/.env.dist index d9ad487..b8ca3ae 100644 --- a/.env.dist +++ b/.env.dist @@ -2,6 +2,7 @@ WEB_PORT=8080 MYSQL_PORT=3306 SELENIUM_PORT=4444 VNC_PORT=5900 +MAIL_PORT=8025 BASE_URI=http://127.0.0.1:8080 UID=1000 GID=1000 diff --git a/README.md b/README.md index 615368e..dc18bd5 100644 --- a/README.md +++ b/README.md @@ -100,6 +100,11 @@ in order to see tests running in the browser. Using a VNC client such as Remmina simply connect to port `127.0.0.1:5900` with the password `secret`. If you've changed the `VNC_PORT` environment variable be sure to connect to that port instead. +## Mailpit + +The mailpit service is available and configured to capture email sent from the site. This can be +accessed at http://localhost:8025. For more info see https://github.com/axllent/mailpit. + ## Contributing Once you're up and running you'll have Drupal core checked out in the app directory. From here you diff --git a/docker-compose.yml b/docker-compose.yml index fab63eb..beb4bc7 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,6 +6,8 @@ services: - "${MYSQL_PORT:-3306}:3306" - "${SELENIUM_PORT:-4444}:4444" - "${VNC_PORT:-5900}:5900" + - "${SMTP_PORT:-1025}:1025" + - "${MAIL_PORT:-8025}:8025" extra_hosts: - "host.docker.internal:host-gateway" volumes: @@ -23,6 +25,7 @@ services: network_mode: service:nginx volumes: - ./:/data + - ./.docker/php/custom.ini:/etc/php/conf.d/99-custom.ini environment: - PHP_IDE_CONFIG=serverName=localhost @@ -43,6 +46,7 @@ services: - PHP_IDE_CONFIG=serverName=localhost volumes: - ./:/data + - ./.docker/php/custom.ini:/etc/php/conf.d/99-custom.ini mysql: image: mysql:latest @@ -60,3 +64,7 @@ services: selenium: image: ${SELENIUM_IMAGE:-selenium/standalone-chrome:111.0} network_mode: service:nginx + + mail: + image: axllent/mailpit + network_mode: service:nginx