namshi / docker-smtp

SMTP docker container
MIT License
548 stars 199 forks source link

trouble with sending emails #57

Open TigenTigen opened 5 years ago

TigenTigen commented 5 years ago

Hello, not sure to write it here, but I can't solve the problem by myself, so... I used this docker image to run as single smtp server for web app via docker-compose. Compose configuration: ` smtp: image: namshi/smtp:latest networks:

Logs: `

`

vesamet commented 4 years ago

Same

ArtyIF commented 4 years ago

I have the same issue. My SMTP service in docker-compose.yml goes as follows:

  smtp:
    image: namshi/smtp
    restart: always
    ports:
      - '25:25'
    volumes:
      - ./:/web
    environment: 
      - KEY_PATH=/web/config/ssl_keys/privkey.pem
      - CERTIFICATE_PATH=/web/config/ssl_keys/fullchain.pem

with ./ also being used by Django and Celery. I'm trying to send email through Django, here's my settings.py:

EMAIL_HOST = 'smtp'
EMAIL_PORT = '25'
EMAIL_USE_TLS = True
DEFAULT_FROM_EMAIL = 'noreply@localhost'

I'm trying to send a password reset email through saving a PasswordResetForm (how it's done by a default implementation, had to make my own for reasons).

Someone help?

roseyda commented 4 years ago

Same issue. Any idea ?

ArtyIF commented 4 years ago

turns out i needed to add a couple DNS records (MX, DMARC, SPF and DKIM)

fredericoschardong commented 2 years ago

turns out i needed to add a couple DNS records (MX, DMARC, SPF and DKIM)

Could you please elaborate a bit more for us newbies? :-)