DEV Community

Henrique Holtz
Henrique Holtz

Posted on

How to reset root password on gitlab-ce (self-managed) using gitlab-rake

In this article we'll see how to reset root password on gitlab-ce (community edition) self-managed using the embedded tool gitlab-rake.

First we need access the container of gitlab-ce (you can see How to run gitlab-ce (self-managed) on docker container), we'll access it by container name, in my case is gitlab_ce, let's entry with this command:

docker exec -it gitlab_ce bin/bash
Enter fullscreen mode Exit fullscreen mode

Then, into the container we'll reset the root password directly using the command bellow:

gitlab-rake "gitlab:password:reset[root]"
Enter fullscreen mode Exit fullscreen mode

The above command will request for you the new password and your confirm password. After you should see some message successfully as the image below:

Image Password successfully updated for user with username root

It's ready! Now, you can make your login with your new password and the root login:

Example of login using root user

Thanks for reading!

Top comments (0)