A Secure VPS with DigitalOcean, Nginx, LetsEncrypt. Your VPS

Create a VPS with high security. Deploy a VPS server on DigitalOcean: Use Ubuntu, Nginx, MySQL, PHP and Letsencrypt
4.5 (20 ratings) Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
181 students enrolled
$19
$70
73% off
Take This Course
  • Lectures 54
  • Length 3.5 hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works

Discover

Find online courses made by experts from around the world.

Learn

Take your courses with you and learn anywhere, anytime.

Master

Learn and practice real-world skills and achieve your goals.

About This Course

Published 4/2016 English

Course Description

Create and configure your own virtual private server (VPS) from scratch and step-by-step.

During this course, learn to create from scratch your own VPS server, configure it properly, with security measures best suited and most appropriate mechanisms of operation.

Deploy your services and sites on a fast server like Nginx, with PHP or whatever you require, just perform and learn all that you can do with a VPS.

Displays all your projects with your own domain, with endless possibilities, because it is your VPS and your rules. Keep your own space in the cloud for all your work, projects and ideas; all in the same VPS.

Create your own VPS with DigitalOcean, installs and deploys a complete system with Linux / Ubuntu, PHP Nginx and MySQL besides obtaining TLS certificates completely free and automated through Letsencrypt.

With your VPS, you can install al what you need and you require, just learn how to do that and deploy all the projects that you want.

Why choose this course?

After completing this course, you will be able to deploy your own VPS server very quickly and easily, using very powerful tools, innovative and safe (Nginx, letsencrypt, PHP, MySQL, etc). You will have your personal and professional projects online without additional costs, because no matter how many domains, subdomains, or projects put on your VPS, the cost will remain the same because you can do all that you need in a single VPS.

Upon completion of all classes, have all your projects under a VPS server, completely safe with HTTPS / TLS connections, completely free through Letsencrypt.

Do you want more details? Here is everything that you can get from this course:

  • Create your own VPS server with DigitalOcean or the service that you prefer.
  • Have a safe and friendly fast system with Linux / Ubuntu on your VPS
  • Deploy a Nginx server in minutes on your VPS
  • Hardening your Nginx installation
  • Install a MySQL server quickly
  • Configure and easily use Git to deploy projects on your VPS
  • Get external packages and install them globally (composer and Letsencrypt as examples)
  • Create and set up your own domain and unlimited subdomains in a single VPS
  • Point your domain to your VPS server, configuring DNS entries
  • Connect to your VPS remotely, easily and safely
  • Learn to use basic commands (cd, service, cp, sudo, mv, rm, mkdir, reboot, etc.) directly on the VPS.
  • Learn to easily manage your packages with apt-get, keep updated your VPS
  • Assign permissions for folders in the right way
  • Keep easily updated your VPS system (retained packages and grub)
  • Managing user accounts for the VPS
  • Manage and assign administrative permissions (sudo / su) for users
  • Connect with third-party service from your VPS, through SSH keys
  • Easily set up a firewall and dramatically increases the security of your VPS
  • Set up your services to make them safer
  • Set headers expiration for your projects
  • Enables system Gzip on your server
  • Set up your services to reduce possible attacks DoS and DDoS
  • Avoid CSS / XSS
  • Install security certificates. HTTPS / TLS connections for your projects in your VPS
  • Use Letsencrypt and get easily free security certificates
  • Create domains and subdomains easily in your VPS
  • How easily deploy any project in your VPS
  • How to deploy complex projects in the VPS (Laravel as use case)

It does not end here! You are going to have lifetime access to all the current and new classes that are going to be added to the course, keep updated your VPS with the latest packages, versions, and systems.

Finally, but not less important, you can contact me at any moment; I will always be pleased to help with any problem or project.

Do not wait to be an expert and keep your own services and projects in the cloud with a VPS.

Join to the course now and see you in class!

What are the requirements?

  • Be able to pay for a VPS service, for the course and your own projects (5 USD / month)
  • Eager to learn and participate :)
  • Basic ideas about the web and online projects (cloud)

