Commit Graph

373 Commits

Author SHA1 Message Date
Niels Abspoel
ca6b26e3ed
Merge pull request #75 from bawuenet/more_services
More pillar managed services
2018-10-01 22:49:54 +02:00
Javier Bértoli
4fb57c98a8
Merge pull request #77 from bawuenet/main_iteration
Improve handling of multiple values in main.cf
2018-09-29 08:42:20 -03:00
Andreas Thienemann
36f0a70813 Improve handling of multiple values in main.cf
In case a list of items (iterable) is passed to the set_parameter
function in main.cf, the list of items are joined by a comma.

This makes parameters with many items a bit hard to read as it
results in long lines.

Postfix also supports an alternative declaration where subsequent
parameter values are written in a new line that starts with whitespace
and thus forms a continuation of the previous line.
This makes parsing multiple entry lines easier for humans.

Old style:
smtpd_milters = { unix:/run/spamass-milter/postfix/sock, connect_timeout=10s, default_action=accept } { inet:localhost:10003, connect_timeout=10s, default_action=accept } { inet:localhost:10004, connect_timeout=10s, default_action=accept } { inet:localhost:10006, connect_timeout=10s, default_action=accept } { inet:localhost:10007, connect_timeout=10s, default_action=accept }

New style:
smtpd_milters = { unix:/run/spamass-milter/postfix/sock, connect_timeout=10s, default_action=accept }
                { inet:localhost:10003, connect_timeout=10s, default_action=accept }
                { inet:localhost:10004, connect_timeout=10s, default_action=accept }
                { inet:localhost:10006, connect_timeout=10s, default_action=accept }
                { inet:localhost:10007, connect_timeout=10s, default_action=accept }
2018-09-29 03:55:38 +02:00
Javier Bértoli
a4cdd1acd2
Merge pull request #74 from bawuenet/postfix_reload
Reload postfix service by default.
2018-09-27 22:00:35 -03:00
N
4a3a94fb39
Merge pull request #76 from netmanagers/master
Fix testing
2018-09-28 00:16:06 +01:00
Javier Bértoli
768cc62f66 Fix testing 2018-09-27 15:12:42 -03:00
Andreas Thienemann
1b9ac1eb4e More pillar managed services
Most of the services in master.cf were already configurable through
the formula but specific ones such as cyrus or uucp were not managed
yet.

This commit adds functionality to manage these services as well
through pillar variables, e.g.:

postfix:
  master_config:
    services:
      uucp:
	enable: True
2018-09-26 21:52:02 -07:00
Andreas Thienemann
44210a1fe8 Reload postfix service by default.
The postfix service is currently being restarted whenever a
config item changes.
This is unnecessary as the postfix service can reload a new
config.

Set reload: True to prevent unnecessary restarts of the service.
The old behavior can be restored by setting the pillar key
reload_service to False.
2018-09-26 17:33:14 -07:00
Niels Abspoel
3ded29687e
Merge pull request #73 from Perceptyx/master
Force batch in FreeBSD
2018-09-25 20:54:58 +02:00
Javier Bértoli
f8cebbfe8e
Merge pull request #72 from asenci/fix_duplicated_maps
Fix duplicated mapping parameters on main.cf
2018-09-01 09:44:28 -03:00
Andre Sencioles
e40c589cd5 Fix duplicated mapping parameters on main.cf
Fixes the creation of duplicated parameters on main.cf by using the
"set_parameter" macro to append the mapping parameter to the
"processed_parameters" list.
2018-08-29 15:34:31 +12:00
Felipe Zipitria
7ede7609f7 Force batch in FreeBSD 2018-07-24 14:38:10 +01:00
Niels Abspoel
cf42ec7e8c
Merge pull request #71 from Poil/add_inet_protocols
add inet_protocols
2018-07-09 12:19:46 +02:00
Benjamin DUPUIS
fe261fc635 add inet_protocols 2018-07-09 11:32:16 +02:00
Javier Bértoli
b19eb93f9c
Merge pull request #70 from saltstack-formulas/bugfixes
master.cf: submission: CSV must not use blank
2018-04-04 07:33:21 -03:00
Alexander Weidinger
0c489c03df master.cf: submission: CSV must not use blank
Would produce: "fatal: unexpected command-line argument: nameofsetting,"
2018-04-04 11:34:34 +02:00
Niels Abspoel
84605b0237
Merge pull request #66 from netmanagers/master
Basic testing framework
2018-04-01 21:54:26 +02:00
Javier Bértoli
1087f3b85e Basic testing framework 2018-03-18 16:49:49 -03:00
Niels Abspoel
62abea758a
Merge pull request #67 from netmanagers/fix_bin_prefix
Fix xbin_prefix parameter, add managed by Salt headers
2018-03-18 20:11:38 +01:00
Javier Bértoli
47ffa7d173 Fix xbin_prefix parameter, add managed by Salt headers 2018-03-18 14:08:45 -03:00
Niels Abspoel
9399043497
Merge pull request #65 from bawuenet/configurable_services
Allow for full managed master.cf services
2018-03-18 17:16:15 +01:00
Andreas Thienemann
b6b7ab4cca Allow for full managed master.cf services
Currently master.cf only allows for _very_ limited configuration
options mainly focussed on SMTP submission settings.

