Problem/Motivation

The default swiftmailer config is to use sendmail with the bs option.

Stand-alone SMTP server mode. Read SMTP commands from standard input, and write responses to standard output. In stand-alone SMTP server mode, mail relaying and other access
controls are disabled by default. To enable them, run the process as the mail_owner user.
This mode of operation is implemented by running the smtpd(8) daemon.

The issue is that this mode isn't allowed on some more secure hosting providers (such as Platform.sh). Instead they will have their PHP settings configured to use the t option.

Extract recipients from message headers. These are added to any recipients specified on the command line.<

This is also indicated in an issue open for Swiftmailer itself which will probably not get fixed: https://www.drupal.org/project/swiftmailer/issues/3174215#comment-13845855

Steps to reproduce

Install Open Social on a server that has sendmail_path configured to /usr/sbin/sendmail -t -i in their php.ini and try to send an email.

Proposed resolution

Adjust the social_swiftmail_install hook to update the sendmail_mode in the swiftmailer.transport config based on the PHP settings. This ensures that the t mode is properly used on supported platforms so that emailing in Open Social works out of the box.

Remaining tasks

User interface changes

API changes

Data model changes

Comments

Kingdutch created an issue. See original summary.

kingdutch’s picture

ronaldtebrake’s picture

Status: Needs review » Reviewed & tested by the community
ronaldtebrake’s picture

Status: Reviewed & tested by the community » Fixed

Will be only on new installs in 10.3.x / 11.0.x

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.