Weird Email Setup

Hi,

I have just got virtualmin up and running, so far so good, the only issue is email. For most of my customers I recommend Google Apps because of the interface, storage etc., however, I am a bit stuck on how to configure the following:

  • I don’t want email delivered to my VPS, (I guess this is solved by the MX records pointing at google), however it would be good to disable it anyway.

  • User scripts will still need to send emails, is it possible to set the sendmail or other smtp server to proxy the mail onto google’s SMTP server (as I want the email to appear if possible from the user’s domain, not my vps’ domain).

Any pointers will be appreciated,

Regards,

Tom

- I don't want email delivered to my VPS, (I guess this is solved by the MX records pointing at google), however it would be good to disable it anyway.

Do just what you said…disable mail for the virtual servers when you create them. (Enabled Features)

To do it for all new virtual servers, do it in the Server Template(s) that you use.

- User scripts will still need to send emails, is it possible to set the sendmail or other smtp server to proxy the mail onto google's SMTP server (as I want the email to appear if possible from the user's domain, not my vps' domain).

This is wholly orthogonal to where you receive mail. Mail does not need to be enabled for a virtual server for you to be able to use the local SMTP server to send mail (you do probably want to make sure you have SPF records in DNS, though). The From: address in email is set by the client sending the message, not the mail server, and the origin in the headers is irrelevant since no one sees it (and it won’t appear as being from your user’s domain if it goes through Google…it’ll appear as being from Google’s servers–the header information must accurately reflect the actual server it went through or spam filters will treat it mercilessly).