Mam wykupiony serwer VPS i chciałbym móc wysyłać z niego maile korzystając z już istniejącego konta email na gmail-u.
Kombinuje z Postfixem. W /etc/postfix/main.cf dodałem:
relayhost = [smtp.gmail.com]:587
smtp_use_tls = yes
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous
utworzyłem plik: /etc/postfix/sasl_passwd
[smtp.gmail.com]:587 [email protected]:password
dalej
postmap /etc/postfix/sasl_passwd
i
systemctl reload postfix
i próbuje wysłać testowego maila:
echo "Testowy mail." | mail -s "Testowy email" [email protected]
mail niestety nie wysyła się a w logach widzę taki wpis:
Apr 20 08:29:20 vps-xxx postfix/pickup[416890]: 0DF611E1B3: uid=1000 from=<[email protected]>
Apr 20 08:29:20 vps-xxx postfix/cleanup[416911]: 0DF611E1B3: message-id=<[email protected]>
Apr 20 08:29:20 vps-xxx postfix/qmgr[416891]: 0DF611E1B3: from=<[email protected]>, size=441, nrcpt=1 (queue active)
Apr 20 08:29:20 vps-xxx postfix/error[416915]: 0DF611E1B3: to=<[email protected]>, relay=none, delay=0.05, delays=0.03/0.01/0/0.01, dsn=5.0.0, status=bounced ([smtp.gmail.com]:587)
Apr 20 08:29:20 vps-xxx postfix/cleanup[416911]: 334D17E2B4: message-id=<[email protected]>
Apr 20 08:29:20 vps-xxx postfix/qmgr[416891]: 334D17E2B4: from=<>, size=2424, nrcpt=1 (queue active)
Apr 20 08:29:20 vps-xxx postfix/bounce[416916]: 0DF611E1B3: sender non-delivery notification: 334D17E2B4
Apr 20 08:29:20 vps-xxx postfix/qmgr[416891]: 0DF611E1B3: removed
Apr 20 08:29:20 vps-xxx postfix/local[416918]: 334D17E2B4: to=<[email protected]>, relay=local, delay=0.02, delays=0/0.01/0/0, dsn=2.0.0, status=sent (delivered to mailbox)
Apr 20 08:29:20 vps-xxx postfix/qmgr[416891]: 334D17E2B4: removed
Podpowie ktoś co robię źle?