Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make gittorrentd follow symlinks on first level? #24

Closed
anarcat opened this issue May 31, 2015 · 1 comment
Closed

make gittorrentd follow symlinks on first level? #24

anarcat opened this issue May 31, 2015 · 1 comment

Comments

@anarcat
Copy link

anarcat commented May 31, 2015

one of the issues i'm having deploying this is to try to put all the repos in the same directory, to work around #23. now that often means using symlinks, as my repositories are spread all over my filesystem...

it seems that gittorrentd doesn't follow symlinks, as it doesn't find the repos with symlinks here...

anarcat@marcos:~$ cd /tmp
anarcat@marcos:tmp$ mkdir test
anarcat@marcos:tmp$ cd test
anarcat@marcos:test$ git init test
Initialized empty Git repository in /tmp/test/test/.git/
anarcat@marcos:test$ touch test/.git/git-daemon-export-ok
anarcat@marcos:test$ touch readme
anarcat@marcos:test$ git add readme
anarcat@marcos:test$ git commit -m"test"
[master (root-commit) a549173] test
 1 file changed, 0 insertions(+), 0 deletions(-)
 create mode 100644 readme
anarcat@marcos:test$ cd ..
anarcat@marcos:test$ gittorrentd
in repo test/.git/git-daemon-export-ok
test/.git/
Announcing a5491738f6415acb996f98800b33421ea472d2d6 for ref refs/heads/master on repo test/.git/
{"repositories":{"test":{"master":"a5491738f6415acb996f98800b33421ea472d2d6"}}}
^Canarcat@marcos:test$ git init /tmp/test2
Reinitialized existing Git repository in /tmp/test2/.git/
anarcat@marcos:test$ ln -s /tmp/test2 test2
anarcat@marcos:test$ touch test2/git-daemon-export-ok
anarcat@marcos:test$ gittorrentd
in repo test/.git/git-daemon-export-ok
test/.git/
Announcing a5491738f6415acb996f98800b33421ea472d2d6 for ref refs/heads/master on repo test/.git/
{"repositories":{"test":{"master":"a5491738f6415acb996f98800b33421ea472d2d6"}}}
errors= []
hash= 30c2b6a80ec64021b58a592b8b1750433df4c185

notice, above, how test2 is not found.. is there a way to fix that?

@anarcat
Copy link
Author

anarcat commented May 31, 2015

oh, it's not symlinks, it's bare git repos that are not handled... see #25

[pid  4141] lstat("/var/lib/ikiwiki-hosting-web/git/wiki.anarc.at.git/.git/git-daemon-export-ok", 0x7fff6d0291d8) = -1 ENOENT (No such file or directory)

@anarcat anarcat closed this as completed May 31, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant