ÔõÑùÔÚCentOS 7ϵͳÉÏ×°ÖÃGitLab
gitlabÊÇÒ»¿î¿ªÔ´µÄ´úÂëÍйÜƽ̨£¬¿ÉÒÔÇáËɵØʵÏÖÍŶÓÐ×÷¿ª·¢¡£ËüÌṩÁËÒ»¸öÖÜÈ«µÄgit¿ÍÕ»ÖÎÀíϵͳ£¬¼¯³ÉÁËÐí¶à²å¼þ£¬Ö§³ÖÖÖÖÖÊ¢ÐеÄÓïÑԺͿò¼Ü¡£±¾ÎĽ«ÏÈÈÝÔõÑùÔÚcentos 7ϵͳÉÏ×°ÖÃgitlab¡£
°ì·¨1£º×°ÖÃÐëÒªµÄÒÀÀµ
ÔÚ×°ÖÃGitLab֮ǰ£¬ÐèҪװÖÃһЩÐëÒªµÄÒÀÀµ¡£·¿ªÖն˴°¿Ú£¬ÔËÐÐÒÔÏÂÏÂÁ
sudo yum update -y sudo yum install curl openssh-server openssh-clients postfix cronie -y
µÇ¼ºó¸´ÖÆ
ÉÏÊöÏÂÁ¸üÐÂϵͳ²¢×°ÖÃÓʼþЧÀÍÆ÷£¨Postfix£©ºÍÍýÏëʹÃü£¨Cronie£©¡£
°ì·¨2£º×°ÖÃGitLab
ÔËÐÐÒÔÏÂÏÂÁîÒÔÌí¼ÓGitLabÈí¼þ°ü²¢×°ÖÃËü£º
curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash sudo yum install gitlab-ce -y
µÇ¼ºó¸´ÖÆ
×°ÖóÌÐò½«×Ô¶¯´ÓGitLab¹Ù·½¿ÍÕ»ÖÐÏÂÔØÈí¼þ°ü£¬²¢½«Æä×°Öõ½ÏµÍ³ÖС£
°ì·¨3£ºÉèÖÃGitLab
Íê³ÉGitLabµÄ×°Öúó£¬ÐèҪƾ֤×Ô¼ºµÄÐèÇó¾ÙÐÐÉèÖá£
±à¼GitLabÉèÖÃÎļþ£º
sudo vi /etc/gitlab/gitlab.rb
µÇ¼ºó¸´ÖÆ
ÔÚ¸ÃÎļþÖУ¬Äú¿ÉÒÔ¸ü¸ÄGitLabµÄÉèÖÃÑ¡ÏÀýÈç¶Ë¿ÚºÅºÍHTTPSÐÒéµÈ¡£ÆäÖÐһЩ³£ÓÃÑ¡ÏîÈçÏ£º
external_url 'http://yourdomain.com' # ¸ü¸ÄGitLabµÄURLµØµã gitlab_rails['smtp_enable'] = true # ÆôÓÃÓʼþ½»¸¶ gitlab_rails['smtp_address'] = "smtp.gmail.com" # Ö¸¶¨ÓʼþЧÀÍÆ÷ gitlab_rails['smtp_port'] = 587 # Ö¸¶¨ÓʼþЧÀÍ¶Ë¿Ú gitlab_rails['smtp_user_name'] = "youremail@gmail.com" # Ö¸¶¨·¢¼þÈËÓÊÏä gitlab_rails['smtp_password'] = "password" # Ö¸¶¨·¢¼þÈËÓÊÏäÃÜÂë
µÇ¼ºó¸´ÖÆ
¸ü¸ÄÉèÖÃÑ¡ÏîÖ®ºó£¬ÐèÒªÖØмÓÔØÉèÖÃÎļþ£º
sudo gitlab-ctl reconfigure
µÇ¼ºó¸´ÖÆ
°ì·¨4£ºÆô¶¯GitLab
Íê³ÉÉèÖú󣬿ÉÒÔÆô¶¯GitLabЧÀÍ£º
sudo gitlab-ctl start
µÇ¼ºó¸´ÖÆ
GitLab½«ÔÚĬÈ϶˿Ú80ÉÏÔËÐУ¬¿ÉÒÔÔÚWebä¯ÀÀÆ÷Öлá¼ûÄúµÄGitLabʵÀýµÄIPµØµãºÍ¶Ë¿ÚºÅ¡£ÔÚµÚÒ»´Î»á¼ûʱ£¬ÄúÐèÒªÉèÖÃÖÎÀíÔ±ÕË»§ºÍÃÜÂë¡£
°ì·¨5£º»á¼ûGitLab
Íê³ÉÒÔÉÏ°ì·¨ºó£¬Äú¿ÉÒÔÔÚWebä¯ÀÀÆ÷Öлá¼ûGitLabʵÀýµÄURLµØµã¡£ÈôÊÇÉèÖÃÁËÍⲿURLÑ¡ÏÔòÓ¦¸ÃÔÚ¸ÃURLµØµãÏ»á¼ûGitLab¡£
ÔÚÄúµÄWebä¯ÀÀÆ÷ÖÐÊäÈëGitLabµÄURLµØµã£¬²¢Æ¾Ö¤Ò³ÃæÉϵÄָʾÉèÖÃÖÎÀíÔ±ÕË»§ºÍÃÜÂë¡£Ò»µ©ÉèÖÃÍê³É£¬¾Í¿ÉÒÔÔÚGitLabÉϽ¨ÉèÏîÄ¿¡¢Ìí¼ÓÓû§¡¢ÖÎÀíȨÏ޵ȡ£
×ܽá
±¾ÎÄÏÈÈÝÁËÔõÑùÔÚCentOS 7ϵͳÉÏ×°ÖÃGitLabÒÔ¼°ÉèÖÃÑ¡Ïî¡£GitLabÊÇÒ»¿î¿ªÔ´µÄ´úÂëÍйÜƽ̨£¬ÊÇÍŶÓÐ×÷¿ª·¢µÄÀíÏëÑ¡Ôñ¡£½Ó´ýʵÑ飡
ÒÔÉϾÍÊÇÔõÑùÔÚCentOS 7ϵͳÉÏ×°ÖÃGitLabµÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