[16] | 1 | = Installation and Configuration of email2trac = |
---|
| 2 | |
---|
[5] | 3 | The email2trac package contains the following utilities: |
---|
[19] | 4 | email2trac.py : converts an email to ticket. Reads a config file |
---|
| 5 | email2trac.conf |
---|
| 6 | run_email2trac.c: suid program that changes the MTA-user to the TRAC-user so |
---|
| 7 | that we can save attachments |
---|
| 8 | delete_spam.py : small program that deletes the SPAM tickets from the database |
---|
| 9 | email2trac.conf : read by email2trac.py to set the various options. This are |
---|
| 10 | the options: |
---|
[16] | 11 | {{{ |
---|
[19] | 12 | [DEFAULT] # REQUIRED |
---|
| 13 | project: /data/trac/jouvin # REQUIRED |
---|
| 14 | debug: 1 # OPTIONAL, if set print some DEBUG info |
---|
| 15 | spam_level: 4 # OPTIONAL, if set check for SPAM mail |
---|
[47] | 16 | reply_address: 1 # OBSOLETE, see trac.ini notification section |
---|
| 17 | reply_all: 1 # OPTIONAL, if set then put all CC-addresses in ticket CC-field |
---|
[19] | 18 | umask: 022 # OPTIONAL, Use this umask for saving attachments |
---|
| 19 | mailto_link: 1 # OPTIONAL, if set then [mailto:<CC>] in description |
---|
| 20 | email_header: 1 # OPTIONAL, if set then show TO/CC fields in description |
---|
| 21 | trac_version: 0.8 # OPTIONAL, if set use this as trac version (D: 0.9) |
---|
| 22 | |
---|
[20] | 23 | [bas] # OPTIONAL project declaration, also set |
---|
| 24 | # project option, use -p|--project |
---|
| 25 | project: /data/trac/bas # |
---|
[19] | 26 | spam_level: 2 # Override DEFAULT spam_level, can also be |
---|
| 27 | # done for other options |
---|
[16] | 28 | }}} |
---|
[5] | 29 | |
---|
[16] | 30 | == Installation and Configuration == |
---|
[5] | 31 | |
---|
[16] | 32 | First build, install email2trac : |
---|
[5] | 33 | |
---|
[51] | 34 | option 1: |
---|
| 35 | * ./configure (see --help) |
---|
[24] | 36 | {{{ |
---|
| 37 | default values for: |
---|
| 38 | prefix=/usr/local --> --prefix=<path> |
---|
| 39 | exec_prefix=$prefix/bin --> --exec_prefix=<path> |
---|
| 40 | sysconfdir=$prefix/etc --> --sysconfdir=<path> |
---|
| 41 | MTA_USER=nobody --> --with-mta_user=<name> |
---|
| 42 | TRAC_USER=www-data --> --with-trac_user=<name> |
---|
| 43 | }}} |
---|
[16] | 44 | * make |
---|
| 45 | * make install |
---|
[24] | 46 | * First install copy emailtrac.conf to $sysconfdir |
---|
[5] | 47 | |
---|
[51] | 48 | option 2: |
---|
| 49 | * debian/rules binary |
---|
| 50 | * First install copy emailtrac.conf to /etc |
---|
[9] | 51 | |
---|
[51] | 52 | After installation, edit email2trac.conf for your site. Most important |
---|
| 53 | parameter is project, see above |
---|
| 54 | |
---|
[16] | 55 | == Usage == |
---|
| 56 | |
---|
[19] | 57 | It depends on your MTA how the setup is. For Sendmail and Postfix, the p |
---|
| 58 | rocedure is the same : |
---|
| 59 | * Edit your alias definition file (default : /etc/aliases for Postfix, |
---|
| 60 | /etc/mail/aliases for Sendmail) and add one line per project/component you |
---|
| 61 | want to allow ticket submission from email to. For each alias, you can |
---|
| 62 | specify option --project. This option selects a configuration stanza in the |
---|
| 63 | config file and ''--component'' to specify a component other than the |
---|
| 64 | default component for the project. Line must have the following format : |
---|
[16] | 65 | {{{ |
---|
| 66 | tracproj: |/usr/sbin/run_email2trac [--project=<project_name>] [--component=<project_component>] |
---|
| 67 | }}} |
---|
| 68 | |
---|
| 69 | * Update your alias database with command ''newaliases'' |
---|
[19] | 70 | * Test with a command like : |
---|
[16] | 71 | {{{ |
---|
[56] | 72 | mail tracproj |
---|
[16] | 73 | }}} |
---|