How to configure mailpit in local dev environment if normal sendmail will fail.
You had problems to receive mails in mailhog in a local setup with sendmail configuration.
// mailsender command for the "Symfony Mailer" module for drupal 10
$settings['mailer_sendmail_commands'] = [
'/usr/local/bin/mailpit sendmail -t --smtp-addr=mail:1025',
];
Prerequisite:
You have the Drupal Symfony Mailer module enabled and have a local Config Split running.
Issue:
You had problems to receive mails in mailhog in a local setup with sendmail configuration.
Solution:
Add this custom command to the sendmail configuration in your settings.local.php.
After adding go to `/admin/config/system/mailer/transport` and create a transport type 'sendmail'. Chose our newly added command and save the configuration.
Add the `symfony_mailer.mailer_transport.sendmail` config to your partial split configuration for your local split and then export the configuration.
Ihre Drupal-Website zukunftssicher machen
Wir prüfen Ihr System und zeigen, was Sie für AI, Wartung und Upgrades brauchen.