Skip to content

Commit bb6746c

Browse files
committed
Explain multiple entries in virtual_alias_maps via pillar.example
1 parent c432ae2 commit bb6746c

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

pillar.example

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,3 +235,24 @@ postfix:
235235
236236
237237
- singlealiasexample: [email protected]
238+
239+
240+
###
241+
#
242+
# Multiple virtual_alias_maps entries:
243+
#
244+
# You are free to define alternative mapping names
245+
# and use them as 'variables' in your Postfix config:
246+
# (Credit for the idea and the example goes to @roskens.)
247+
248+
postfix:
249+
config:
250+
virtual_alias_maps: $virtual_alias_1_maps $virtual_alias_2_maps
251+
virtual_alias_1_maps: hash:/etc/postfix/virtual
252+
virtual_alias_2_maps: pcre:/etc/postfix/virtual.pcre
253+
mapping:
254+
virtual_alias_1_maps:
255+
root:
256+
- me
257+
virtual_alias_2_maps:
258+
- '/(\S+)_(devel|preprod|prod)@sub.example.com$/': '$(1)@$(2).sub.example.com'

0 commit comments

Comments
 (0)