Deploying With Digital Ocean & nginx

DigitalOcean is a simple and robust cloud computing platform, designed for developers. It allows your to deploy websites on a remote server.

NGINX is a free, open-source, high-performance HTTP server and reverse proxy. NGINX is known for its high performance, stability, rich feature set, simple configuration, and low resource consumption. It allows you to deploy multiple sites and applications to a single Digital Ocean server.

The following steps apply for all sites.

1. Purchase a Digital Ocean Droplet.

Go to and register. Once you register you will be able to create a "droplet", which will be your own virtual private server that runs on Digital Ocean's hardware.

Reference Digital Ocean's guides for creating a droplet.

We currently recommend that you choose Ubuntu 14.04.5 as your server type.

2. Create and register an SSH key with Digital Ocean.

An SSH key is a unique code generated by your computer that you can register with online services and servers so that you can be granted access and prevent others from do so. You will need to generate an SSH key in order to log into (SSH into) your DO server.

You can follow DO's guide to Creating and Registering and SSH key.

  1. SHH into your remote server.
  2. Clone your Git repository.
  3. Create an nginx file in the sites-available folder.
  4. Link your nginx file to the sites-enabled folder.
  5. Restart nginx.
For full-stack applications:
  1. Install Forever / PM2.
  2. Start your server.
For apps using MongoDB:
  1. Install MongoDB on your remote server.
  2. Restart your server.