在Debian上部署GitLab的步骤如下:
sudo apt update && sudo apt upgrade -y
sudo apt install -y curl openssh-server ca-certificates tzdata perl
sudo systemctl enable ssh
sudo systemctl start ssh
curl https://packages.gitlab.com/gpg.key | sudo apt-key add -
sudo sh -c 'echo "deb https://packages.gitlab.com/gitlab/gitlab-ce/debian buster main" > /etc/apt/sources.list.d/gitlab.list'
sudo apt update
sudo EXTERNAL_URL="http://your-gitlab-domain.com" apt install gitlab-ce
/etc/gitlab/gitlab.rb
文件中的external_url
设置正确。external_url 'http://your-gitlab-domain.com'
sudo gitlab-ctl reconfigure
sudo gitlab-ctl restart
http://your-gitlab-domain.com
。root
和密码(在安装过程中设置)登录。sudo ufw allow 80/tcp
sudo ufw allow 443/tcp
sudo ufw allow 22/tcp
sudo ufw enable
sudo gitlab-rake gitlab:backup:create
/var/log/gitlab
目录下。以上步骤应该可以帮助你在Debian上成功部署GitLab。如果在过程中遇到问题,请参考GitLab官方文档或寻求社区支持。