Spinning up your own Linux server in the cloud takes about ten minutes and a few dollars a month. In this beginners guide I’ll walk you through creating a VPS on DigitalOcean from scratch – no prior server experience needed.
We’ll start by generating an SSH key so your server is locked down from the very first boot, then create a Droplet, add a startup script that configures the machine for you automatically, and walk through the settings worth turning on. Finally we’ll SSH in and talk about what to do with it.

Startup Script Code
Below is the code that was used in the startup script section of the instance creation process:
#!/bin/bash
export DEBIAN_FRONTEND=noninteractive
APT_OPTIONS='-o Dpkg::Options::=--force-confdef -o Dpkg::Options::=--force-confold'
apt-get update
apt-get $APT_OPTIONS -y dist-upgraderoot@digitalocean-tutorial:~#