The goal of this project is simply to create an easy setup GitLab instance that one could simply drop in a lab and run with. I am sure there are better ways to do this but this is my way and it works for those just getting started.
Installation:
-
To install you first install docker on your host. Instructions on how to do that can be found on the docker website here: https://docs.docker.com/get-docker/
-
Next install docker compose on the system following the instructions here: https://docs.docker.com/compose/install/
-
Now simply clone the repo to your local system with this command:
git clone https://github.com/mon0pixel/docker-gitlab -
Apply the execute permission to the .sh file.
chmod +x ./install.sh -
And spin up the services with the installer script:
./install.shFor HTTPS use the --ssl switch.
./install --ssl
Setting the root password:
I hope to improve this in the future but for now to set the root password you need to perform the following steps.
-
Launch the ruby console on the host:
docker exec -it gitlab /opt/gitlab/bin/gitlab-rails console -
Load the user profile for root into a variable:
user = User.find(1) -
Set the password with the following two commands:
user.password = '<YOUR PASSWORD>' user.password_comfirmation = '<YOUR PASSWORD>' -
Save the changes with the final command:
user.save! -
You should now be able to log in with the username of root and your password.