This base container is not currently aimed at public consumption. It exists as a starting point for August Ash containers.
3.0.0,latest(Dockerfile)2.0.0(Dockerfile)1.0.2(Dockerfile)1.0.1(Dockerfile)1.0.0(Dockerfile)
See VERSIONS.md for image contents.
Launch a MailHog container that can act as a development SMTP server with an HTTP interface:
docker run --rm \
-p 8025:8025 \
-p 1025:1025 \
--net <NETWORK NAME> \
augustash/alpine-mailhogYou must direct email to the running container and that can be done by SMTP or sendmail for PHP applications.
For example, in your php.ini configuration you can use the following line:
sendmail_path = /usr/sbin/sendmail -S <CONTAINER NAME/IP>:1025Alternatively you can look into MailHog's sendmail replacement called mhsendmail. If installed, it can be used like this:
sendmail_path = /usr/local/go/bin/mhsendmail --smtp-addr <CONTAINER NAME/IP>:1025Once running and capturing email, you can view the messages using the Web UI. If using the default hostname/ports, open a browser and visit MailHog Web UI.
To help avoid nasty permissions errors, the container allows you to specify your own PUID and PGID. This can be a user you've created or even root (not recommended).
The following variables can be set and will change how the container behaves. You can use the -e flag, an environment file, or your Docker Compose file to set your preferred values. The default values are shown:
PUID=501PGID=1000MAIL_STORAGE=memoryMAIL_SMTP_PORT=1025MAIL_API_PORT=8025MAIL_HOSTNAME=mailhog.testMAIL_PARAMS=