What am I going to get from this course?

  • Publish your projects to your own space in the cloud
  • Manage efficiently and safely your own VPS Server
  • Use the most recent and recommended techniques to manage your projects and services
  • Build high security projects easily and without pay extra

What is the target audience?

  • Who wants to manage his own space online
  • Who wants to have his own projects and services, safely and without pay extra
  • Who want full control over his projects, domains, subdomains and technologies

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.

Curriculum

Section 1: Introduction
02:00

Get a brief idea about all those thing that you are going to learn during the course and the final results of every class during the course.

03:10

During the course we are going to use DigitalOcean. Although it is not mandatory and required for the course (you can use other service)

02:55

Lets talk a little about nginx. I just have to say that (again) you are completely free to choose the server that you prefer (apache, nginx or other) depending of your requiriments. Basically during this course, we are going to use Nginx, because is much more effective managing the requests (multiple requests).

Nginx create a new thread for every user/client request, while apache works in a less effective way on this aspect.

02:54

Letsencrypt is a service which allow you to create your own certificates completely free and in fact install it into the server automatically.

Letsencrypt is an open source project, so you can found very nice projects working around this adding or improving some features.

2 questions

Lets check if the concepts were clear

Section 2: Starting With The VPS
04:35

During this class youa are going to create the VPS (maybe your first VPS) for your projects and for the course using DigitalOcean.

You are going to be allowed to create a VPS with a LEMP stack, pre-installed. It means that you can obtain a VPS with those tools installes, automatically:

  • Ubuntu
  • Nginx
  • MySQL
  • PHP
03:49

Windows is a little more "difficult" to stablish a connection to your VPS, because you need an external tool (we are going to use Putty). During this class you are going to learn how to donwload and use Putty to stablish a connection with your VPS.

Article

Through the SSH command that is natively supported on OSX and Linux, you can easily stablish a connection with your VPS from your OSX or Linux system.

Learn how the command SSH works and how to use it very very easy.

02:32

You can obtain your own domain in the service that you prefeer, the most important thing is that you need to configure your domain to redirect the requests to the namervers of your VPS provider.

In this case we are going to recirect the requests to supersecuredomain to the nameservers of digitalocean.

03:55

It is necessary to add th domain that we created to the DigitalOcean configuration. In this way, DigitalOcean is going to recirect all the requests to our domain to the VPS.

Additionally, we can create and configure all the subdomains that we prefeer very easy.

2 questions

Lets check if the concepts were clear

Section 3: Learning and Using Some Important Commands
03:03

There exists tons of different commands and of course you could require specific information about one new (or inclusive one that you already know).

Ubuntu, has a very helpful command that provide you information about another commands. This command is called "man". Lets to learn about it.

05:32

During this class you are going to learn about the cd (change directory) command. How to use it and some specific "tricks" for this command.

03:23

During this class you are going to learn about the command "ls".

This command is useful to show the contents of the current location or a specified location.

06:22

During this class you are going to learn how to create, delete, move and copy files. All those tasks require of specific commands, so lets to learn everyone.

04:27

During this class you are going to learn how to create, delete, move and copy folders. All those tasks require of specific commands, but in fact are almost the same for manage files (except to create), so lets to learn everyone.

04:26

During this class you are going to learn how to manage packages (install, remove, update) to install all what you need and additionally to keep your system up to date.

02:29

Generally after some specific updates, is very common that the system require to be restarted, in fact the systm will show us the message "System Restart Required" whe it is needed (of course). Lets to see how to do it and, some specific considerations during this process.

05:32

In some specific cases some packages can't be upgraded automatically by the system because require som "additional" steps or just are risky and, should be upgrded by the user (preferibly).

DUring this class you are going to learn how to upgrade the retained process and how to upgrade the grub if it is required.

03:32

In some specific situations it is required to stop, start, restart or just reload a specific service. Using the command "service" allow you to easily manage a specific service by name.

