0
点赞
收藏
分享

微信扫一扫

Docker重启GitLab异常/opt/gitlab/embedded/bin/runsvdir-start: No such file or directory(特殊情况)

一、 基本情况

原来在学习gitlab安装的时候,学习了centos本地安装和docker安装,当时本地安装完成后直接关闭了gitlab服务,然后直接尝试Docker安装,Docker成功,然后想把本地安装的GitLab给卸载了。

# 停止gitlab
sudo gitlab-ctl stop

#卸载gitlab
sudo rpm -e gitlab-ce

#查看gitlab进程
ps -ef|grep gitlab

#杀掉第一个守护进程(runsvdir -P /opt/gitlab/service log)
kill -9 4473

#删除所有包含gitlab的文件及目录
find / -name *gitlab*|xargs rm -rf

执行到最后一步的时候,后悔了,因为是模糊匹配,会把GitLab的Docker配置和镜像也删掉,赶紧终止,重启docker的gitlab容器,果然报错

Thank you for using GitLab Docker Image!
Current version: gitlab-ce=11.7.4-ce.0

Configure GitLab for your system by editing /etc/gitlab/gitlab.rb file
And restart this container to reload settings.
To do it use docker exec:

docker exec -it gitlab vim /etc/gitlab/gitlab.rb
docker restart gitlab

For a comprehensive list of configuration options please see the Omnibus GitLab readme
https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/README.md

If this container fails to start due to permission problems try to fix it by executing:

docker exec -it gitlab update-permissions
docker restart gitlab

Preparing services...
Starting services...
Configuring GitLab...
/assets/wrapper: line 81: /opt/gitlab/embedded/bin/runsvdir-start: No such file or directory
/assets/wrapper: line 84: gitlab-ctl: command not found

解决方法,重新下载docker镜像,前提是你挂载的本地数据没被删掉。

举报

相关推荐

0 条评论