October 10, 2008, Friday, 283

Email Settings

From osTicket Wiki

Jump to: navigation, search

Email Settings

osTicket allows you to setup unlimited number of email addresses to handle all your company's mail accounts and email communication. Incoming emails are converted to support tickets allowing you to easily manage, organize and archive all emailed support requests in one place.

Contents

Email Templates

osTicket ships with generic email templates used for auto-responses, alerts, notices and replies. Refer to Email Templates Guide for details on how to customize them.

Routing Incoming Emails

Setting up your system to accept emails varies from system to system and depends on your personal preference. osTicket currently supports piping(aliases) and POP3 mail methods for routing incoming emails. Tickets are routed to the department and assigned a default priority associated with the email. You can also disable auto-responder at email level.

Email Piping

Piping method allows for real-time email handling. Extra setup is required at mail server level to pipe the raw email message to osTicket pipe handler. Both remote and local piping are supported. Email piping must be enabled in admin panel Settings ->preference.

Local Piping

Local piping refers to the case where osTicket is installed on a server also handling your emails. Most shared hosting users fall into this category.

Setting up aliases in cPanel

Add a forwarding rule for each of the email addresses to /path/to/api/pipe.php. For example forward support@domain.com to "|/path/to/api/pipe.php" or "|/usr/bin/php -q /path/to/api/pipe.php" for CPanel 11.

  • Don't forget the quotes.
  • Make pipe.php executable chmod 764 pipe.php
  • Enable email piping in admin panel Settings ->preference

Setting up aliases with qmail

Create/Edit your .qmail-* for the domain you wish to forward and add a forwarding rule to /path/to/api/pipe.php. For example for support@domain.com .qmail-support file should contain |/path/to/api/pipe.php

Setting up aliases for sendmail

Modify your aliases file by adding support: root, |/path/to/api/pipe.php and run newaliases.

Setting up aliases in .procmailrc

    :0 c
    * ^To.*support@domain.com
    |/path/to/api/pipe.php

Remote Piping

Remote piping is useful when osTicket installation and the mail server are on two separate machines. To maintain logic in one place remote piping is done over HTTP post. osTicket ships with 2 scripts to help you accomplish this task; automail.php and automail.pl. Both accomplish the same task by posting to http://www.yourdomain.com/api/pipe.php

Remote host IP must be white listed and valid API pass phrase required.

POP3

POP3 method is best suited for individuals with remote mail account(s) and/or with limited access to mail delivery settings. Each email address added to the system can have one POP3 account associated to it. Once you've entered login info you need to configure cron job for periodic mail fetch.

  • Enable POP3 mail fetch in Admin Panel => Settings => Mail Methods
  • Setup cron job

Auto Cron Job

No external setup required! If enabled, emails are fetched based on staff activity at an interval set for each of the POP3 accounts. A staff member activity can trigger a maximum of one cron call every 3 minutes.

External Cron Job

To set a desired normalized fetch frequency you can setup external cron job and disable auto cron. Add the following entry to cron file normally in /etc/crontab in *nix systems and adjust the time and paths accordingly

*/5 * * * * nobody /path/to/php /path/to/api/cron.php

For windows users in "Scheduled Tasks" add "c:\php\bin\php.exe c:\website\osticket\cron.php"