3 questions

Lets check if the concepts were clear

Section 4: Installing and Configuring Some Tools
Article

If your VPS provider does not allow you to automatically install the LEMP stack (Linux, Nginx, MySQL and PHP), just follow this simple steps to get it working on your VPS.

02:33

Git is a very useful package wich allow you to perfomr a version controlling for your projects or synchronize it with a remote repository on Github, Butbucket or similar services.

Lets to see during this class, how to easily install this package.

03:20

In order to use some important tools in our VPS, it is required to install some additional modules for PHP (not included by default).

Lets to install php5-cli (it is like a PHP intepreter) and enable the mcrypt module.

04:00

Composer is a very cool tool, to easily manage and install dependencies for PHP projects. Composer can not be installed using apt-get, so we are going to use an alternative way to do it and install it globally.

Article

The main idea of this section is mainly to install some required components, but additionally is to practice how to install (in different ways) a required package.

After this you possibly are capable to install the package that you require successfully. Of course of you want some help for a specific package, just let me know that.

Section 5: Setting an Initial Security Level
04:15

The SSH keys are very useful to validate connections between two parts. During this class you are going to learn, how to create SSH keys (public and private) to be used to stablish secure and valid connections.

Article

During a previous class we created an SSH keys. Learn how to configure and use those keys to stablish connections between the VPS and third-party services (github as example). 

06:59

During this class you are going to learn how to create and remove user accounts. You are going to create your personal user account to avoit use the root user.

04:30

It is very common that a specific user (may be many of them) require to perform some "advanced" tasks and, those tasks require advanced permissions. To solve this yo do not require to use the root user always, you can provide sudo permissions to a specific user and grant advanced capabilities.

06:09

There exists different ways to assign permissions to folders and files, but generally for web platforms it is a good practice to assign the permissions only for the server user.

During this class you are going to see how to assign permissions to a folder in the right way.

05:57

UFW (Uncomplicated FireWall) is a very useful firewall that comes installed by default with Ubuntu, but is disabled.

UFW is a very simple way to manage IPTables and control the inbound and outbound traffic.

During this class you are going to learn, how to configure and enable UFW in your system in order to disable all the inbound connections, excepting the web services connections (HTTP, HTTPS, SSH, etc), and enable the outbound connections.

01:51

After install the MySQL server, it is always a good recommendation (it is basically required), execute the secure_installation, in order to remove some insecure configurations and user accounts from the default installation of MySQL.

It is, in fact, very simple to perform and can save you.

03:20

During this class, you are going to see, how to easily remove the "dailymessage" and in the way practice and perform a system update.

For the new DigitalOcean droplets, is included a "daily message" to remember to you, to execute the secure installation of MySQL (like in the previous class) and spcifying the password for the root user of the MySQL server.

We already perform all those suggested steps, so we can remove the message.

Section 6: Initial Configuration of Nginx
04:35

During the class you are going to see a little overview for Nginx, the structure the location and the main files for the configuration.

09:34

During this class you are going to see where are located the files to configure different sites inside the single VPS, how to create different domains and or subdomains and configure every one independently with different root, names and folders.

04:41

During this class you are going to finish the creation and configuration process for the subdomains of your VPS.

02:45

During this class, you are goingo to see, how much easy is to configure the Gzip module on the Nginx server.

The Gzip module can be easily enabled and configured (in fact it is already enabled). This module is very useful to compress the responses from the Nginz server, and reduce the bandwidth usage. It is specially useful when the server must return responses with big cuantity of data.

05:54

It is a very good idea to stablish the expiration headers, for the static content. In this way, the browser and some clients, are not going to request for every one of those every time. After the firs time those files are going to be stored in the client side to the date of expiration.

Section 7: Hardening Nginx (Advanced Security Configurations)
02:49

During this class you are going to see, how to solve a little problem with the default configuration of Nginx.

By default Nginx include the server version and the operating system in all the responses, with a header called server. The purpouse of this class is disable this behaviour to avoid this.

