在Debian上使用Docker容器化部署GitLab的步骤如下:
wget https://mirrors.aliyun.com/docker-ce/linux/static/stable/x86_64/docker-24.0.4.tgz
tar -xf docker-24.0.4.tgz
cp docker/* /usr/bin/
vi /etc/systemd/system/docker.service
systemctl daemon-reload
systemctl start docker
systemctl enable docker
wget https://github.com/docker/compose/releases/download/1.29.2/docker-compose-linux-x86_64
mv docker-compose-linux-x86_64 /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker pull registry.cn-hangzhou.aliyuncs.com/lab99/gitlab-ce-zh:latest
docker-compose.yml
文件:version: '3.1'
services:
gitlab:
image: registry.cn-hangzhou.aliyuncs.com/lab99/gitlab-ce-zh:latest
container_name: gitlab
restart: always
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url 'http://192.168.88.11:8929'
gitlab_rails['gitlab_shell_ssh_port'] = 8013
docker-compose up -d
http://192.168.88.11:8929
,按照提示设置root密码即可登录GitLab。请注意,以上步骤是基于搜索结果的概述,具体操作可能会因网络环境和具体需求有所不同。建议在部署前详细阅读GitLab和Docker的官方文档,并确保所有步骤都正确无误地执行。
辰迅云「云服务器」,即开即用、新一代英特尔至强铂金CPU、三副本存储NVMe SSD云盘,价格低至29元/月。点击查看>>
推荐阅读: Debian Extract如何防止攻击