1

Here is my problem.

In our company we have a setup like this. There is a server with apache, php and all. All the client (dev) machine has their one drive (M:) mapped to the home folder on the server of that user. We have also setup the Dynamic document root. For e.g. jimy.www.domain.com get the document root as /home/jimitm/www/. Now we have started using GIT some days back. One problem we are facing is git status (or any other similar command) take too much time as it has to check every file for the change on the network drive.
What I was thinking is that at all possible that the document root would on client(dev) machine D: Drive (or some local state drive). So for jimy.www.domain.com the Document root will be D:/www of the client machine ?

Or is there any other workaround ?

2
  • Why don't you have a local working copy of the repo (as you say on D:) and push to the repo (as you already have on M:) on the server?
    – Dan D.
    Mar 14, 2014 at 11:33
  • @DanD. That would have 1 more step of syncing files on and D: and M:
    – jimy
    Mar 15, 2014 at 16:14

1 Answer 1

1

So, while git might be used on network shares, it is far from optimal -it needs to load both the .git files, and all the files from the network share to see what has changed.

Using network shares, you might mount folders from the server's side, however performance of this on server requests will be drastically worse, which increases your code-test-evaluate cycles from 5-10 seconds to ~10-30 seconds each. This is a performance (and psychological) penalty your developers will neither tolerate, nor can afford.

There are ways around this:

  • Using a similar configuration, our solution was also having shell access to the server, and using git from the shell only; this allows for semi-instant git checkout / commit, and also for auxiliary server-side scripts, specifically for deployment, rollback, and unit testing.

  • Another popular choice is having everyone work on fully local copies (by setting up a replica of the live environment in virtualbox), then committing their changes to the central repo

Hope this helps, comment if you need clarifications.

1
  • Most probably we will be opting the second suggestion. By the way thanks for the workaround of first suggestion.
    – jimy
    Mar 15, 2014 at 16:13

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .