4

We are a team of less than ten persons that need to quickly set up a git server that supports active directory based authentication.

The simplest solution seems to be to use a file share with a bare git repository and reaching it using a unc path, e.g.

git clone //server/share/repo.git

However, we are a bit worried about robustness. Are there no issues with concurrency when several people use the same git repository and there is no actual server component running?

Clients are running windows 7, server is Windows Server 2008R2. Using msysgit 1.8.1.2

(I am well aware that there are many other git server solutions, but, especially given the requirement of AD authentication, they are not as simple to set up)

Klas Mellbourn
  • 42,571
  • 24
  • 140
  • 158
  • Interesting question. As an aside, it definitely seems unwise to have a local repo on a smb share: https://answers.atlassian.com/questions/17026/source-tree-corrupts-git-index-file-on-smb-share. – Andrew Mao Feb 25 '13 at 19:28
  • It shouldn't be a problem. Even if there is a problem git keeps full repository on each instance, and you will be able to restore it say from your machine. – David Sergey Feb 25 '13 at 19:28
  • What is the problem with concurrency? git is a distributed version control system. It should inherently handle such scenarios. – Peter L. Feb 25 '13 at 19:30
  • I'm not entirely sure about the answer to your question but, as someone who had to set up something similar, we went with https://github.com/otac0n/WebGitNet/wiki/Getting-Started and used IIS's built-in windows authentication. – Wesley Wiser Feb 25 '13 at 19:31
  • Possible dupe http://stackoverflow.com/questions/750765/concurrency-in-a-git-repo-on-a-network-shared-folder?rq=1 – willoller Feb 25 '13 at 19:34

1 Answers1

2

It seems the only times the AR Auth will be in play is pushing/pulling.

When you clone the git repo, the entire history will be cloned as well, so every user will have a complete repo.

If the file share fails, any user can replace the code on a new share by pushing their code up.

Concurrency is not an issue - since git is distributed it handles concurrency differently from other VCSs: no file locks, etc.

willoller
  • 7,106
  • 1
  • 35
  • 63