0

I am installing on a Debian 12 server running Apache2 and PHP. I installed Postfix, and now I get the following configuration screen:

No configuration:
Should be chosen to leave the current configuration unchanged.
Internet site:
Mail is sent and received directly using SMTP.
Internet with smarthost:
Mail is received directly using SMTP or by running a utility such
as fetchmail. Outgoing mail is sent using a smarthost.
Satellite system:
All mail is sent to another machine, called a 'smarthost', for
delivery.
Local only:
The only delivered mail is the mail for local users. There is no
network.

I want to be able to send using either the local server ("Internet site") or a gmail account ("Satellite system"), depending on specific applications on that server.

Can/Should I choose both? I would just need to change the smtp server in the phpmailer configuration to use one option or the other. Also, how do I do it? Do I run postfix twice? Will it hold both options in its configuration file?

1 Answer 1

1

Can/Should I choose both? I would just need to change the smtp server in the phpmailer configuration to use one option or the other.

No. If you're just going to change the SMTP server in phpmailer, then you're not going to use Postfix anymore, therefore there's no need to integrate Postfix with Gmail.

Also, how do I do it? Do I run postfix twice? Will it hold both options in its configuration file?

It won't. That's not impossible, but it would require a way of telling Postfix when to use one option or the other. (For example, it's possible to configure this kind of routing based on the "From" address.)

(Changing the SMTP server in phpmailer doesn't tell Postfix anything – it bypasses Postfix. Postfix is your local SMTP server.)

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.