Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm now teaching data bases and all my students get access to a virtual machine running ubuntu. They use FTP as the main way of connecting to the server and uploading their PHP files. Last time I was told that FTP was slow as every change you made you had to open filezilla, send the file and then test if it works. So, now I'm looking for something more automatic, something like GIT where you just push to the server using git push. Any ideas what can be used?

share|improve this question
3  
Any reason against simply using git for this? –  Falcon Momot Mar 18 at 1:57

2 Answers 2

up vote 2 down vote accepted

It's likely the most simple solution would be for you to use rsync over ssh.

This requires that each user have an account on the server. For this example, assume that they're wanting to copy files from their local machine, /home/user1/folder to /home/user1/foo on the server. To do this, they'd run the following from their workstation:

$ rsync -avz --progress --delete /home/user1/folder/ user1@server.example.com:/home/user1/foo/"

This will synchronize the workstation directory to the server directory.

There are many, many other options. Git is not a bad one. Using it will require a bit more training, though, as well as setup on the server.

share|improve this answer
    
The "a bit more training" is likely to be well worth it, too, as you're teaching about version control as a bonus. I'm amazed how many software dev grads I see getting out of colleges w/o having experienced a VCS. –  ceejayoz Mar 18 at 2:03
    
@ceejayoz Great point. –  EEAA Mar 18 at 2:04

A simple alternative, still using FTP, might be to use an FTP client which manifests as a filesystem - for example I use curlftpfs under Linux. Never looked at them, but Webdrive and FTPDrive apparently do something similar under Windows.

A couple of alternative solutions which might do something similar - Setting up the server with SAMBA (if the clients are Windows) or NFS (if the clients run Linux or similar). There is also sshfs clients.

The limitation of the above range of solutions is it is very easy to do work on the live server - which might not be ideal in a production environment.

share|improve this answer
1  
Not sure it's a great idea to recommend continuing to use FTP when 1) OP is asking for an alternative and 2) FTP is a horrible, insecure file transfer protocol that has no business existing in today's computing environment. :) –  EEAA Mar 18 at 2:16
    
Except that the problem he purported to be trying to solve is one of speed of making changes, no changes need to be made to the server to support it, most web providers still allow only FTP access. I also provided 3 alternatives which perform the same goal - SAMBA, NFS and SSHFS - and pointed out the downside. I agree that FTP sucks as a protocol through. –  davidgo Mar 18 at 3:22

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.