Ticket #190 (closed enhancement: fixed)

Opened 11 years ago

Last modified 10 years ago

Add command-line options to the Perl scripts

Reported by: rjl Owned by: rjl
Priority: low Milestone: 1.0.1
Component: Perl scripts Version: 1.0.0 RC5
Severity: minor Keywords: process-quarantine.pl expire-quarantine-cache.pl command-line


Some of the configurable behaviour of the various Perl scripts (e.g. process-quarantine.pl, expire-quarantine-cache.pl, etc.) is hard-coded at the beginnings of the scripts themselves, or read from database columns. For maximum utility however, it would be convenient to also let some of these things be set via command-line options.

If set on the command-line, such options would override any hard-coded defaults or database-sourced values, so for routine purposes (e.g. cron jobs) the scripts would be best run without any arguments, but for one-off administration purposes--like, say, purging X days worth of confirmed-but-unreported spam--command-line arguments would be highly convenient.

The expire-quarantine-cache.pl script, in particular, might be amended to allow the administrator to specify the types of mail items that should be expired--suspected ham/spam, confirmed ham/spam, viruses, banned files, bad header items, etc. (Currently, confirmed ham/spam items are not expired by this script at all--only process-quarantine.pl does this.)

Change History

Changed 11 years ago by rjl

Fixed for process-quarantine.pl in [619]. Similar changes still need to be made to expire-quarantine-cache.pl.

Changed 10 years ago by dmorton

  • milestone 1.0.0 deleted

Changed 10 years ago by rjl

  • status changed from new to assigned
  • milestone set to 1.0.1

Changed 10 years ago by rjl

  • status changed from assigned to closed
  • type changed from defect to enhancement
  • resolution set to fixed

Added command-line options for expire-quarantine-cache.pl in [995] and [996], to make it more flexible as an expiry tool. In addition to being able to control which types of items get expired, the script now supports the expiry of confirmed spam [C] and confirmed non-spam [G] items if desired (e.g. if process-quarantine.pl has not been run for a long time, and it becomes desirable to simply delete user-confirmed items). It shouldn't be necessary to do this with the new process-quarantine.pl script, but it's there as an option in any case.

Note: See TracTickets for help on using tickets.