Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
cpanel:email-archiving [2010-11-30 13:36:20]
garrett.plasky Approved
cpanel:email-archiving [2011-07-05 13:45:10]
garrett.plasky Approved
Line 4: Line 4:
 First we'll need to make a copy of the existing cPanel Exim filter so our rules don't get overwritten by cPanel, so get into the shell as root and execute: First we'll need to make a copy of the existing cPanel Exim filter so our rules don't get overwritten by cPanel, so get into the shell as root and execute:
  
-<code console>cp -a /​etc/​cpanel_exim_system_filter /​etc/​cpanel_exim_system_filter_modified</​code>+<sxh shell>cp -a /​etc/​cpanel_exim_system_filter /​etc/​cpanel_exim_system_filter_modified</​sxh>
  
 In this new file, insert the following at the bottom, modifying **domain.com** to the domain of your choosing and the email addresses **(incoming|outgoing)@domain.com** appropriately as well: In this new file, insert the following at the bottom, modifying **domain.com** to the domain of your choosing and the email addresses **(incoming|outgoing)@domain.com** appropriately as well:
  
-<code>#​Incoming/​Outgoing Email Archiving+<sxh bash>#​Incoming/​Outgoing Email Archiving
 if ("​$h_to:,​ $h_cc:, $h_bcc"​ contains "​domain.com"​) if ("​$h_to:,​ $h_cc:, $h_bcc"​ contains "​domain.com"​)
 then then
Line 17: Line 17:
 then then
   unseen deliver "​outgoing@domain.com"​   unseen deliver "​outgoing@domain.com"​
-endif</code>+endif</sxh>
  
 Finally, we need to modify the default Exim filter file in the WHM so that this new file is used. Go to //Main >> Service Configuration >> Exim Configuration Editor// and modify the **System Filter File** line; save. Finally, we need to modify the default Exim filter file in the WHM so that this new file is used. Go to //Main >> Service Configuration >> Exim Configuration Editor// and modify the **System Filter File** line; save.