# --
# INSTALL description of OTRS
# Copyright (C) 2001-2002 Martin Edenhofer <martin+code@otrs.org>
# --
# $Id: INSTALL,v 1.19 2002/10/24 23:58:08 martin Exp $
# --
# This software comes with ABSOLUTELY NO WARRANTY. For details, see 
# the enclosed file COPYING for license information (GPL). If you 
# did not receive this file, see http://www.gnu.org/licenses/gpl.txt.
# --

Software requirements?
======================

  On all Perl-Platforms! You need:
    * min. Perl5
    * Database (e. g. MySQL, PostgreSQL)
    * Webpserver (mod_perl isn't required but "very nice" to have)
    * some CPAN-Module (CGI, MIME::Words, Mail::Internet, MIME::Parser, DBI,
      DBD::mysql, Digest::MD5) and for stats (GD, GD::Text, GD::Graph, 
      GD::Graph::lines, GD::Text::Align, Date::Calc)

Installation:
=============

This few steps describe an OTRS installation incl. webserver and database 
settings. The OTRS user is "otrs" and the home (root) directory is /opt/OpenTRS
(of cause you can choose an other directory or/and OTRS user). 

1. Install CPAN Modules (if needed):
   ---------------------------------
   a) Install the RPMs if your distributions provides RPMs for
      the CPAN modules. 

   b) Install the modules via CPAN (http://www.cpan.org/)
      perl -MCPAN -e shell;
      ...
      install MIME::Words
      install MIME::Parser
      install Digest::MD5
      ...

      and maybe the GD stuff (stats support, not required!)
      ...
      install GD
      install GD::Text
      install GD::Graph
      install GD::Graph::lines
      install GD::Text::Align
      install Date::Calc
      ...

   Check if all needed modules are installed:
   ------------------------------------------
      $shell:~> perl -cw /opt/OpenTRS/bin/cgi-bin/index.pl 
      /opt/OpenTRS/bin/cgi-bin/index.pl syntax OK
      $shell:~> perl -cw /opt/OpenTRS/bin/PostMaster.pl 
      /opt/OpenTRS/bin/PostMaster.pl syntax OK
      $shell:~>

    If you get "syntax OK" it seems to be Ok. Go ahead.

2. Create user: 
   ------------
    Add user:
    ---------
    $shell: useradd -d /opt/OpenTRS/ -c 'OTRS user' otrs

    Add user to webserver group (if the webserver is not running with OTRS user):
    -----------------------------------------------------------------------------
    $shell: usermod -G nogroup otrs

    (SuSE=nogroup, Red Hat=apache)

3. Install tar.gz:
   ---------------
   $shell: cd /opt/
   $shell: tar -xzvf otrs-xxxx-xx-xx.tar-gz
   $shell: chown -R /opt/OpenTRS/* otrs
   
4. Webserver:
   ----------
   [follow README.webserver] 

5. Database setup:
   ---------------
   If you use MySQL, you can use the Web-Installer (http://yourhost/otrs/installer.pl).
   Else follow README.database --> "DB - Setup Example".

6. Config file ($HOME/Kernel/Config.pm):
   -------------------------------------
   If you used the Web-Installer, you can skip this point. If not,
   set some Kernel::Config ($HOME/Kernel/Config.pm) Options (FQDN, SystemID, TicketHook, ...)

7. File Permissions:
   -----------------
   Set the file permissions with 
   "$HOME/bin/SetPermissions.sh <OTRS_HOME> <OTRS_USER> <WEBSERVER_USER> [OTRS_GROUP] [WEB_GROUP]"
   e. g. 
     Webserver with OTRS user: "SetPermissions.sh /opt/OpenTRS otrs otrs" 
     Webserver with wwwrun user (e. g. SuSE): "SetPermissions.sh /opt/OpenTRS otrs wwwrun" 
     Webserver with apache user (e. g. Redhat): "SetPermissions.sh /opt/OpenTRS otrs apache users apache"

8. First Login:
   ------------
   http://yourhost/otrs/index.pl
   User: root@localhost
   PW: root

   --> goto AdminArea and set some config settings (UserAdd, Queues, ...).

   Finished.

9. First Email:
   ------------
   use the procmailrc of the OTRS user --> ~otrs/.procmailrc or e. g. /opt/OpenTRS/.procmailrc

   --> send emails to the otrs user (e. g. otrs@localhost)

   or pipe an email directly into $OTRS_HOME/bin/Postmaster.pl
    (e. g. 'cat /opt/OpenTRS/doc/test-email-1.box | /opt/OpenTRS/bin/PostMaster.pl').

10. Cronjobs for the OTRS user:
    ---------------------------
    There are several OTRS cronjobs in $OTRS_HOME/var/cron/*. Use  
    $OTRS_HOME/bin/Cron.sh {start|stop|restart} to start or stop this cronjobs. 

    >> Note: Install this cronjobs as OTRS user. <<


Remark: For installation questions ask otrs@otrs.org (http://lists.otrs.org/).

Have a lot of fun.

 Martin Edenhofer 

(September 2002 Frankfurt/Germany)

EOF
