首页 > 其他分享 >gitlab root密码重置

gitlab root密码重置

时间:2023-05-09 22:26:44浏览次数:33  
标签:gitlab 4.2 com 重置 user irb main root

[root@VM-16-14-centos ~]# su - git
-sh-4.2$ gitlab-rails console production
Loading production environment (Rails 4.2.6)
irb(main):001:0> user = User.where(id:1).first

irb(main):009:0> user.password='admin@123!'

=> "admin@123!"
irb(main):010:0> user.save
=> true
irb(main):011:0> user = User.where(id:1).first

irb(main):002:0> user.email='[email protected]'

=> "[email protected]"
irb(main):003:0> user.save
Enqueued ActionMailer::DeliveryJob (Job ID: 4e4deb11-0292-4ad7-9e17-29943391f42b) to Sidekiq(mailers) with arguments: "DeviseMailer", "confirmation_instructions", "deliver_now", gid://gitlab/User/1, "S_K14x1f3jceB-xBYJzy", {:to=>"[email protected]"}
=> true
irb(main):004:0>quit
-sh-4.2$

 

标签:gitlab,4.2,com,重置,user,irb,main,root
From: https://www.cnblogs.com/myibm/p/17386472.html

相关文章

  • 台式机装Ubuntu 遇到“no root file system is defined”、安装类型上没有“删除直接
    今日,给清华要的两台电脑终于拿到手了(下午拿到的,具体坎坷经历见日报)。开始配环境,主要是三个步骤:1、装Linux2、装网卡和网卡驱动3、装GNU_radio一系列环境(见我上个月虚拟机的操作方案)今天完成了1和2.最恶心的是1.首先报的错误是,norootfilesystemisdefined,确实,但是为什么......
  • python GUI(beeware) + uiautomator2 实现root后的安卓手机自动执行脚本
    python环境:python3.81:安装beewarebeeware教程:https://docs.beeware.org/en/latest/tutorial/tutorial-2.html2:安装python模块uiautomator23:测试代码代码结构 app.py"""Myfirstapplication"""fromtoga.styleimportPackfrom.dy_dianzanim......
  • WARNING: Running pip as the 'root' user can result in broken permissions and con
      pipinstall-rrequirements.txt报错"WARNING:Runningpipasthe'root'usercanresultinbrokenpermissionsandconflictingbehaviourwiththesystempackagemanager.Itisrecommendedtouseavirtualenvironmentinstead:https://pip.pyp......
  • 自动化部署(Gitlab)
    小程序可持续化自动部署一、安装gitlab-runner官方地址:https://docs.gitlab.com/runner/install/windows安装如下:nodejs的环境变量一定要放到系统变量中!!!进入硬盘任意一个目录,下载gitlab-runner.exe文件,根据电脑是64位还是32位下载cd到文件所在目录中,进行注册。命令:./gitl......
  • (非root权限)java环境配置
     打开文件:vim~/.bashrc 末尾添加配置:exportJAVA_HOME=/usr/share/jdk8exportPATH=$JAVA_HOME/bin:$PATHexportCLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar更新:source~/.bashrc(更新路径) ......
  • 解决mysql出现docker出现access denied for user root@% to database“xxx”的问题
    使用navicat连接Linux上的数据库时,新建一个库出现异常无法创建accessdeniedforuserroot@%todatabase返回Linux查看mysql状态状态正常,navicat也能正常连接,排除掉应该是权限的问题dockerexec-itd7bcc087dce1bash进入mysql容器 mysql-uroot-p登录账......
  • 交换机重置console口密码
    1、通过Console口连接华为交换机,手动重启交换机。2、界面出现BIOS LADING...,按下快捷键“Ctrl+B”并输入BootROM/BootLoad密码,进入BootROM/BootLoad主菜单。3、初始密码:[email protected]  A必须大写。4、选择7 Clearpasswordforconsoleuser 清除console用户密码模式......
  • Rocky Linux 9 GitLab 部署
    1、环境8核/16G内存/500G硬盘当前gitlab暂不支持RockyLinux9,不过可以使用AlmaLinux8的安装源进行安装2、安装依赖#安装依赖dnfinstall-ycurlpolicycoreutilsopenssh-serverperlpostfix#启动邮件服务systemctlenable--nowpostfix3、安装源配置(......
  • gitlab密码忘记了怎么办?
    gitlab密码忘记了怎么办?长时间不用代码管理工具gitlab,忘记密码了怎么办?可以使用如下的方式去修改root的密码登陆管制台gitlab-railsconsole修改密码#查找切换账号u=User.where(id:1).first#修改密码u.password='更改后的密码'#再次确认密码u.password='更改后的密码'#......
  • Vulhub 漏洞学习之:Gitlab
    Vulhub漏洞学习之:Gitlab目录Vulhub漏洞学习之:Gitlab1GitLab任意文件读取漏洞(CVE-2016-9086)1.1环境安装1.2漏洞利用过程2GitLab远程命令执行漏洞(CVE-2021-22205)2.1环境安装2.2漏洞利用过程2.2.1脚本复现2.2.2手动复现1GitLab任意文件读取漏洞(CVE-2016-9086)GitLab......