CMS & WordPress
drtanz — 2012-05-02T04:40:03-04:00 — #1
I would like to have a desktop PC and a laptop available for development. I am using XAMPP on the desktop which I use as my main workstation, however I'd like to just change location and be able to continue working on the laptop. It seems that it is possible to move the /htdocs folder to Dropbox so the XAMPP instances on both devices would use the same shared folder. That would be a part-solution, what about the question of databases, how would I go about that? I'm sure there are others who work in a similar fashion, so I'd like some pointers on how to set this up properly. Thanks
webcosmo — 2012-05-02T12:44:22-04:00 — #2
Why not use one of them as a server computer, and then create a network to allow remote access from other computers. This way you can have everything on one place still access from others.
jason__c — 2012-05-02T17:54:45-04:00 — #3
Are we talking Linux or Windows? I also agree with webcosmo, setting up a server-client relationship would be the best solution for multi-computer setup. The biggest problem you would run into, excluding client-server solution, would be database integrity between 2 computers. Plus, it is very easy to set up a client-server relationship with two personal computers.
spacephoenix — 2012-05-03T02:15:45-04:00 — #4
Something like http://www.usbwebserver.net/en/ is probably what your looking for. I've never used it myself. I guess it would be a case of saving any work, shutting the server down and then moving the USB stick to the other computer to switch over
jj35 — 2012-05-03T07:48:35-04:00 — #5
The beauty of XAMPP is that it is configured to be used as a full web server. I agree with webcosmo, simply identify one of your machines as the server, and do all af your dev from there. You can further configure access to your files via ftp or a direct share, which you will be able to access from both machines.
drtanz — 2012-05-03T09:05:35-04:00 — #6
That would be ideal if my main desktop is always switched on and I am working from home, but I'd like both computers to be independent of each other, and be able to work from any location with internet access. That's why Dropbox would be very nice. Another alternative I thought about is to use Bitbucket to host files there and then use Git to pull files to each computer. Not sure that would sort the database issue though anyway.
jj35 — 2012-05-03T09:35:51-04:00 — #7
I have used a Dropbox solution similar to the one you mention, and simply drop my dev files into the right location on each machine. This worked great most of the time, but a couple of times there was a connectivity or other issue, and the files didn't get updated on machine #2. As you can imagine, when I started editing on #2 the changes were propagated to #1, overwriting my original updates. Uggh.
Anyway, I finally shelled out the $50 annual fee for a hosting plan on 1and1 (or was it godaddy, or somewhere similar?), which solved most of the problems I was running into. Btw, these plans typically provide git support as well.
sg707 — 2012-05-03T14:53:33-04:00 — #8
For me, I try to develop using the same machine if possible. If I need to work from diff computer then I remote access. Of course, I use SCM but I run all the resources like db's/servers/etc... locally. Many times, I tweak those settings. For these tweaks, it's hard (more of remembering issue) to synchronize these between multiple computers. Anyways, your dropbox sounds like a solution but you won't be able to synchronize completely.. the last thing you want to ask is "It runs on A computer but not on B computer". Another option is to remotely wake the computer. I've never done this but here's a resource link.
sg707 — 2012-05-03T15:05:28-04:00 — #9
I like this solution! Keep everything in USB.
markbrown4 — 2012-05-03T18:00:43-04:00 — #10
I think copying files across would probably work for you as a first step, for the db you'll just want do something like http://dev.mysql.com/doc/refman/5.1/en/mysqldump.html
However, it's really easier to be working with with source control & db migrations rather than doing these manual steps if you're moving between machines a lot.
For example, here's all I would need to do to update the code and migrate the database using a framework like Rails.
wwb_99 — 2012-05-04T07:58:34-04:00 — #11
This is a solved problem. What you want to do is use source control, such as subversion, git or mercurial. Work on files on any PC, commit changes, pull updates from the other PC. Also get great features like change tracking, the ability to roll back versions or even the ability to maintain multiple divergent versions in a sane and rational manner.
drtanz — 2012-05-04T10:54:28-04:00 — #12
For the files yes, but for the database? Would you do an export and import each time?
wwb_99 — 2012-05-04T14:50:22-04:00 — #13
We usually keep a reference backup that travels with the code so we've got something to stand up and test against. When doing most dev work the rows in the database tend not to matter.
mittineague — 2014-09-22T02:08:08-04:00 — #14
This topic is now archived. It is frozen and cannot be changed in any way.