Gitlab Docker in Docker: no errors but cannot login

I’ve created an efficient docker image that makes restoring backups and deploying backups (for testing purposes) trivial. For this, i’m using Docker in Docker, so that my container will restore the GitLab container in itself.

Everything seems to work except as soon as i get to login page it says that my login credentials are incorrect!? When I check the logs there is nothing to indicate the reason. Only a failed login attempt.

For comparison, if i use the exact same restoration scripts directly on my host system it works perfectly and i can actually login.

What is the reason why login would not work for GitLab container inside a container?

I wouldn’t be surprised if it’s because Gitlab have been deprecating Docker-In-Docker (DIND). First it started with the security scanners and then for SAST and was completely deprecated in Gitlab 13.4. I believe the only thing left that does currently supports DIND is CI/CD. So chances are the reason why it doesn’t work is because of this. Especially since you configured it works normally on your system.

If nothing is showing up in the logs anywhere, virtually impossible to figure out why. Alternatively, you can attempt resetting the user login/password that you attempted to login with after restore: Reset a user's password | GitLab and if that doesn’t work, then it would mean Gitlab doesn’t support Docker In Docker anymore for such situations.

1 Like

cheers @iwalker that’s very helpful to know. Had no idea they had/are depreciating DIND.

1 Like