This is rather limited and does not scale very well for managing
the other services defined in master.cf.

This patch has moved all the service definitions into a jinja file
and generates the master.cf service definition on the fly based on
these defaults.

Defaults can be overridden in a pillar to customize the rendered
master.cf file accordingly to local needs.
Undefined values will be filled with the postfix defaults.

Care has been taken that the previous ways of managing the submission
configuration options are still supported for backwards compatibility
to prevent breakage for existing users of the formula.
2018-03-11 19:22:12 +01:00
N
e9ef0aa547
Merge pull request #56 from vquiering/add_mysql_query_to_virtual
Add a mysql query to 'virtual' files
2018-03-08 09:43:26 +00:00
N
5579ebcef6
Merge branch 'master' into add_mysql_query_to_virtual 2018-03-08 09:40:09 +00:00
Javier Bértoli
b40258211e
Merge pull request #64 from aboe76/python3_support
replace iteritems with items
2018-03-07 19:38:59 -03:00
Niels Abspoel
f30071afd2 replace iteritems with items 2018-03-07 21:17:57 +01:00
Niels Abspoel
16f73256b2
Merge pull request #63 from saltstack-formulas/configurable-master-config
Configurable master_config.cf
2017-12-30 22:46:19 +01:00
Alexander Weidinger
f4a10a2843 re-enable Pillar postfix:aliases:content 2017-12-28 21:42:23 +01:00
Alexander Weidinger
014c5227bc Let the user handle mappings manually 2017-12-08 14:53:58 +01:00
Alexander Weidinger
caee184158 master.cf: added dovecot 2017-12-08 14:04:35 +01:00
Alexander Weidinger
4c7c2a269d master.cf: made submission configurable 2017-12-08 13:20:01 +01:00
Alexander Weidinger
ae878da8fa Use defaults.yaml and osmap.yaml 2017-12-08 12:12:56 +01:00
Florian Ermisch
9ed99927c2 explain what the colon in mapping.j2 is for 2017-08-25 14:54:20 +02:00
Florian Ermisch
f514881e5a explain the difference between alias_maps and alias_database 2017-08-24 13:35:24 +02:00
Florian Ermisch
c60c3bab6f adjust processed_parameters to match pillar.example 2017-08-24 13:25:38 +02:00
Florian Ermisch
8eed254773 one for-loop for all of the mappings 2017-08-24 13:10:54 +02:00
Florian Ermisch
136e02a61c check for absolute file_paths for maps 2017-08-24 13:03:22 +02:00
Florian Ermisch
d51f60647a add optional context variable "colon" to mapping.j2 for aliases file 2017-08-24 13:03:10 +02:00
Florian Ermisch
099d84ab73 Template paths and groups to make them work on FreeBSD, too. 2017-08-24 13:02:46 +02:00
Florian Ermisch
af5e9f8862 Add FreeBSD to map.jinja; root_grp, xbin_prefix to defaults.yaml
Accidentally already added config_path in the last commit, not
redoing it again.
2017-08-24 11:27:43 +02:00
Florian Ermisch
f30c63f9ed Import map.jinja+defaults.yaml structure from salt-formula
Now using the `deep_merge()` macro so we can move the
values which are identical on most distributions from
`map.jinja` to `defaults.yaml`.
2017-08-24 11:21:48 +02:00
Niels Abspoel
7fc82e0bd2 Merge pull request #57 from M2Mobi/aliases
Use alias states for managing mail aliases.
2017-08-03 15:51:23 +02:00
Heinz Wiesinger
e290d36699 Add option to manage mail aliases using alias states. 2017-05-08 16:55:14 +02:00
Vitali Quiering
f8514b3629 Add a mysql query to virtual_mailbox_domains, virtual_alias_maps virtual_mailbox_maps if mysql is declared in main.cf within these options 2017-04-12 17:06:16 +02:00
Niels Abspoel
21fc78dcf7 Merge pull request #55 from netmanagers/master
Minor formatting change
2017-03-29 14:58:58 +02:00
Javier Bértoli
026dd44dde Minor formatting change 2017-03-29 08:19:33 -03:00
Niels Abspoel
d1dfca2398 Merge pull request #54 from netmanagers/master
Use join() for iterable values in main.cf
2017-03-28 17:08:19 +02:00
Javier Bértoli
b0aa531297 Use join() for iterable values in main.cf 2017-03-28 11:57:34 -03:00
Lukas Erlacher
3183fc4351 Merge pull request #51 from EvaSDK/gh50-postconf-respect-file-type
Make postconf/newaliases respect file type
2017-02-23 09:36:33 +01:00
Gilles Dartiguelongue
961c1e10c4 Allow alias_database file type to be respected for running newaliases
See github issue #50.
2017-02-22 23:32:04 +01:00