I've installed GitLab on an Ubuntu Server. Everything seems to work fine except I can't push/pull/clone to/from the server.
When I push I get the general error message:
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
I've tried everything from hours of googling, but I can't seem to locate a problem.
sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production
Runs fine, OK across the board!
I can SSH into [email protected] I get:
PTY allocation request failed on channel 0
Welcome to GitLab, Anonymous!
When I do:
ssh [email protected] "ls /location/of/git/dir"
I get:
Not allowed command
The website is running, when I create a repository on the site it appears in /home/git/repository/
But I still can't push to it.
I followed this guide:
https://github.com/gitlabhq/gitlabhq/blob/5-0-stable/doc/install/installation.md
and this guide to get it running on apache:
http://shanetully.com/2012/08/running-gitlab-from-a-subdirectory-on-apache/
You need to use git pull and resolve the difference between your local changes and the remote changes before you can git push . There is still a commit in the remote branch initializing the repo that may not be in your local version.
I finally figured it out after many hours of debugging, and I somehow knew there was a simple issue with the configuration.
Since the second guide mention how to set up gitlab on apache with a relative url you actually have to do some more configs inside gitlab. I uncommented the line about relative url:s unicorn.rb and in gitlab-shell/config I added my whole URL (with subdirectory).
Before:
http://web-adress.com/
after:
http://web-adress.com/subdomain/
Now it works great.
You can test it with the command bellow. When you login it should say your name.
ssh -T [email protected]
Welcome to GitLab, Christian Hammer!
If it says "Welcome to GitLab, Anonymous!" gitlab does not recognise you as a user of gitlab.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With