Skip to content

Commit fea3a8d

Browse files
authored
Merge pull request #107 from ljohnston/master
Add postfix_smtp_generic_maps_database_type
2 parents c69a7b8 + 81f9288 commit fea3a8d

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ None
3030
* `postfix_header_checks` [default: `[]`]: Lookup tables for content inspection of primary non-MIME message headers `/etc/postfix/header_checks` ([see](http://www.postfix.org/postconf.5.html#header_checks))
3131
* `postfix_header_checks_database_type` [default: `regexp`]: The database type for use in `header_checks`
3232
* `postfix_generic` [default: `[]`]: Generic table address mapping in `/etc/postfix/generic` ([see](http://www.postfix.org/generic.5.html))
33+
* `postfix_smtp_generic_maps_database_type` [default: `"{{ postfix_default_database_type }}"`]: The database type for use in `smtp_generic_maps`
3334

3435
* `postfix_mydestination` [default: `["{{ postfix_hostname }}", 'localdomain', 'localhost', 'localhost.localdomain']`]: Specifies what domains this machine will deliver locally, instead of forwarding to another machine
3536
* `postfix_mynetworks` [default: `['127.0.0.0/8', '[::ffff:127.0.0.0]/104', '[::1]/128']`]: The list of "trusted" remote SMTP clients that have more privileges than "strangers"

defaults/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ postfix_sender_dependent_relayhost_maps: []
2323
postfix_header_checks: []
2424
postfix_header_checks_database_type: regexp
2525
postfix_generic: []
26+
postfix_smtp_generic_maps_database_type: "{{ postfix_default_database_type }}"
2627

2728
postfix_relayhost: ''
2829
postfix_relayhost_mxlookup: false

handlers/main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
when: postfix_default_database_type != 'regexp'
3030

3131
- name: postmap generic
32-
command: postmap {{ postfix_default_database_type }}:{{ postfix_generic_file }}
33-
when: postfix_default_database_type != 'regexp'
32+
command: postmap {{ postfix_smtp_generic_maps_database_type }}:{{ postfix_generic_file }}
33+
when: postfix_smtp_generic_maps_database_type != 'regexp'
3434

3535
- name: remove pid
3636
file:

templates/etc/postfix/main.cf.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ transport_maps = {{ postfix_transport_maps_database_type }}:{{ postfix_transport
5252
sender_dependent_relayhost_maps = {{ postfix_default_database_type }}:{{ postfix_sender_dependent_relayhost_maps_file }}
5353
{% endif %}
5454
{% if postfix_generic %}
55-
smtp_generic_maps = {{ postfix_default_database_type }}:{{ postfix_generic_file }}
55+
smtp_generic_maps = {{ postfix_smtp_generic_maps_database_type }}:{{ postfix_generic_file }}
5656
{% endif %}
5757
{% if postfix_header_checks %}
5858
smtp_header_checks = {{ postfix_header_checks_database_type }}:{{ postfix_header_checks_file }}

0 commit comments

Comments
 (0)