Thursday, December 27, 2012

Installation Guideline for GIT Server on linux




Installation Guideline for GIT Server
1.       Yum install git git-daemon (If git is not available through yum kindly install rpmforge repo from http://pkgs.repoforge.org/rpmforge-release/rpmforge-release.*.rpm)
2.       mkdir <git directory>
3.       cd <git directory>
4.       git init

Configuration of Apache with Git
<VirtualHost *:80>
        ServerName git.confiz.com
        DocumentRoot /git
        <Directory /git/>
                DAV On
                Options ExecCGI FollowSymLinks Indexes
                # Deny everyything here
                Deny from all
                AuthType Basic
                AuthName "git repository"
                AuthUserFile /etc/httpd/htpasswd.git
        </Directory>

        <Directory /git/<clinetname>/<projectrepo>
                Allow from all
                Order allow,deny
                <Limit GET PUT POST DELETE PROPPATCH MKCOL COPY MOVE LOCK UNLOCK>
                        Require user <allowed user>
                </Limit>
        </Directory>
</VirtualHost>

Adding htpasswd file and its user

Creating file + adding user > htpasswd -c  /etc/httpd/git/htpasswd.git <username>
                                                   Note: you will be prompted for password

Adding user to existing file > htpasswd /etc/httpd/git/htpasswd.git <username>
                                                    Note: you will be prompted for password


Adding a new repo

1.       mkdir <client folder>/<project repo>  –p
2.       cd <client folder>/<project repo>/
3.       git --bare init
4.       chown apache.apache -R /git/<client folder>/<project repo>
5.       sudo -u apache git update-server-info
6.       Add proper entry in  > vi /etc/httpd/conf.d/git.conf
7.       Create username for access > htpasswd /etc/httpd/htpasswd.git <username>
8.        service httpd reload

how to install ruby enterprise on linux,centos




Installation of Ruby enterprise:

cd /tmp
wget https://packages.endpoint.com/endpoint-rpmsign.pub
rpm --import endpoint-rpmsign.pub
:
cd /tmp
64-bit  >> wget https://packages.endpoint.com/rhel/5/os/x86_64/endpoint-repo-1.0-1.x86_64.rpm
32-bit  >> wget https://packages.endpoint.com/rhel/5/os/i386/endpoint-repo-1.0-1.i386.rpm
yum localinstall endpoint-repo-1.0-1.x86_64.rpm
On RHEL:
yum --disableplugin=rhnplugin clean all
On CentOS:
yum clean all

yum install ruby-enterprise ruby-enterprise-rubygems

Passenger installation
yum install httpd-devel
gem install passenger
passenger-install-apache2-module
insert  respective module information given by passenger setup into /etc/httpd/conf.d/passenger.conf