Google Email as SMTP server for outgoing emails

Hi,

I have a main domain of www.mydomain.com I aslo have a subdomain of staging.mydomain.com.

I have setup Google Email on the base domain of mydomain.com and this is working fine receiving emails and sending emails via Google.

I am doing some dev work on the staging environment to send emails on a linux ubuntu servers using PHP and would want to use the already setup Google service from the base domain to send outgoing emails. Is this possible? or would I need to setup the google mail on the staging environment too..

We have referenced the email client setup information from Google to setup the details in the staging environment. http://mail.google.com/support/bin/answ … swer=78799">http://mail.google.com/support/bin/answer.py?answer=78799

However we still are not able to connect to the server.

Thanks

Simon

4 Replies

If I understand you correctly your staging site you want the linux server to send the emails and for the live site you want to send via google apps.

If so then for the staging site install postfix/exim (check out http://library.linode.com/email) and PHP will send via that.

For the live site check out MSMTP (google it).

Hi Obs,

Thanks for your reply, I want to send emails from the staging site via linux, however instead of installing a mail client to my staging site I want to use the Google Email currently setup on the live environment.

Iam hoping that I don't need to install a mail client in staging to then change the settings once we deploy to code live where we hope to still send emails via our PHP code.

Thanks..

You'll probably still have to set up a send-only MTA on your Linode. Exim is nice and easy -

http://library.linode.com/email/exim

How do you send via google on the live site? Can't you just use the same configuration on the test site?

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct