Lucas,

> I'm migrating my database from postgresql to mysql and
> I found a problem with the order that the rules are read.
>
> I have this registers in policy table.
>   [...]
> users table:
> | id | priority | policy_id | email            | fullname | local |
> |  2 |        7 |         4 | @domain.com      | NULL     | Y     |
> |  3 |        7 |         5 | [email protected] | NULL     | Y     |


> When the account '[email protected]' receive an e-mail, amavisd works
> with the values defined to policy 'domain.com' rather than work with
> specific rules (policy_name [email protected]).
> With postgresql database I didn't have this problem.

Your mistake is that you used the same priority for both
'users' records. The more specific user.email entries
should have a higher user.priority. That's the whole
purpose of the 'ORDER BY users.priority DESC', letting
the more specific address match first.

In my example in README_FILES/README.sql I use the
following priority values:

  9  user+extens...@domain
  7  u...@domain
  5  @domain
  3  user
  0  @.  (catchall)


Mark

------------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It is the best place to buy or sell services for
just about anything Open Source.
http://p.sf.net/sfu/Xq1LFB
_______________________________________________
AMaViS-user mailing list
[email protected] 
https://lists.sourceforge.net/lists/listinfo/amavis-user 
 AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3 
 AMaViS-HowTos:http://www.amavis.org/howto/ 

Reply via email to