GitLab change user password

gitlab modify user password


 1. Enter the management of gitlab sudo gitlab-rails console production ;
  2. Query the user information of the lost person user = User.where(id: 1).first or  
      user = User.where(name:''xiaoqiang").first; Through this, you can query
      information such as user name, email and id
  3. Reset the password to 123456 user.password='12345678'
  4. Confirm the password to 123456 user.password_confirmation='12345678 '
  5. Save user.save!
  6. Exit quit

gitlab modify user password official document


  1. gitlab-rails console production

  2. user = User.where(id: 1).first

  3. user = User.find_by(email: '[email protected]')

  4. user.password = 'secret_pass'
user.password_confirmation = 'secret_pass'

  5. user.save!

 

get itstick out tongue

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326124254&siteId=291194637