Why can't you just image the disk, a digital copy of a working c9 to your new workplace, then use rsync to do increment sync.
rsync -azHAXxP -e 'ssh -p22' username@your-droplet-IP \
"dd if=/dev/sda of=myworking-droplet.iso bs=512 conv=noerror,sync"
Now that you have a full copy of working droplet as an image (.iso) file,
you can copy this to any hard disk of your choice and boot into it.
Image your Cloud9 into USB
If your C9 filesize is less than 30G, you can copy this into usb drive and maintain a locally bootable copy, that is you can image this unto any larger USB
and make it bootable, to achieve this do :
Once finished, remove your drive, plug it into another PC,
change the boot order to USB Drive
and boot into your C9 locally
Sync Your Cloud9 workspace directory to another box
It gets better if you just want to sync your C9 workspace directory
over SSH connection to another box, use:
`rsync -azHAXxP -e 'ssh -p22' username@your-droplet-IP:/path/to/your/workspace .`
The above will clone your workspace directory over to your current box.
NOTE: The dot at the end of the command is necessary.
Mount your Cloud9 workspace to your local machine
Also you can mount your remote workspace file system to your local computer so you can make changes on
the fly and treat your droplet as local storage, so you can work and
access the same workspace locally without the need to login into your Cloud9
everytime you want to make changes or work on your project, to achieve this use:
Install SSHFS if not already installed with :
sudo apt-get install sshfs
Create a local directory in which to mount the droplet's file system.
sudo mkdir /mnt/mydroplet
Mount your droplet with:
sudo sshfs -o allow_other,defer_permissions \
root@xxx.xxx.xxx.xxx:/ /mnt/mydroplet
If your droplet is configured for login via ssh key authorization, use this:
`sudo sshfs -o allow_other,defer_permissions,IdentityFile=~/.ssh/id_rsa \
root@xxx.xxx.xxx.xxx:/ /mnt/mydroplet`
Now you can work with files on your droplet as if it were a physical device attached to your local machine.
Testing your mount from your local machine:
`cd /mnt/mydroplet`
Creat a test file
touch TestFile.php
Now login into you Clound9 and verify that you can access and modify the newly created file i.e TestFile.php
Now you can code locally, it immediately appears on your C9, or upload files from your local machine to your Cloud9 by copy file to your locally mounted directory.