GitLab
Abstract
インストール忘備録
Install to Ubuntu
GitLab for Ubuntu
https://about.gitlab.com/install/#ubuntu
以下公式手順だとUbuntuバージョンによりパッケージが認識されずインストールできない (e.g., Jammy)
sudo apt install curl curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ee/script.deb.sh | sudo bash sudo apt install gitlab-ee
以下手順で直接ダウンロードしたパッケージならインストールは可能だがうまくやらないとポートが競合する (e.g., 22, 80, 443)
wget --content-disposition https://packages.gitlab.com/gitlab/gitlab-ee/packages/ubuntu/bionic/gitlab-ee_15.2.0-ee.0_amd64.deb/download.deb sudo apt install ./gitlab-ee_15.2.0-ee.0_amd64.deb sudo vi /etc/gitlab/gitlab.rb ====================================== external_url 'http://192.168.123.123:80' ====================================== sudo gitlab-ctl reconfigure sudo gitlab-ctl status sudo gitlab-ctl restart
結果として直接インストールは専用サーバでない限りあまり芳しくない
Docker on Ubuntu (TBW)
GitLab Docker Images
https://docs.gitlab.com/ee/install/docker.html
未使用ポート確認と環境設定
lsof -i:9922,9980,9443 export GITLAB_HOME=/srv/gitlab
sudo docker run --detach \ --hostname 192.168.123.123 \ --publish 9443:443 --publish 9980:80 --publish 9922:22 \ --name gitlab \ --restart always \ --volume $GITLAB_HOME/config:/etc/gitlab \ --volume $GITLAB_HOME/logs:/var/log/gitlab \ --volume $GITLAB_HOME/data:/var/opt/gitlab \ --shm-size 256m \ gitlab/gitlab-ee:latest
sudo vi /srv/gitlab/config/gitlab.rb ====================================== external_url 'http://192.168.123.123:9980' gitlab_rails['gitlab_shell_ssh_port'] = 9922 ====================================== sudo docker exec gitlab gitlab-ctl reconfigure sudo docker exec gitlab gitlab-ctl restart #docker restart gitlab
起動完了まで数分待機、なかなかのメモリを消費するので注意
sudo docker ps -a ## STATUS = (health: starting) > (healthy)
Connect to GitLab
http://192.168.123.123:9980/
References
GitLab
https://about.gitlab.com/
Acknowledgments
Daiphys is a professional-service company for research and development of leading-edge technologies in science and engineering.
Get started accelerating your business through our deep expertise in R&D with AI, quantum computing, and space development; please get in touch with Daiphys today!
Daiphys Technologies LLC - https://www.daiphys.com/