Hello, Since I've properly installed Gitlab from ports we are unable to push anything on the repositories. All users got the following error: remote: GitLab: The project you were looking for could not be found. To git@unixcorn.org:Papey/dotfiles.git ! [remote rejected] master -> master (pre-receive hook declined) error: impossible de pousser des références vers 'git@unixcorn.org:Papey/dotfiles.git' I told them to verify their configuration (who seems OK): ssh -T git@unixcorn.org Welcome to GitLab, XXXXXXX XXXXXXXXX! I also checked the repositories rights: root@hulk:/usr/local/www/gitlab # ls -al /usr/home/git/repositories/ total 11 drwxrws--- 6 git git 6 Apr 11 10:30 . drwxr-xr-x 7 git git 19 Apr 10 21:05 .. drwxrwx--- 2 git git 2 Apr 11 10:59 Papey drwxrwx--- 2 git git 2 Apr 10 19:33 UnixcornProject drwxrwx--- 4 git git 4 Apr 11 10:59 matunixe Any help would be very appreciated. Thanks in advance !
Hello, that is strange. Can you please report me the result of the following two commands: ls -lah /usr/local/share/gitlab-shell/hooks/ and: pkg info gitlab-shell Greetings, Torsten
(In reply to Torsten Zühlsdorff from comment #1) Hello Torsten, Thank you for your very quick reply, there is the result: total 45 drwxr-xr-x 2 root wheel 5B Apr 10 13:30 . drwxr-xr-x 7 root wheel 22B Apr 10 13:30 .. -r-xr-xr-x 1 root wheel 492B Mar 31 20:15 post-receive -r-xr-xr-x 1 root wheel 483B Mar 31 20:15 pre-receive -r-xr-xr-x 1 root wheel 357B Mar 31 20:15 update And for the pkg info: gitlab-shell-2.7.1 Name : gitlab-shell Version : 2.7.1 Installed on : Sun Apr 10 13:30:23 2016 CEST Origin : devel/gitlab-shell Architecture : freebsd:10:* Prefix : /usr/local Categories : devel Licenses : Maintainer : ports@toco-domains.de WWW : https://gitlab.com/gitlab-org/gitlab-shell Comment : GitLab Shell handles git commands for GitLab Annotations : Flat size : 147KiB Description : GitLab Shell handles git commands for GitLab and modifies the list of authorized keys. WWW: https://gitlab.com/gitlab-org/gitlab-shell Something seems wrong with the permissions of the first directories checked, can you confirm ? Greetings, Mathias
(In reply to Mathias B. from comment #2) > Something seems wrong with the permissions of the first > directories checked, can you confirm ? Not really. There was an error which wrong permissions of the hooks in gitlab-shell, but you clearly use the already fixed ones. Can you have a look at /usr/local/www/gitlab/logs? There are various logfiles written by GitLab. Maybe they can give as a clue.
(In reply to Torsten Zühlsdorff from comment #3) Sadly there is nothing interesting in production.log and sidekiq.log :-(
(In reply to Mathias B. from comment #4) > Sadly there is nothing interesting in production.log and sidekiq.log :-( You do not use the default configuration, do you? I registered an account at the provided link and created a repository. I could not even clone a repository via HTTPS or SSH: $ git clone https://git.unixcorn.org/Zuehlsdorff/test.git Klone nach 'test' ... Username for 'https://git.unixcorn.org': Password for 'https://Zuehlsdorff@git.unixcorn.org': fatal: Authentication failed for 'https://git.unixcorn.org/Zuehlsdorff/test.git/' $ git clone git@unixcorn.org:Zuehlsdorff/test.git Klone nach 'test' ... The authenticity of host 'unixcorn.org (62.210.123.14)' can't be established. ECDSA key fingerprint is 98:96:05:bb:cb:9a:b1:77:75:e3:f1:49:4e:09:8e:97. No matching host key fingerprint found in DNS. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added 'unixcorn.org' (ECDSA) to the list of known hosts. Password for git@hulk: Password for git@hulk: Password for git@hulk: Permission denied (publickey,keyboard-interactive). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. That is very suspicious and clearly works out of the box for me. I fear it is not possible to get deeper into this without having a look at the machine itself. :/
I'm sorry - i could clone the repository. Now i can reproduce the error: $ git push -u origin master Enter passphrase for key '/home/thorny/.ssh/id_rsa': Zähle Objekte: 3, Fertig. Schreibe Objekte: 100% (3/3), 231 bytes | 0 bytes/s, Fertig. Total 3 (delta 0), reused 0 (delta 0) remote: GitLab: The project you were looking for could not be found. To git@unixcorn.org:Zuehlsdorff/test.git ! [remote rejected] master -> master (pre-receive hook declined) error: Fehler beim Versenden einiger Referenzen nach 'git@unixcorn.org:Zuehlsdorff/test.git' Next idea: What is the content of /var/log/gitlab-shell?
(In reply to Torsten Zühlsdorff from comment #6) No problem, thank you very much for helping. There is the content of the log file suggested (since you register): I, [2016-04-11T15:04:39.107973 #19741] INFO -- : Adding project Zuehlsdorff/test.git at </home/git/repositories/Zuehlsdorff/test.git>. I, [2016-04-11T15:04:39.113447 #19741] INFO -- : Moving existing hooks directory and symlinking global hooks directory for /home/git/repositories/Zuehlsdorff/test.git. I, [2016-04-11T15:04:39.804357 #19743] INFO -- : Adding project Zuehlsdorff/test.wiki.git at </home/git/repositories/Zuehlsdorff/test.wiki.git>. I, [2016-04-11T15:04:39.809732 #19743] INFO -- : Moving existing hooks directory and symlinking global hooks directory for /home/git/repositories/Zuehlsdorff/test.wiki.git. I, [2016-04-11T15:13:49.436553 #19821] INFO -- : Adding key key-4 => "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDXgrbZrbTy2BNhFnZ2UXZPrLfdXcvOj8+n8UkaKChufd1/YxbjACF5cFXYO//O6o8hjlrWaPZQOARoj2sydtSQhMiw7zi5zD3sZtPKzrAtBWM+KqMy/bPsm/QMtPl0SPhxSmeQKZ167344NjFDhJex0pb3FhRvaa8dcjNzU5luvXuAnhLLBWPZR+8/b1qivlV88YgRveb4DXQ22D1H+RaYrDwaSK4NYehohn9tuvDnytfh3etZlzjXDAsLU9U2Qk4Fi/LU7srb1+6ilS3mSt8geEUtte9FY+t7kwEOJB48Zz5p5ZVCTdhhIAELB+0Fz8irfHUXTLMc2HjLRbWWymWR thorny@hera" I, [2016-04-11T15:14:42.263884 #19827] INFO -- : GET http://localhost:8080/api/v3/internal/discover?key_id=4 1.20685 I, [2016-04-11T15:15:10.342534 #19849] INFO -- : POST http://localhost:8080/api/v3/internal/allowed 1.24163 I, [2016-04-11T15:15:10.342660 #19849] INFO -- : gitlab-shell: executing git command <git-upload-pack /home/git/repositories/Zuehlsdorff/test.git> for user with key key-4. I, [2016-04-11T15:15:37.518898 #19863] INFO -- : POST http://localhost:8080/api/v3/internal/allowed 0.02636 I, [2016-04-11T15:15:37.519092 #19863] INFO -- : gitlab-shell: executing git command <git-receive-pack /home/git/repositories/Zuehlsdorff/test.git> for user with key key-4. I, [2016-04-11T15:15:37.665611 #19867] INFO -- : POST http://localhost:8080/api/v3/internal/allowed 0.00890 I, [2016-04-11T15:16:16.383018 #19877] INFO -- : GET http://localhost:8080/api/v3/internal/discover?key_id=3 1.26858 I, [2016-04-11T15:17:00.514028 #19889] INFO -- : POST http://localhost:8080/api/v3/internal/allowed 0.02920 I, [2016-04-11T15:17:00.514241 #19889] INFO -- : gitlab-shell: executing git command <git-upload-pack /home/git/repositories/matunixe/archlinux-on-macbook_air.git> for user with key key-3.
I did find a greater number of issue-reports with this error message, but all seems to be older and a problem of GitLab itself. Last try: Please create a new repostiory, clone it and than try to push it. And provide the full production.log for these actions. Hopefully this gave us some clues. Otherwise just the project itself can help.
(In reply to Torsten Zühlsdorff from comment #8) I created a repo named "tester", there is the full production.log (I didn't see anything not normal): Started GET "/" for 81.64.129.130 at 2016-04-11 15:37:05 +0200 Processing by RootController#index as HTML Read fragment views/namespaces/3-20160410142322039080000/projects/1-20160410173642599506000/root/index/application_settings/1-20160410190932055824000/v2.2/8b33c854a46dcf7f6d598c9a827c46de (0.1ms) Write fragment views/namespaces/3-20160410142322039080000/projects/1-20160410173642599506000/root/index/application_settings/1-20160410190932055824000/v2.2/8b33c854a46dcf7f6d598c9a827c46de (0.2ms) Completed 200 OK in 381ms (Views: 153.0ms | ActiveRecord: 20.6ms) Started GET "/projects/new" for 81.64.129.130 at 2016-04-11 15:37:07 +0200 Processing by ProjectsController#new as HTML Completed 200 OK in 355ms (Views: 185.2ms | ActiveRecord: 15.9ms) Started POST "/projects" for 81.64.129.130 at 2016-04-11 15:37:12 +0200 Processing by ProjectsController#create as HTML Parameters: {"utf8"=>"✓", "authenticity_token"=>"[FILTERED]", "project"=>{"namespace_id"=>"3", "path"=>"tester", "import_url"=>"", "description"=>"", "visibility_level"=>"0"}} Redirected to https://git.unixcorn.org/matunixe/tester Completed 302 Found in 2075ms (ActiveRecord: 200.6ms) Started GET "/matunixe/tester" for 81.64.129.130 at 2016-04-11 15:37:15 +0200 Processing by ProjectsController#show as HTML Parameters: {"namespace_id"=>"matunixe", "id"=>"tester"} Completed 200 OK in 644ms (Views: 391.5ms | ActiveRecord: 33.7ms) Started POST "/api/v3/internal/allowed" for 127.0.0.1 at 2016-04-11 15:37:27 +0200 Started POST "/api/v3/internal/allowed" for 127.0.0.1 at 2016-04-11 15:38:24 +0200 Started POST "/api/v3/internal/allowed" for 127.0.0.1 at 2016-04-11 15:38:25 +0200 Started GET "/matunixe/tester/edit" for 81.64.129.130 at 2016-04-11 15:38:31 +0200 Processing by ProjectsController#edit as HTML Parameters: {"namespace_id"=>"matunixe", "id"=>"tester"} Completed 200 OK in 409ms (Views: 175.1ms | ActiveRecord: 19.2ms) Started GET "/admin" for 81.64.129.130 at 2016-04-11 15:38:33 +0200 Processing by Admin::DashboardController#index as HTML Completed 200 OK in 337ms (Views: 169.5ms | ActiveRecord: 22.0ms) Started GET "/admin/logs" for 81.64.129.130 at 2016-04-11 15:38:36 +0200 Processing by Admin::LogsController#show as HTML
You are right - there is nothing suspicious in the logfiles :( Since it is already broken: would you like to test the patch for the next version? You can find it here: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=208511 Maybe it solves the problem. If not, this would be a good base for an issue at https://gitlab.com/gitlab-org/gitlab-ce/issues/. I will let the PR open. Maybe we find a solution or new idea to try later. I'm sorry i couldn't help any further.
Hey Torsten, Thanks for answering again. :-) I upgraded with the provided patch, everything works well except the problem we found before. I'll go open a bug report in the official gitlab repo. Bye!
Can you provide the link to the issue? I like to follow ;)
(In reply to Torsten Zühlsdorff from comment #12) Of course, there it is: https://gitlab.com/gitlab-org/gitlab-ce/issues/15143
Meh, nobody cares. :(
(In reply to Mathias B. from comment #14) > Meh, nobody cares. :( You can also try it at: https://github.com/gitlabhq/gitlabhq/ There is often more response (but not always).
Did any of the newer versions (8.5.12 or 8.7.2) fix the issue ?
(In reply to Kurt Jaeger from comment #16) Hey, thanks for questioning. I didn't try, I needed a Gitlab instance running quickly. So I setup a Debian guest on my hypervisor... As I'm unable to debug further I think we can close this bug, no?
Hi guys, I found a solution to this issue, as I had exactly the same problem with a fresh install on Freebsd 10. I needed to change the following things: repo_path in gitlab-shell config.yml to /usr/home/git/repositories repos_path in gitlab gitlab.yml to /usr/home/git/repositories/ It is because the default value /home is a symlink on Freebsd. After this the system works flawlessly.
(In reply to Gabor from comment #18) > It is because the default value /home is a symlink on Freebsd. > After this the system works flawlessly. After reading this, i think you are right. There is a big warning about symlinks above the pathes and i wasn't aware about the home-symlink. Attached a patch with a proposed solution. Please test it and give feedback.
Created attachment 170448 [details] patch with patched config for devel/gitlab-shell and www/gitlab
Created attachment 170874 [details] patch to update gitlab-shell
I did the test by myself and the patch worked. :) I added a patch for devel/gitlab-shell to fix the issue. The patch for www/gitlab will be contained in the update for GitLab itself. Greetings, Torsten
Sorry mate, I didn't had the chance to test it, but I trust in you :)
A commit references this bug: Author: pi Date: Thu Jun 2 06:15:01 UTC 2016 New revision: 416268 URL: https://svnweb.freebsd.org/changeset/ports/416268 Log: devel/gitlab-shell: fix the supplied example file for /usr/home PR: 208693 Submitted by: Torsten Zuehlsdorff <ports@toco-domains.de> (maintainer) Changes: head/devel/gitlab-shell/Makefile head/devel/gitlab-shell/files/patch-config.yml.example
Committed, thanks!