Home‎ > ‎unix/linux‎ > ‎Centos Systems‎ > ‎

RT



Get the box setup

Remove selinux (at least for now)
vim /etc/sysconfig/selinux
   SELINUX=disabled

install latests epel rpm
rpm -Uvh http://linux.mirrors.es.net/fedora-epel/6/i386/epel-release-6-7.noarch.rpm

install goodies
yum install mysql-server mysql phpmyadmin httpd httpd-devel mod_ssl mod_fcgid gcc make perl-CPAN

setup and start mysql
/etc/init.d/mysqld start
chkconfig mysqld on
/usr/bin/mysql_secure_installation
/etc/init.d/mysqld restart

configure apache by allowing access
vim /etc/httpd/conf.d/phpMyAdmin.conf
    <Directory /usr/share/phpMyAdmin/>
      <IfModule mod_authz_core.c>
        # Apache 2.4    
        <RequireAny>
          Require ip 127.0.0.1
          Require ip ::1
        </RequireAny>
      </IfModule>
      <IfModule !mod_authz_core.c>
        # Apache 2.2
        Order Deny,Allow
        Deny from All
        Allow from 127.0.0.1
        Allow from 10
        Allow from ::1
      </IfModule>
    </Directory>


Then start up apache
/etc/init.d/httpd start
chkconfig httpd on

and add rules to your IPTables: 
vim /etc/sysconfig/iptables
    *filter
    :INPUT ACCEPT [0:0]
    :FORWARD ACCEPT [0:0]
    :OUTPUT ACCEPT [0:0]
    -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
    -A INPUT -p icmp -j ACCEPT
    -A INPUT -i lo -j ACCEPT
    -A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
    -A INPUT -m state --state NEW -m tcp -p tcp --dport 443 -j ACCEPT
    -A INPUT -j REJECT --reject-with icmp-host-prohibited
    -A FORWARD -j REJECT --reject-with icmp-host-prohibited
    COMMIT

/etc/init.d/iptables restart

For Apache, create an empty start page
touch /var/www/html/index.html
/etc/init.d/httpd restart


Then go to the webpage, and test phpmyadamin
https://<server>/phpmyadmin/

Install RT: 

see the latest versions here: http://bestpractical.com/rt/download_file.html
wget http://download.bestpractical.com/pub/rt/release/rt-4.0.8.tar.gz
tar zxvf rt-4.0.8.tar.gz
mv rt-4.0.8 /opt/.

Setup the rt user: 
groupadd rt
useradd -g rt rt

Build RT
cd /opt/rt-4.0.8
./configure --with-db-type=mysql --with-db-host=localhost --with-web-user=apache --with-web-group=apache --with-rt-group=rt --prefix=/usr/local/rt --enable-graphviz --enable-gd --enable-gpg


Install all the apps needed for RT: 
yum install – - enablerepo=rpmforge rpm* nmap expect vsftpd net-snmp* ntp* subversion subversion-devel mysql mysql-server mysql-devel screen perl-Crypt- PasswdMD5 graphviz php-xml php-cli php-mhash php-ldap php-devel php-pdo php-imap php-readline php-ncurses php-soap php-snmp php-common php-mcrypt php-odbc php-mbstring php-gd php-bcmath php php-xmlrpc php-pear php-mysql php-dba mod_perl-devel mod_auth_mysql mod_perl mod_authz_ldap gd gd-devel gd-progs gcc* - – exclude=gcc-java* – - exclude=gcc4-java phpmyadmin mod_fcgid perl-GD perl-GnuPG-Interface perl-GraphViz perl-YAML

Get Perl working

Make sure that you have all the perl dependencies.  (yea, I realize this is a nuts amount of stuff)
yum install perl*
yum install --enablerepo=rpmforge cpan

Set cpan to auto-follow dependencies
perl -MCPAN -e shell
    o conf prerequisites_policy follow
    o conf commit
    install Bundle::CPAN
    reload cpan
    reload index
    exit


Final Apache/RT setup: 

Create rt.conf file for apache
vim /etc/httpd/conf.d/rt.conf
    AddDefaultCharset UTF-8

    Alias /rt/NoAuth/images /usr/local/rt/share/html/NoAuth/images/
    ScriptAlias /rt /usr/local/rt/sbin/rt-server.fcgi/

    DocumentRoot "/usr/local/rt/share/html"
    <Location /rt>
    #       SSLRequireSSL
        Order allow,deny
        Allow from all

        Options +ExecCGI
        AddHandler fcgid-script fcgi
    </Location>






References: 

Comments