I'd like to define the SMTP server deets in my local config as I regularly need to push/pull databases between environments and will have different settings.

There doesn't seem to be any of doing this currently. Are there any workarounds? I thought maybe I could just put the SMTP deets in my code (testing for current enviroment) but the EmailModel class doesn't accept any of the SMTP-related properties of PHPMailer.


Currently email settings aren't multi-environment aware, so there is no native way to do this.

Probably worth adding to the feedback site, as this has come up before, though.

  • Ok thanks. I would add feedback but I've run out of feedback credits! May 5 '15 at 9:36
  • Just checked and I must have earned some credits—have posted feedback. May 5 '15 at 9:40

Shameless plug: We've written a plugin that automatically updates your email settings depending on your environment. It's not free, but it is cheap :-) Please check out the page on our website for more information.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.