从零开始Ubuntu24.04上Docker构建自动化部署(四)Docker安装gitlab

你会发现所有gitlab都无法拉取到的情况下,经查找极狐下的gitlab还可以下载,具体如下:

建议保存地址:

https://packages.gitlab.cn/#browse/search=keyword%3Dgitlab

最新版本:

sudo docker pull registry.gitlab.cn/omnibus/gitlab-jh:17.3.3

停止docker 上mygitlab

sudo docker stop mygitlab

删除docker上mygitlab容器

sudo docker rm mygitlab

修改配置需要重启

gitlab-ctl reconfigure

gitlab-ctl restart

运行gitlab

sudo docker run --detach --publish 20443:443 --publish 20080:80 --publish 20022:22 --name=mygitlab --restart=always --volume /home/gitlab/config:/etc/gitlab --volume /home/gitlab/logs:/var/log/gitlab --volume /home/gitlab/data:/var/opt/gitlab --privileged=true registry.gitlab.cn/omnibus/gitlab-jh:17.3.3

浏览器访问:

http://192.168.100.128:20080/

查看密码

cat /etc/gitlab/initial_root_password

初始化密码,修改密码

root@c5d112cc211f:/# cat /etc/gitlab/initial_root_password

WARNING: This value is valid only in the following conditions

1. If provided manually (either via `GITLAB_ROOT_PASSWORD` environment variable or via `gitlab_rails['initial_root_password']` setting in `gitlab.rb`, it was provided before database was seeded for the first time (usually, the first reconfigure run).

2. Password hasn't been changed manually, either via UI or via command line.

If the password shown here doesn't work, you must reset the admin password following https://docs.gitlab.com/ee/security/reset_user_password.html#reset-your-root-password.

Password: +NFD/uQ/IP1uB8idyV2YKq5q9AVLfAJd7jBykWU/zgI=

NOTE: This file will be automatically deleted in the first reconfigure run after 24 hours.

登录系统后,修改密码即可

当‌Docker在拉取镜像时卡在"‌pulling fs layer"阶段,可以通过重启Docker服务来解决。 具体步骤如下:

首先,尝试重启Docker服务。可以通过运行以下命令来重启Docker服务:

systemctl restart docker
相关推荐
sj1163739403几秒前
docker-compose方式启动Kafka Sasl加密认证(无zk)
docker·kafka
Dontla1 小时前
Docker run --add-host参数解析(在容器启动时向/etc/hosts文件中添加自定义的主机名与IP映射)(适用于临时调试或测试)
tcp/ip·docker·容器
西西小飞龙1 小时前
Docker和K8S中pod、services、container的介绍和关系
docker·容器·kubernetes
元气满满的热码式1 小时前
Docker数据卷操作实战
linux·运维·docker·云原生·容器
kngines1 小时前
【实战 ES】实战 Elasticsearch:快速上手与深度实践-1.3.1单节点安装(Docker与手动部署)
大数据·elasticsearch·docker
北京耐用通信2 小时前
航空装配自动化神器Ethercat转profient网关搭配机器人精准控制
运维·机器人·自动化
SuperherRo10 小时前
自动化反编译微信小程序工具-e0e1-wx
微信小程序·自动化·hook·反编译
飞火流星0202713 小时前
docker安装etcd:docker离线安装etcd、docker在线安装etcd、etcd镜像下载、etcd配置详解、etcd常用命令、安装常见问题总结
docker·容器·etcd
you来有去14 小时前
记录一下在k3s快速创建gitlab
java·kubernetes·gitlab
magrich14 小时前
Docker usage on ubuntu
ubuntu·docker·容器