Recipe 38Using Dropbox to Collaborate and Host a Static Site

Problem

Our company and our partner company, AwesomeCableCo, are sponsoring Youth Technology Days. AwesomeCableCo has its own designer, Rob, who works remotely. We need a way to work with Rob on this site and show our bosses the progress we’re making. Rob doesn’t have virtual private network (VPN) access to our server farm, and our firewall allows deployment only from within our network.

Ingredients

  • An active Dropbox account and the Dropbox desktop client[120]

Solution

We can use Dropbox to collaborate on static HTML files and host them so they can be viewed by external users. With Dropbox we don’t need to worry about firewalls, FTP servers, or emailing files. Because Dropbox is cross-platform, we don’t have to waste time with different applications for each OS, making Dropbox a productivity win.

Let’s walk through the Dropbox client installation so we can document it and send it off to Rob. First, we head to the Dropbox website and get the installer.

Once installed, we can go to the Dropbox folder on our local computer. Dropbox automatically creates a Public folder, as shown in the following figure:

images/dropbox/starting_dropbox_folders.png

We can use this Public folder to distribute files to anyone in the world. Let’s make a youth_tech_days folder inside of that Public folder.

Now that we have a folder created, we need to invite Rob to collaborate with us. When we right-click the folder we created, we see a context menu that gives us the option to share this folder, as shown in the following figure:

images/dropbox/share_folder_from_pc.png

When we choose Share this folder, we’re taken to the Dropbox website to finish the sharing process, as shown in the following figure:

images/dropbox/sharing_on_dropbox.png

We fill out the information to share this folder with Rob.

Now we can move the files for the website into the youth_tech_day folder, which you can find in the book’s source code in the dropbox folder. Now the directory looks like the following figure:

images/dropbox/site_in_folder.png

Whenever we drop files into this folder, they’ll show up on Rob’s computer as well. When Rob updates the files, our copy will be updated to stay in sync. As we work on the files, we’ll want to communicate with Rob about what we’re doing so that we don’t overwrite his work. Dropbox has checks in place to handle conflicts if we edit a file at the same time as Rob, saving multiple copies of the file and appending a message to the filename indicating the conflict. This works fine for our simple situation, but if we are doing heavy active collaboration, we would should be using Git, as mentioned in Recipe 32, Managing Files with Git.

Now we need to show our bosses what we’ve done. Since we put the files in the public folder, they’re available on the web to anyone who knows the URL. To find the address of our index file, we right-click it and choose Copy public link, which saves the URL to our clipboard. We can test the URL—one similar to http://dl.dropbox.com/u/33441336/youth_tech_days/index.html—by opening it in a browser.

This is a great, simple way to collaborate with people outside our company and easily show progress without the need for an FTP server, web server, or VPN connection. We can add other contributors to our project and share the URL with anyone who’s interested in our progress.

Further Exploration

We can further explore by sharing nonpublic folders with coworkers and friends. We can also use nonpublic folders to back up files and share them among several of our own computers. In addition, we can use the public folder to send Mom an Internet Explorer patch she just can’t seem to find on her own or provide our clients with a place to send us photos or other assets they’d like us to post on their sites. Other uses include the following:

  • Hosting files you want to share on a blog post

  • Sharing a folder with each of your clients for easy collaboration

  • Forwarding a vanity domain to a public site

  • Creating a blog with Enfield and hosting it from Dropbox

If your registrar or DNS provider supports redirection, you could set up a URL that’s easier for people to remember when they want to check out your pages on Dropbox.

Also See

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.140.207.79