I'm trying to setup a postfix server for testing our app which uses oracle mail library javax.mail to send mail. The app works fine as I'm able to use google, our own mail server, etc to send mail.
The problem I'm getting when sending an ehlo test is 5.7.1 relay access denied. I see there are hundreds of these questions but none have helped me understand how this actually works.
If I list yahoo.com as a 'relay_domain' in main.cf, I can send mail to a yahoo recepient. I am not really grasping what this means, do I list all domains I want to send mail to here (surely not). Sorry for the noob style question but most of the guides for this seem to be geared for people with a better understanding of how email works.
postfix is running on centOS.
Here's my config differences.
alias_database = hash:/etc/aliases alias_maps = hash:/etc/aliases command_directory = /usr/sbin config_directory = /etc/postfix daemon_directory = /usr/libexec/postfix data_directory = /var/lib/postfix debug_peer_level = 2 html_directory = no inet_interfaces = localhost inet_protocols = all mail_owner = postfix mailq_path = /usr/bin/mailq.postfix manpage_directory = /usr/share/man mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain, mail.$mydomain, www.$mydomain, ftp.$mydomain mydomain = *****.com myhostname = mail.*****.com mynetworks = 192.168.1.0/200, 127.0.0.0/8 myorigin = $myhostname newaliases_path = /usr/bin/newaliases.postfix queue_directory = /var/spool/postfix readme_directory = /usr/share/doc/postfix-2.6.6/README_FILES relay_domains = $mydestination sample_directory = /usr/share/doc/postfix-2.6.6/samples sendmail_path = /usr/sbin/sendmail.postfix setgid_group = postdrop unknown_local_recipient_reject_code = 550