sverre Posted August 5, 2011 Share Posted August 5, 2011 Hi! Me and my colleagues are going to start using GIT for our future projects, the advantages for us are actually overwhelming come to think about it. All introductions I have read on the subject seems to focus on that every developer have their own local copy of the repository, but I can't quite see that working for us. We are in a mixed environment with Linux-servers and Mac/Win-clients. The Linux webserver hase Zend Server with memory caching etc. That is the main reason why I don't think developing on our local machines will work. So my guess is that I will have to create a development area for every developer on the actual webserver (apache). I would like some input from you guys about what might be the best practices here. I also believe I need some kind of smart, dynamic domain mapping with that. So that a development version of a website exposed for the customer ( http://dev.customersite.com ) could also have a subdomain for every develop to their working version ( http://username.dev.customersite.com ) Anyone have experience of a similar Git setup or stumpled upon something good to read online, please let me know. I have found a lot of good articles about Git, but nothing really good about having a configured web server that all should be able to use for their work. Thanks for any help! /Daniel Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/ Share on other sites More sharing options...
trq Posted August 5, 2011 Share Posted August 5, 2011 All developers need to have there own working environment. All working in the exact same code base is ridiculous. Where I work we have our own workstation (with whatever OS you choose) and several virtual machines each for work. We then simply mount drives from the virtual machines onto or local machine or shell into the virtual machines and work. Currently we host our code within a subversion repository. Though myself and another developer use Git to commit to subversion. As for exposing development machines to clients. I guess it depends on your infrastructure, but most places would use a staging server for such things. We don't build web apps so don't really have an issue using only use a single staging server for everything (our sales reps can access and show clients). Some places however might have a staging server per developer - but I guess that is less common. So, to reiterate. I have Git installed locally but work within my own remote repositories which are mounted locally. I then push to subversion (you guys could just as easily push to a central Git repo). I would recommend taking a look at Gitolite if your going to host these repos internally. Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/#findComment-1252467 Share on other sites More sharing options...
sverre Posted August 5, 2011 Author Share Posted August 5, 2011 Well my idea was that our Linux server with Apache2 and Zend Server would serve as both staging server and development server by keeping everything separated. Maybe some think like this? /var /www (staging) /site /home /username (developer home) /www /site (working direcory) The developer could of course map that folder over the network, or work directly over ssh / sftp. Is that totally out of the question? Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/#findComment-1252495 Share on other sites More sharing options...
trq Posted August 5, 2011 Share Posted August 5, 2011 No man, that looks like a good plan. There's no particular reason you would need virtual machines if your only developing websites. We actually do development over the entire server which is why we need access to the entire OS. It's horses for courses. Just setup vhosts for each developer. They can then clone whatever repo they like into it and push to some single central Git repo. Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/#findComment-1252500 Share on other sites More sharing options...
sverre Posted August 18, 2011 Author Share Posted August 18, 2011 I have git setup on our development server now with a central repository and three developers currently working. Since everything is set up on a remote server, I was wondering if there is a Git client with GUI that can be used on client machines that enables checking out, comitting and comparing files even though everything resides on a server to which we only have ssh access? Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/#findComment-1259180 Share on other sites More sharing options...
trq Posted August 18, 2011 Share Posted August 18, 2011 Even though you have a central server you still work with local git repos. that is how git works. There are a few git gui's around apparently, though Iv'e not used any, try searching Google. Quote Link to comment https://forums.phpfreaks.com/topic/243905-best-solution-for-git-with-multiple-developers-on-same-server/#findComment-1259186 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.