> The idea behind the lmail template subsystem which currently has been in 
> place for well over 3 years, is that in a future release of lmail it will be 
> possible to specify within the configuration file, exactly which mail 
> templates you would like to use on a per backup configuration basis. It is 
> important to work towards an easily editable the template script sub-system 
> as I outlined above. However, this is not going to make it into the upcoming 
> 0.9.8r2 release.

An experimental implementation of the per configuration mail tempting system 
described above is part of the recently released LBackup 0.9.8r3-alpha5.

I will now outline how to enable custom mail templates.

First add the following line into your lmail configuration file :


If lmail detects this line within your lmail configuration, then it will search 
within the LBackup configuration directory for a directory (or a symbolic link 
to a directory) called "message_templates". If this directory exists, then 
lmail will also check for the following template scripts :

  - mail_error.sh
  - mail_logerror_attachment.sh
  - mail_standard.sh
  - mail_standard_attachment.sh

If any of these components are not found, then the built in (default) mail 
templates will be used to generate an email reports. However, if all of these 
files located, then these custom mail templates will be used to generate the 
email reports.

As such, a good way to get started with customizing your email templates is to 
copy the built in LBackup mail templates : 
"/usr/local/libexec/lbackup/message_templates" into your LBackup configuration 
directory. Then you may edit the the copy you just made within your LBackup 
configuration directory. 

When you run lmail you should see a message which states that Custom mail 
templates are enabled.

If you have any suggestions on how to improve the custom email template system 
in this alpha release then reply to this message. Likewise, if you start using 
this system and find that it is not offering you the flexibility you require 
but are not sure how to improve the system then still let me know.

Keep in mind that this initial implementation is highly experimental. The way 
this works may radically change within a future release of LBackup. As such, if 
you enable custom mail templates then be aware that you will be compromising on 
the reliability of email reporting. This is particularly true if you upgrade to 
a newer version of LBackup in the future. You may find that your custom mail 
scripts stop working or not even be accessed. 

Feed back regarding this current approach will be elemental in deciding if this 
is the way LBackup custom reporting moves forward.

Thank you for all your support this year and all the best for 2010.

lbackup-discussion mailing list

Reply via email to