0

I've got several alias files being used as sources for virtual aliases in Postfix, one of which is auto-generated. Sometimes, this one contains aliases that conflict with those declared in static files; how does Postfix decide which alias to prefer?

Scenario 1

static:

postmaster@my.domain authorised-user@my.domain

dynamic:

postmaster@my.domain wrong-user@other.domain

Can I force it to choose my static one over another? I can't exercise control over the dynamic file, so I need some measure of protection here.

Desired result: postmaster@my.domain -> authorised-user@my.domain

Scenario 2

static:

webmaster@my.domain user1@my.domain

dynamic:

webmaster@my.domain user2@other.domain

Sometimes I need to add temporary users to an alias, so they go into the dynamic file; can these be merged in some cases instead of overriding as above?

Desired result: webmaster@my.domain -> user1@my.domain, user2@my.domain

Iain Hallam
  • 447
  • 2
  • 6
  • 22

1 Answers1

0

According to the Postfix documentation, any conflict is resolved by precedence: first come, first served.

Richard T
  • 1,206
  • 12
  • 29
  • I've not been able to find that in the docs - have you got a reference, please? – Iain Hallam Sep 21 '13 at 11:49
  • @IainHallam Not off hand, but it may be in the main.cf file. ...I'd go look, but our mail server is down and I'm focused on that right now... – Richard T Sep 22 '13 at 16:41
  • I don't see it in main.cf or the man pages, but this does seem to work - the first one to define an alias is definitive and later definitions are ignored. – Iain Hallam Feb 05 '14 at 16:53