NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.
Forum Discussion
ledermann
Oct 10, 2010Aspirant
gitscm: Can't connect to git repo
Hi! I have installed the gitscm add-on and can't get it to work, instead the "git-upload-pack: command not found" message appears. What I have done: - Installed gitscm-addon via FrontView and ...
WhoCares_
Oct 29, 2010Mentor
The problem when cloning using the git:// protocol is that by default git won't export any repositories unless told to do so:
So you have two options:
1) create the magic file "git-daemon-export-ok" in the .git directory within your git repo
2) add the "--export-all" option to the line starting with GITDAEMON_OPTIONS= in /etc/init.d/rfw-git-daemon
In either case restart the git daemon using
Now cloning should work using the git:// protocol. If you need to enable uploads (receive-packs), you need to either configure the repo to allow this or add the "--enable=reveice-pack" option to the GITDAEMON_OPTIONS line. Other settings you can use with the "--enable-option":
Again this works for the git:// protocol. Using SSH I still get the "command not found" error which has me really stumped for the PATH is added correctly for all user accounts involved. Will have to investigate more to get that one solved I fear.
-Stefan
A really simple TCP git daemon that normally listens on port "DEFAULT_GIT_PORT" aka 9418. It waits for a connection asking for a service, and will serve that service if it is enabled.
It verifies that the directory has the magic file "git-daemon-export-ok", and it will refuse to export any git directory that hasn't explicitly been marked for export this way (unless the --export-all parameter is specified). If you pass some directory paths as git daemon arguments, you can further restrict the offers to a whitelist comprising of those.
So you have two options:
1) create the magic file "git-daemon-export-ok" in the .git directory within your git repo
2) add the "--export-all" option to the line starting with GITDAEMON_OPTIONS= in /etc/init.d/rfw-git-daemon
In either case restart the git daemon using
/etc/init.d/rfw-git-daemon stop
/etc/init.d/rfw-git-daemon start
Now cloning should work using the git:// protocol. If you need to enable uploads (receive-packs), you need to either configure the repo to allow this or add the "--enable=reveice-pack" option to the GITDAEMON_OPTIONS line. Other settings you can use with the "--enable-option":
These services can be globally enabled/disabled using the command line options of this command. If a finer-grained control is desired (e.g. to allow git archive to be run against only in a few selected repositories the daemon serves), the per-repository configuration file can be used to enable or disable them.
upload-pack
This serves git fetch-pack and git ls-remote clients. It is enabled by default, but a repository can disable it by setting daemon.uploadpack configuration item to false.
upload-archive
This serves git archive --remote. It is disabled by default, but a repository can enable it by setting daemon.uploadarch configuration item to true.
receive-pack
This serves git send-pack clients, allowing anonymous push. It is disabled by default, as there is _no_ authentication in the protocol (in other words, anybody can push anything into the repository, including removal of refs). This is solely meant for a closed LAN setting where everybody is friendly. This service can be enabled by daemon.receivepack configuration item to true.
Again this works for the git:// protocol. Using SSH I still get the "command not found" error which has me really stumped for the PATH is added correctly for all user accounts involved. Will have to investigate more to get that one solved I fear.
-Stefan
Related Content
NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology!
Join Us!