gitlab的密码忘了,内网服务器,正好也有gitlab服务器的权限。

百度结果大部分都是通过 gitlab-rails console production方式重置的,但是没有找到gitlab-rails,版本的差异导致的

也有通过执行 undle exec rails console production 这个命令来操作的,但是提示没有 bundle这个命令

 

 

 

需要进入到cd /opt/gitlab-8.8.4-0/apps/gitlab/htdocs/vendor/目录下面,执行

bundle exec rails console production命令,注意也需要切换到git用户下

su - git

cd /opt/gitlab-8.8.4-0/apps/gitlab/htdocs/vendor/

bundle exec rails console production

gitlab 重置密码 版本差异 8.8.4-0

进入终端提示行来进行修改

user = User.find_by(email: '邮箱') // 或者根据id等修改

user.password = '密码'

user.password_confirmation = '密码'

user.save

 

参考博文

https://blog.csdn.net/oxp7085915/article/details/52242193

 

 

 

 

 

相关文章:

  • 2021-07-30
  • 2022-12-23
  • 2021-11-01
  • 2022-12-23
  • 2021-07-09
  • 2021-06-20
  • 2022-02-26
猜你喜欢
  • 2021-10-04
  • 2021-10-01
  • 2021-08-04
  • 2022-02-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案