Cannot clone projects via HTTP after upgrade from Gitllab 7.10 to 8.11

Hi,

After upgrade Gitlab version from 7.10 to 8.11 I’m not able to clone projects via HTTP

  • RHEL 6.7
  • Omnibus installation
  • External Apache

Cloning into ‘C:\Data\TestProject’…
warning: You appear to have cloned an empty repository.
Checking connectivity… done.

Gitlab logs:

Started GET “/gitlab/SANDBOX/TestProject.git/info/refs?service=git-upload-pack” for 10.0.46.84 at 2016-08-24 13:01:17 +0000
Processing by Projects::GitHttpController#info_refs as /
Parameters: {“service”=>“git-upload-pack”, “namespace_id”=>“SANDBOX”, “project_id”=>“TestProject.git”}
Filter chain halted as :authenticate_user rendered or redirected
Completed 401 Unauthorized in 112ms (Views: 7.0ms | ActiveRecord: 8.2ms)
Started GET “/gitlab/SANDBOX/TestProject.git/info/refs?service=git-upload-pack” for 10.0.46.84 at 2016-08-24 13:01:22 +0000
Processing by Projects::GitHttpController#info_refs as /
Parameters: {“service”=>“git-upload-pack”, “namespace_id”=>“SANDBOX”, “project_id”=>“TestProject.git”}
Filter chain halted as :authenticate_user rendered or redirected
Completed 401 Unauthorized in 17ms (Views: 0.3ms | ActiveRecord: 2.6ms)
Started GET “/gitlab/SANDBOX/TestProject.git/info/refs?service=git-upload-pack” for 10.0.46.84 at 2016-08-24 13:01:23 +0000
Processing by Projects::GitHttpController#info_refs as /
Parameters: {“service”=>“git-upload-pack”, “namespace_id”=>“SANDBOX”, “project_id”=>“TestProject.git”}
Completed 200 OK in 339ms (Views: 0.7ms | ActiveRecord: 16.5ms)
Started GET “/gitlab/SANDBOX/TestProject.git/HEAD” for 10.0.46.84 at 2016-08-24 13:01:24 +0000
Processing by NamespacesController#show as /
Parameters: {“id”=>“SANDBOX/TestProject.git/HEAD”}
Completed 401 Unauthorized in 17ms (ActiveRecord: 2.8ms)
Started GET “/gitlab/users/sign_in” for 10.0.46.84 at 2016-08-24 13:01:24 +0000
Processing by SessionsController#new as /
Completed 200 OK in 295ms (Views: 213.7ms | ActiveRecord: 4.9ms)

Any idea for what could be wrong?

Thank you

Found the solution!

Edit file gitlab.rb and added:

gitlab_git_http_server[‘listen_network’] = “tcp”
gitlab_git_http_server[‘listen_addr’] = “localhost:8282”

Added the following in apache configuration:

RewriteEngine on
RewriteRule /[-/\w.]+.git/ http://127.0.0.1:8282%{REQUEST_URI} [P,QSA,L]

Reconfigure Gitlab and restart Gillab and apache:

sudo gitlab-ctl reconfigure
sudo gitlab-ctl restart
service httpd restart

Hi @Soutaga. I’m interested to know what upgrade route you took here? Did you just upgrade the package straight to 8.11 latest from 7.10 or did you take any steps in between?

@Soutaga It is highly recommended that you update your Apache configuration to be like the example in the Recipes repository. While the change that you made may fix your clone issue, you are not reaping the full benefits of changes made to the way Gitlab handles incoming requests.

Yes, the upgrade was straight to 8.11.
I have just donwload the package manually and ran the command:

sudo rpm -Uvh gitlab-ce-8.11.0-ce.1.el6.x86_64.rpm

Hi @kohenkatz,

Thank you for the information.
I will have a look on the examples.