This guide will walk you through how to set up a droplet in Digital Ocean where you will host your backend and web source code.
1. Login to DigitalOcean
After you log into the DigitalOcean Control Panel with your email address and password for the first time, there are two ways to create a Droplet. You can either:
- Click the large, blue Create Droplet button. This button is only visible when you do not have any Droplets.
- Click the green Create button at the top right and choose Droplets.
2. Choose an image
The first configuration section is titled Choose an image. At the time of this writing, the 64-bit Ubuntu 16.04 image is selected by default. We'll keep that default Ubuntu image.
3. Choosing a size
The next configuration section allows you to choose the size of your Droplet, i.e. the amount of RAM and storage space it has. For our source code, we can start with $20/mo plan.
You can skip the Add block storage section for now.
4: Choose a data center region
Next, you're given a choice of data center regions.
For the best performance, choose the data center nearest to you and your users. More distant server locations may increase the server's latency without providing any practical benefits.
You can skip the Select additional options section for now.
5. Select SSH keys
The SSH keys are a key pair made between your computer and the server that allows the server to connect if it sees the matching key on the machine from which you are logging in. While a password can eventually be cracked with a brute force attack, SSH keys are nearly impossible to decipher by brute force alone. SSH keys provide more security than using a password. You have the option to use them in the Add your SSH keys section.
If you don't have an SSH key
You need to create an SSH key from your computer which you will upload it to the server to secure it. If you are using Mac OS X or Linux visit How to create an SSH key from a Linux machine. If you are using a windows OS visit How to create an SSH key from a Windows machine. Create an SSH key and then repeat step 5.
If you already have an SSH key then,
Click the New SSH key button.
Copy your public key and paste it in the SSH key content box and give it a name.
Once you upload the key, check the box by the key name to add it to your droplet.
6. Finalising and creating
The "Finalize and Create" section of the Create page allows you to choose the number and name(s) of the Droplets you're creating.
By default 1 droplet will be selected. Give the droplet a name and press Create.
7. Creating the Droplet
Once you have selected your options and click Create, a progress bar displays how close your Droplet is to being ready.
When the setup is 100% complete, the IP address of your Droplet will be displayed.
Your server creation is complete. Proceed to Step 2. Setting up the server for installation.