GitLab recovery with only repo directory but without database

Recently my CentOS root partition is broken due to HDD failure. I have backup all the GitLab repositories (using rsync script daily). I have

  1. reinstalled CentOS and GitLab on a new HDD
  2. configure the etc/gitlab/gitlab.rb as the same as the old system
  3. resync the repositories to the data_dirs
  4. recreate a user with the same login

but I cannot see the old repo after login even they are physically locate in the HDD. I realised that I don’t have the old database copied.

Question: A. How to make a recovery with only the repo but no database? B. If I can find the old database, can I make use of it?