Sign inSign up

ogulcanaydogan/mailpit

By ogulcanaydogan

Updated 7 months ago

Local SMTP server with web UI for development email testing

Image
0

1.0K

ogulcanaydogan/mailpit repository overview

Mailpit

Local SMTP server with web UI for development email testing. Catch all outgoing emails without delivering them.

Quick Start

docker run -p 1025:1025 -p 8025:8025 ogulcanaydogan/mailpit

Then open http://localhost:8025 to view captured emails.

Features

  • SMTP server on port 1025
  • Web UI on port 8025
  • REST API for programmatic access
  • Message search and filtering
  • SMTP relay support
  • Persistent storage option

Environment Variables

VariableDescriptionDefault
MP_SMTP_BIND_ADDRSMTP listen address0.0.0.0:1025
MP_UI_BIND_ADDRWeb UI listen address0.0.0.0:8025
MP_MAX_MESSAGESMaximum stored messages500
MP_DATABASEDatabase file path/data/mailpit.db
MP_SMTP_AUTH_ACCEPT_ANYAccept any SMTP auth-
MP_SMTP_RELAY_HOSTRelay SMTP host-
MP_SMTP_RELAY_PORTRelay SMTP port-

Docker Compose Example

services:
  app:
    image: myapp
    environment:
      - SMTP_HOST=mailpit
      - SMTP_PORT=1025

  mailpit:
    image: ogulcanaydogan/mailpit
    ports:
      - "1025:1025"
      - "8025:8025"
    volumes:
      - mailpit-data:/data

volumes:
  mailpit-data:

API Endpoints

  • GET /api/v1/info — Server info
  • GET /api/v1/messages — List messages
  • GET /api/v1/message/{id} — Get message
  • DELETE /api/v1/messages — Delete all messages
  • GET /api/v1/search?query=... — Search messages

License

MIT

Tag summary

Content type

Image

Digest

sha256:24ee610c6

Size

15.9 MB

Last updated

7 months ago

docker pull ogulcanaydogan/mailpit