is not true! Providing a file under /config/plugin.js does not change the email provider!
In order to change the defaultFrom or defaultReplyTo or anything else, you need to put following code inside the register function found in “./src/index.ts”
should look like this:
register(/*{ strapi }*/) {
strapi.config.set('plugin.email', {
provider: 'strapi-provider-email-smtp',
providerOptions: {
host: ('MAIL_HOST'), //SMTP Host
port: 465, //SMTP Port
secure: true,
username: `${('MAIL_USERNAME')}@${('MAIL_DOMAIN')}`,
password: ('MAIL_PASSWORD'),
rejectUnauthorized: true,
requireTLS: true,
connectionTimeout: 1,
},
settings: {
defaultFrom: `${('MAIL_USERNAME')}@${('MAIL_DOMAIN')}`,
defaultReplyTo: `${('MAIL_USERNAME')}@${('MAIL_DOMAIN')}`,
}
})
}
this will work! If you do this, the provider will change, you can see the changes under http://localhost:1337/admin/settings/email