[Pkg-exim4-users] Questions about configuring

Marc Haber mh+pkg-exim4-users@zugschlus.de
Sat, 4 Jun 2005 21:56:40 +0200


On Wed, Jun 01, 2005 at 01:28:34PM -0700, Ross Boylan wrote:
> On Sun, 2005-05-29 at 08:10 +0200, Andreas Metzler wrote: 
> > If you are using unsplit, you should edit exim4.conf.template (or in
> > 4.50-8 and later /etc/exim4/exim4.conf.localmacros) else place them
> > in a new file, that is read before the others.
> I assume "else" mean "if you use split".  That was the missing piece for
> me, and I think the 4.50-8 docs are much clearer on this.
> 
> I want to double-check that stuff I put in main/00_local is read before
> things in the acl/ directory (for example).

Yes, as the exim configuration has a pre-defined order of the
configuration sections in the config file. Macro definitions can only
be in the main section (this will change for exim4 4.51, which allows
macro definitions at almost any place in the config).

> The new README seems to
> indicate everything can go under main, and the update-exim4.conf manpage
> indicates main is read first.  Since the general logic is by
> alphabetical order, and acl precedes main, I'm a little concerned
> changes to acl need to go in acl/00_local.

Well, we assume that people intending to mess with exim's
configuration beyond the pre-fabricated stuff that we offer have
acquired some basic familiarity with exim configuration beforehand. I
don't think that this should be a misassumption.

> Proposed change update-exim4.conf manpage, to make that interpretation
> clearer (as well as clarifying some other things, indicated in square
> brackets in the original):
> Current
> Depending [how?] on the setting of dc_use_split_config     in
> /etc/exim4/update-exim4.conf.conf  update-exim4.conf  either  sorts the
> files in  the  subdirectories  main,  acl,  router,  transport,  retry,
> rewrite  and  auth [in that order?] of /etc/exim4/conf.d in the lexical
> sort order [of what?], con-
> catenates them and replaces  the  patterns  DEBCONFsomethingDEBCONF  or
> only   replaces   the   patterns   DEBCONFsomethingDEBCONF   listed  in
> /etc/exim4/exim4.conf.template.  It does not change the other  contents
> of these files.  This makes it very simple to make small changes to the
> configuration and still have the benefits of debconf.
> 
> Proposed
> If dc_use_split_config in /etc/exim4/update-exim4.conf.conf specifies a
> split configuration [still don't say exactly how, but make clear this is
> the split config case, which was only implicit before],
> update-exim4.conf  processes the /etc/exim4/conf.d
> subdirectories  in the order main,  acl,  router,  transport,  retry,
> rewrite  and  auth. Within each directory it takes files in lexical sort
> order by file name.  It concatenates all these files, making the Debconf
> replacement described below.
> 
> If you do not have a split configuration, update-exim4.conf uses
> only /etc/exim4/exim4.conf.template.
> 
> In either case, before outputing the result
> to /var/lib/exim4/config.autogenerated, update-exim4.conf replaces  the
> patterns  DEBCONFsomethingDEBCONF with the contents of dc_something
> from /etc/exim4/update-exim4.conf.conf.  It makes no other changes.
> This makes it very simple to make small changes to the configuration and
> still have the benefits of debconf.

If we go to documentation _that_ detailed (this text is almost more
exact than the actual code), we also need to say something about
foo.rul taking precendence over foo. Andreas, since you made that
change, can you please...

> Although I know it would require more work, you might consider
> discussing the split and unsplit configurations separately in
> README.Debian (and perhaps some of the man pages).  I think that
> would make it easier to follow.

It would, however, duplicate a lot of the explanations, making it
harder to keep them in sync.

> Finally, the comment in exim4.conf.template could be clearer.  It now reads
> ######################################################################
> # Depending on where you find this file, this might be a template or
> # an actual configuration file. Documentation about the Debian exim4
> # configuration scheme can be found in
> # /usr/share/doc/exim4-base/README.Debian.gz.
> #
> # Strings like DEBCONFsomethingDEBCONF are replaced by installation
> # dependent values by update-exim4.conf, the script which builds the
> # actual configuration from the templates.
> 
> I'm still not sure what the template/actual configuration file distinction means.

It means that people kept copying /etc/exim4.conf.template to
/etc/exim.conf without reading and/or thinking and swiftly proceeded
to yell at us for shipping a syntactically invalid configuration template.

> It would be simpler to say
> ######################################################################
> # This file is only used in the non-split configuration case.
> # Documentation about the Debian exim4
> # configuration scheme can be found in
> # /usr/share/doc/exim4-base/README.Debian.gz.

This is how it was originally. People were too stupid for that.

> The second paragraph on debconf might add some of the details about where the
> substitution values come from, as I did further up.  Or it could just refer
> to other docs.
> 
> I think part of the problem is that this file is generated from another during
> build, because the same comment also appears  01_exim4-config_listmacrosdefs.
> It's also confusing there.  If it is too much trouble to produce separate comments
> for each, the comment could just say
> ######################################################################
> # /etc/exim4/exim4.conf.template is only used in the non-split configuration case.
> # /etc/exim4/conf.d/main/01_exim4-config_listmacrosdefs is only used for split
> # configurations.
> # Documentation about the Debian exim4
> # configuration scheme can be found in
> # /usr/share/doc/exim4-base/README.Debian.gz.

Good, taken.

Greetings
Marc

-- 
-----------------------------------------------------------------------------
Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things."    Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 621 72739835