Accessing your Server

After you have created your droplet, you'll need to access it, get it set up, and know how to push your project to it.

There isn't much point having an empty droplet sitting in the cloud is there? So at some point you will want to access your droplet, get it set up, and push your project files to the server. We recommend you take a look at our Get Started with your Product section to familiarize yourself with the project files and setup before actually running your project. But let's at least walk through your options for getting access, confirming your configuration and transferring files to your droplet.

Accessing your Droplet

Accessing your droplet should be a pretty simple process. One method involves accessing your droplets console via Digital Ocean's dashboard. You'll simply need to login in as 'root' and provide the same password you created as part of the droplet creation process. Job done.

However, you may prefer a method which allows access without needing to log in your Digital Ocean dashboard. So for that, you'll need to use an application such as PuTTY or OpenSSH. Now, if you didn't create a SSH key pair as part of your droplet creation, you should be fine to simply point these applications at your droplet IP address, and to log in via your root password. However, if you did create a key pair, you'll need to go through some extra steps which are well covered by Digital Ocean.

Droplet Configuration

Now, even though we created a droplet which has Ubuntu and Docker pre-installed, we still need to run through a couple of quick steps to make sure everything is ready for your Django application.

First, you will want to make sure the distribution is up-to-date. To do so, simply run the following commands via your console:

apt-get update -y
apt-get upgrade -y
apt-get dist-upgrade -y
do-release-upgrade

It should take 5 minutes or so to check, download and install any updates, so take a quick break if you need.

Next, we want to enable brute-force protection by running the following via console:

apt-get install fail2ban

This step will prevent IP addresses from logging into the server for 10 minutes if they provide an incorrect password three times, which is critical towards preventing patrolling bots which try brute-force tactics to access root.

Finally, we need to make sure we are running the correct version of Docker and docker-compose. This step is covered in the Install Docker and docker-compose section as part of your development environment setup. But in short, you'll want to check the current installed versions, and make sure they are up-to-date according to the requirements of your DjangoMango project.

Pushing your Files

If you worked through our steps to Set up Version Control as part of your Development Environment, you are going to find this step a breeze. You simply need to repeat the same steps to clone your project repository to your droplet. Job done.

However, if you don't want to set up version control, your other option is to access the droplet using File Transfer Protocol (FTP). FileZilla provides an FTP interface which can be installed on most OS types. And likewise, Digital Ocean provides a handy guide on how to get set up for file transfer using FileZilla. In short, you should be able to access your droplet by simply entering your droplets IP address into FileZilla and using SFTP over the default port 22.