ÔõÑùÔÚUbuntu²Ù×÷ϵͳÉÏ×°ÖÃGitLabµÄ×îа汾
gitlabÊÇÒ»¸ö»ùÓÚgitµÄ°æ±¾¿ØÖÆϵͳ¡£Ëü¾ßÓи»ºñµÄ¹¦Ð§£¬Ê¹¿ª·¢Ö°Ô±Äܹ»Ô½·¢¸ßЧµØÖÎÀíºÍÐ×÷¿ª·¢¡£×îа汾µÄgitlabÊÇ8.17.2°æ±¾¡£±¾ÎĽ«ÏÈÈÝÔõÑùÔÚubuntu²Ù×÷ϵͳÉÏ×°ÖÃgitlabµÄ×îа汾¡£
°ì·¨Ò»£º×°ÖÃÒÀÀµÏî
ÔÚ×°ÖÃGitLab֮ǰ£¬ÐèҪȷ±£ÒÑ×°ÖÃÒÔÏÂÒÀÀµÏ
CURL
sudo apt-get install curl
Openssl
sudo apt-get install openssl
Postgresql
sudo apt-get install postgresql postgresql-contrib
×°ÖÃÍê±Ïºó£¬ÐèҪΪPostgreSQL½¨ÉèÒ»¸öеÄÊý¾Ý¿âÓû§¡£Äú¿ÉÒÔ·¿ªPostgreSQL shell²¢¼üÈëÒÔÏÂÏÂÁîÀ´½¨ÉèÓû§£º
sudo -u postgres psql
CREATE USER git CREATEDB;
SET PASSWORD FOR git = ‘yourpassword’;
°ì·¨¶þ£º×°ÖÃGitLab
×°ÖÃGitLabµÄ×îа汾ÐèҪʹÓùٷ½ÌṩµÄ×°Öþ籾¡£Äú¿ÉÒÔʹÓÃÒÔÏÂÏÂÁîÀ´ÏÂÔؾ籾£º
sudo curl -sS https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.deb.sh | sudo bash
ÐèÒªÆÚ´ýÏÂÔØÍê³Éºó¾Í¿ÉÒÔÖ´ÐÐÏÂÒ»¸öÏÂÁî¾ÙÐÐGitLab×°Öãº
sudo apt-get install gitlab-ce
°ì·¨Èý£ºÉèÖÃGitLab
×°ÖÃÍê³Éºó£¬ÐèÒªÉèÖÃGitLab¡£Ê×ÏÈ£¬Ê¹ÓÃÎı¾±à¼Æ÷£¨Èçnano»òvim£©·¿ª¡°/etc/gitlab/gitlab.rb¡±Îļþ£º
sudo nano /etc/gitlab/gitlab.rb
ÔÚÎļþÖÐËÑË÷¡°postgresql¡±ºÍ¡°external_url ¡±£¬²¢¸ü¸ÄÒÔÏÂÄÚÈÝ£º
postgresql[‘enable’] = true
gitlab_rails[‘db_username’] = “git”
gitlab_rails[‘db_password’] = “yourpassword”
gitlab_rails[‘db_host’] = ‘localhost’
gitlab_rails[‘db_port’] = ‘5432’
external_url ‘http://yourdomain.com’
Íê³Éºó£¬ÉúÑIJ¢¹Ø±ÕÎļþ¡£
°ì·¨ËÄ£ºÖØÐÂÉèÖÃGitLab²¢Æô¶¯Ð§ÀÍ
ÖØÐÂÉèÖÃGitLab£º
sudo gitlab-ctl reconfigure
Æô¶¯GitLabЧÀÍ£º
sudo gitlab-ctl start
µ½´ËΪֹ£¬ÄúÒѾÀֳɵØ×°ÖÃÁËGitLabµÄ×îа汾¡£Äú¿ÉÒÔͨ¹ýä¯ÀÀÆ÷»á¼û http://yourdomain.com À´ÑéÖ¤ËüÊÇ·ñÕý³£ÊÂÇé¡£
×ܽá
±¾ÎÄÏÈÈÝÁËÔõÑùÔÚUbuntu²Ù×÷ϵͳÉÏ×°ÖÃGitLabµÄ×îа汾¡£ËäÈ»×°ÖÿÉÄÜ»áÓöµ½Ò»Ð©ÎÊÌ⣬µ«×¼È·µÄ×°ÖúÍÉèÖý«Ê¹GitLabʵÏÖÓÐÓõİ汾¿ØÖƺÍÐ×÷¿ª·¢¡£Ï£ÍûÕâƪÎÄÕ¶ÔÄúµÄѧϰºÍʹÓÃÓÐËù×ÊÖú¡£
ÒÔÉϾÍÊÇÔõÑùÔÚUbuntu²Ù×÷ϵͳÉÏ×°ÖÃGitLabµÄ×îа汾µÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