#

Mailhog for dev setup

Posted on: December 23rd 2019, 4:02:05 pm
$ docker run -d -p 1025:1025 -p 8025:8025 --name mailhog mailhog/mailhog

Open browser in http://localhost:8025/#

Update settings of apps to use localhost smtp

# Django
EMAIL_HOST='127.0.0.1'
EMAIL_PORT=1025
EMAIL_HOST_USER=''
EMAIL_HOST_PASSWORD=''
EMAIL_USE_TLS=False

# nodemailer
const transporter = nodemailer.createTransporter({
host: '127.0.0.1,
port: '1025',
secure: false})