Cloud made easy: Get started with DigitalOcean


When the boss wants a prototype as soon as possible or a client needs something tomorrow, the cloud is the best place to turn. You can have a fully configured machine serving data in minutes.

One of the most developer-friendly options is , a cloud that offers fast machines at reasonable prices, delivering them in seconds. It doesn’t offer the fancier features that the major cloud providers do—at this writing—but it does package raw machines in a way that’s a breeze to deploy. If you’re a developer with an idea that needs a home, DigitalOcean’s machines are blank slates ready to go.

What’s on offer

Once paid for, DigitalOcean instances, called droplets, generally start in less than a minute. When combined with their reasonable pricing, this speed makes DigitialOcean droplets ideal for the buildup and tear-down common when testing and debugging new sites. With droplets, experimentation is easy.

There are several methods to begin with droplets, depending on your needs. Some developers will want a raw machine with a standard version of the operating system. That can be accomplished in a few steps. The rest of the build-out is up to you.

for each option.

This can be enough information to hang yourself, however. When I built out Drupal 8.1.3, I quickly discovered there was a security problem with the build and it was important to upgrade to 8.2.5 as soon as possible. You should recognize that the scripts may save you plenty of time and effort, but they won’t remove the need to learn more about the underlying software. You’ll need to learn how to maintain it and watch for potential problems.

Building a complete “one-click app” with prebuilt DigitalOcean images is very similar to building a basic version of the operating system. You make the same decisions about size, location, and other details. DigitalOcean simply loads a slightly different image with the software running.

Build a cluster on DigitalOcean

If your application is successful, you may find yourself with a droplet that can’t keep up with all the traffic. Increasing the size of the droplet can help, but the approach is limited when you need more CPU power.

Using several droplets that act like a cluster is the traditional solution. Several droplets can work together to respond to requests. Many call this process “load balancing”; DigitalOcean uses the term “floating IP address.” When you enable it, all of the traffic that comes into the particular IP address will be spread around the droplets in your cluster.

The first step to creating a cluster requires you have a droplet in place. Go to the main page for the droplet where networking information runs along the top. When you click on “Enable floating IP address,” it will take you to a page for configuring them. From here, you can connect the floating IP addresses to the droplets.

This page will also list all floating IP addresses in case you want to reassign or delete them. It’s a good idea to delete them when you’re finished—unused but assigned IP addresses are charged a small amount per hour because they’re valuable commodities.

Rebuild a DigitalOcean droplet after powering off

The power to your droplets can be turned off, an act that is a bit of a fiction for virtual machines running on a cluster. The host hardware stays on, but the virtual machine is shut off and must be rebooted when it is turned back on.

The best way to shut down a computer is through the operating system. Either of these commands will work from the command line:

sudo shutdown -h now
sudo poweroff

If your droplet becomes wedged or unresponsive, you can also shut it down from the DigitalOcean website, but this action could lead to corrupted data and inconsistent file systems. The Power tab for each droplet includes two options for either rebooting a droplet or shutting it off completely.

When you’ve shut down your droplet, you can resize, reconfigure, or fix it. The droplet can be turned back on by going to the Power tab of the droplet, then pushing the “Power on” button.

Resize a DigitalOcean droplet

When the power is off, the Resize tab of the droplet’s main page offers two options for resizing the droplet. The first merely changes the amount of CPU and RAM devoted to a droplet. It’s a good option when you need more power temporarily because it can be reversed, allowing you to switch back after you’re done.

The second option changes the RAM, CPU, and disk space, a step that can take longer because the disk space must be expanded. This option is not reversible because there’s no simple way to shrink the disk space. If you need to shrink the size of your droplet, you’ll need to create a new smaller version and copy data yourself using a or .

Rebuild the file system of a DigitalOcean droplet

You can restart many distributions with a recovery kernel after the machine is powered off. This option can be found under the Kernel tab of the droplet’s main page. When you click the button, you can swap out the kernel and restart it. Not every droplet has this option enabled. (It is generally a good idea to keep good backups so that you don’t need to rely on fsck to solve your problems.)

DigitalOcean offers a thorough on various ways to mount drives and execute standard fsck routines. They also offer the option for rebooting with a recovery ISO that can solve other problems and save data.

Make network changes to a DigitalOcean droplet

You can also adjust the network configuration of your droplet when it is powered down. The Networking tab of the droplet’s main page offers the option to either or access. Both can be configured with a click.