modernizing amavis program directories and config files

Patrick Ben Koetter p at sys4.de
Thu Sep 12 13:31:39 CEST 2019


@all,

I want to adapt amavis' usage of program directories and configuration files
to meet current standards and I'd like to read your comments on my proposal.

The reason to change the current layout is

- it doesn't follow the FHS "Filesystem Hierarchy Standard" as described in
  <http://refspecs.linuxfoundation.org/FHS_3.0/fhs/index.html>
- the mechanism to read configuration isn't packager friendly, i.e. it doesn't
  allow for a standard config, while being open to local changes that won't be
  overwritten on updates
- templates are hard to edit, because they reside in the amavis program and
  are not available as editable files
- there's no default location for DKIM key material

Following the "Filesystem Hierarchy Standard" I've come up with the following
layout, which I've commented at the end of the listing:

----
.
├── etc
│   ├── amavis                                   # <1>
│   │   ├── dkim                                 # <2>
│   │   │   └── selector.example.com.key
│   │   ├── example.conf                         # <3>
│   │   └── templates                            # <4>
│   │       ├── de_DE
│   │       └── en_US                            # <5>
│   │           ├── auto-response.template
│   │           ├── dsn.template
│   │           ├── problem-feedback.template
│   │           ├── release-quarantine.template
│   │           ├── spam-admin.template
│   │           ├── spam-sender.template
│   │           ├── virus-admin.template
│   │           ├── virus-recipient.template
│   │           └── virus-sender.template
│   └── amavis.conf                              # <6>
└── var
    ├── lib
    │   └── amavis                               # <7>
    │       ├── __db.001
    │       ├── __db.002
    │       ├── __db.003
    │       ├── nanny.db
    │       └── snmp.db
    └── spool
        └── amavis                               # <8>
            ├── quarantine                       # <9>
            ├── tmp
            └── var
----

<1> amavis config directory
<2> storage for DKIM key material
<3> *.conf in /etc/amavis will be read and overrides settings from
    /etc/amavis.conf allowing local changes to default config
<4> directory to store templates e.g. notification templates
<5> a subdir named by the locale in which the subsiding templates have been
    written
<6> the default config file shipping with amavis vanilla tarball
<7> "This hierarchy holds state information pertaining to" amavis
<8> The well-known amavis spool dir
<9> Former known as 'virus' renamed to what it is, because it might also hold
    spam, banned files etc.


Regards,

p at rick

-- 
[*] sys4 AG
 
https://sys4.de, +49 (89) 30 90 46 64
Schleißheimer Straße 26/MG,80333 München
 
Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer, Wolfgang Stief
Aufsichtsratsvorsitzender: Florian Kirstein
 


More information about the amavis-devel mailing list