05:46

Similarly, as Nginx. When we execute PHP code, the PHP service, automatically include, a header in every response, specifying the PHP version and the opearting system version as well.

During this class you are going to see the right way to disallow this for a nginx server.

03:58

The Cross Site Scripting (XSS) attacks, are basically a way as a possible attacker can use a real/valid user information to perform operations in our services, without permission.

During this class you are going to see, how to prevent this kind of attacks with a simple configuration of the nginx server.

08:32

In the current days, the DoS and specially the DDoS atacks, can't be prevented and solved. We can only mitigate the effects of those attacks with a good configuration and in specific cases (big projects) a good infrastructure.

Lets to learn how to configure your Nginx server to mitigate a possible DoS and DDoS attack.

2 questions

Lets check if the concepts were clear

Section 8: Deploy a Complete Project on You VPS (Laravel)
02:49

You already have installed git and, it means that you are able to easily obtain the code for a repository from Github, Bitbucket or similar.

During this class you are going to obtain the structure of a Laravel project, stored in a public Github repository using Git.

02:17

You already have access to composer in your VPS. Lets to use this incredible tool, to autimatically obtain all the dependencies of the Laravel project in order to use it.

This is like install the project into your VPS.

03:42

Lets to use the MySQL server to easily create a database for our project and on the way configure the environment and specify the user and password to stablish the database connection.

02:19

A very cool thing to perform, is to automatically create the database structure just runing single commands.

During this class you are going to see how to easily create the database structure using the migrations of the project.

04:03

Laravel as many other web frameworks and CMS, require permissions to write over some specific locations.

In the case of Laravel, it requires to write over the bootstrap/cache and storage/ folders.

During this class we are going to provide permissions over those folders to the www-data user, using the chown command.

02:23

It is time to test how it working the project on the VPS and fix some details at the end (a folder permissions).

Lets to play a little with this and see how much easy is to deploy advanced projects in your VPS.

Section 9: Setting HTTPS/TLS Websites With LetsEncrypt
04:20

Lets to use Letsencrypt directly from a Github repository (a third party), and obtain a much more light and easy to use client.

05:53

During this class you are going to see how much easy is to obtain a security certificate with letsencrypt and completely free for every one of your domains and sub-domains.

07:50

The final step, is to configure every domain and sub-domain, in order to stablish an HTTPS connection with every one using the security certificates.

05:17

Currently our services are vulnerable to a specific attack, which can downgrade the encryption level of a connection, allowing to intercept the connection with our sites.

During this class your are going to see how we are currently vulnerable to this and how to solve that very easy, based in the code of the previous class, implementing the dhparam configuration.

Section 10: Increasing the Security of The VPS
05:26

Using Fail2Ban, you can block specific IP addresses when they try to get access to your VPS more than a specified number of times in a specific period of time.

In this way, you can avoid that someone obtains your passwords trying every possible combination (brute force attack).

Section 11: How to Upgrade the Operating System of your VPS/Server
13:52

Take a look of the process to upgrade Ubuntu between LTS versions. In this case, from Ubuntu 14.04 LTS to Ubuntu 16.04 LTS.

Section 12: Conclusions and Recommendations
01:28

There are tons of things to learn, and much many contents and classes that I want to add to the course. It is temporally the end, but I will be in touch with you with new contents and new skills.

Article

If you already do not have an account with Digitalocean, you can create a new account and test their services for free up to 2 months.

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

JuanD MeGon, Experienced Web Developer, Programmer and Instructor

Systems and Informatics Engineer - Web Developer

Professional Instructor. Founder of ProgramarYa.

Found professional courses about web development with high quality and availability, PHP, Laravel and Web Development in general.

---------------------------------------------------

Ingeniero de sistemas e informática - Desarrollador Web.

Instructor profesional y fundador de ProgramarYa.

Encuentra cursos profesionales sobre PHP, Laravel y de desarrollo web en general, con alta calidad y disponibilidad.

Ready to start learning?
Take This Course