I tried setting up git-shell
on our CentOS (6.4) system (after getting this working correctly on Ubuntu 13.10, maybe cross platform hot mess?)
my /etc/passwd shows
git:x:500:500:Web Archive VCS:/home/git:/usr/bin/git-shell
and my shell commands are in /home/git/git-shell-commands
[root@domain git]# cd /home/git/git-shell-commands/ && tree
.
├── addkey
├── create
├── drop
├── help
└── list
But ssh'ing in is still giving me
Last login: Fri Nov 15 12:14:49 2013 from localhost
fatal: What do you think I am? A shell?
Connection to localhost closed.
I am working off of this resource
http://planzero.org/blog/2012/10/24/hosting_an_admin-friendly_git_server_with_git-shell
There was some confusion that this was licensed GIT commands (push/pull etc) but this is a restricted shell with pre set commands! Please anyone reading this make note ;)
Installer script if you want to see steps
https://github.com/ehime/bash-tools/blob/master/git-server-setup.sh
EDIT
I still have not been able to resolve this over the weekend, I HAVE added
# add to shells
echo '/usr/bin/git-shell' >> /etc/shells
# Prevent full login for security reasons
chsh -s /usr/bin/git-shell git
And have double checked that GIT Shell actually exists in /usr/bin
[root@domain bin]# ll /usr/bin | grep git
-rwxr-xr-x. 105 root root 1138056 Mar 4 2013 git
-rwxr-xr-x. 1 root root 1138056 Mar 4 2013 git-receive-pack
-rwxr-xr-x. 1 root root 457272 Mar 4 2013 git-shell
-rwxr-xr-x. 1 root root 1138056 Mar 4 2013 git-upload-archive
-rwxr-xr-x. 1 root root 467536 Mar 4 2013 git-upload-pack
This IS a root account that I am dealing with though, could that have something to do with it?