Build git and Gitlab repositories under CENTOS7

Source: Internet
Author: User

    • System: CENTOS7

Installation dependencies:

Yum Install Perl
    • git installation

To download the GIT installation package:

wget https://www.kernel.org/pub/software/scm/git/git-2.9.0.tar.gz

Unzip the installation:

tar -zxvf git-2.9. 0. Tar . GZCD git-2.9. 0  make prefix=/usr/local all

The following exception occurred at compile time:

LIBGIT.A (UTF8.O): Infunction' Reencode_string_iconv':/root/git-2.9.0/UTF8.C:463: Undefined reference to ' Libiconv'LIBGIT.A (UTF8.O): Infunction' Reencode_string_len':/root/git-2.9.0/UTF8.C:502: Undefined reference to ' Libiconv_open'/root/git-2.9.0/UTF8.C:521: Undefined reference to ' Libiconv_close'/root/git-2.9.0/UTF8.C:515: Undefined reference to ' Libiconv_open'Collect2:LDReturn1 Make: * * * [Git-credential-store] Error1

Download and install Libiconv

CD.. wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.14.tar.gztar -zxvf libiconv-1.14. Tar . GZCD Libiconv-1.14. /configure--prefix=/usr/local/libiconv  && make do    Install 

Back to Git in this compilation installation

Cd.. /git-2.9. 0  Make Clean . /configure--prefix=/usr/local--with-iconv=/usr/local/libiconv/makeinstall

To see if the installation is correct and installed:

# git--2.9. 0

This indicates that GIT has successfully installed

    • Installing Gitlab
Update source, reference: https://mirror.tuna.tsinghua.edu.cn/help/gitlab-ce/

vi /etc/yum. Repos.d/gitlab-ce.repo

Add the following content

[gitlab-ce]name=gitlab-cebaseurl=http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/ Yum/el6repo_gpgcheck=0gpgcheck=0Enabled=1Gpgkey= HTTPS://Packages.gitlab.com/gpg.key

Perform

sudo Yum Makecache sudo Yum Install Gitlab-ce

After successful installation, modify the configuration file, modify the access URL, etc.

Edit the/etc/gitlab/gitlab.rb and modify it to your IP and URL as:

" http//your ip/gitlab. "

Run after modification

sudo gitlab-ctl reconfiguresudo gitlab-ctl restart

Reference: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/settings/configuration.md

finally pass: HTTP//your ip/gitlab to see if it works. The root user password needs to be reset at the first run.

For more information see: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/README.md

Build git and Gitlab repositories under CENTOS7

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.