Skip to content

maximaster/file-mailer-transport

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

File Mailer Transport

Do you want to save your symfony/mailer emails as files (e.g. .EML)?

You've just found the right package!

Usage

composer require maximaster/file-mailer-transport

services.yaml

    Maximaster\FileMailerTransport\TransportFactory:
        arguments:
            $projectDir: '%kernel.project_dir%'

    mailer.default_transport:
        class: Symfony\Component\Mailer\Transport\TransportInterface
        factory: '@Maximaster\FileMailerTransport\TransportFactory'
        arguments:
            $dsn: '%env(MAILER_DSN)%'

.env

MAILER_DSN=file:///upload/emails/%Y/%m/%d/%[email protected]

Options

  • new_directory_mode - with which rights new directory will be created
  • hash_algo - controls how @hash replacement is calculated
  • path_renderer - callback which is supposed to render a real file path from a path template

About

Saves served emails as files

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages