🚧 Under construction — VoTechWorks is being built. A free tech program — complimentary, as our commitment to get America working.
voTechWorksGrade 13 · a vocational technology learning center, by urbanicity
newSchoolWorks.com › VoTechWorks › Technology & Design › Web & Software Development › Deployment: Servers, CI/CD, and Cloud Publishing › Lesson 2
TEC-WEB46-07 · Lesson 2 · 14 clock hours · lab

Cloud Hosting Platforms and VPS Provisioning

Objective. Students provision a virtual private server (VPS) on a cloud platform, assign SSH key authentication, and verify remote access from their local machine.

⚠ Pending professional review

This lesson, its worked examples and its practice questions has not yet been verified by an industry-certified professional or by a certification or approval body. It is a study draft and may contain errors. Do not use it as instructions for work on a job site or on live equipment. Always follow your instructor, your supervising professional, and current official references and regulations.

VoTechWorks program approval and accreditation are still in progress. Credentials are issued only by the certifying bodies named in each program, after their own exams.

What Is a VPS and Why Does It Matter?

A virtual private server (VPS) is a slice of a physical server that runs its own operating system and behaves like a dedicated machine. Cloud providers such as DigitalOcean, Linode/Akamai, and AWS Lightsail carve large bare-metal servers into many isolated VPS instances using a technology called virtualization. Each instance gets its own CPU allocation, RAM, disk, and public IP address.

For web developers, a VPS is often the first "real" server they manage. Unlike shared hosting, you have root access, which means you can install any software, configure the firewall, and deploy applications exactly as needed. With that power comes responsibility: a misconfigured VPS can expose user data or become a platform for attacks against others.

Choosing a Cloud Provider and Image

All major providers offer a web console where you create and manage instances. Common choices for learners include:

When creating an instance, you choose an operating system image. This lab uses Ubuntu LTS (Long-Term Support), which receives security updates for several years and is widely documented. Always prefer the latest LTS release so your system stays supported.

You also select a region (the data center closest to your users or lowest in latency to you), a plan tier (the combination of CPU, RAM, and disk), and a monthly cost. Entry-level plans on most providers start under $10/month. Record all of these details in your lab log — future troubleshooting often depends on knowing exactly what was provisioned.

SSH Key Authentication

Secure Shell (SSH) is the standard protocol for remote terminal access to Linux servers. By default, a new VPS may allow password login, but password authentication is a security risk because automated bots constantly scan the internet for SSH ports and attempt brute-force logins.

Key-based authentication replaces the password with a mathematically linked pair of files:

This lab uses the Ed25519 algorithm, which is modern, compact, and considered strong by current standards. Older RSA keys still work, but Ed25519 is the current best practice.

Generating the Key Pair

On your local machine, open a terminal and run:

```

ssh-keygen -t ed25519 -C "your_email@example.com"

```

Accept the default file location (`~/.ssh/id_ed25519`) or choose a custom path. You will be prompted to enter a passphrase. Use a passphrase — it encrypts the private key on disk so that if your laptop is stolen, the key cannot be used without the passphrase.

The command produces two files:

Uploading the Public Key

Most cloud consoles let you paste the contents of `id_ed25519.pub` into a field during instance creation. Copy it with:

```

cat ~/.ssh/id_ed25519.pub

```

Then paste the output into the provider's SSH key field. The provider injects it into `/root/.ssh/authorized_keys` on the new instance automatically.

Connecting to Your VPS

Once the instance is running (usually within 60 seconds), connect from your terminal:

```

ssh root@<your-server-ip>

```

If your key is in the default location, OpenSSH finds it automatically. If you used a custom path:

```

ssh -i ~/.ssh/id_ed25519 root@<your-server-ip>

```

On first connection, SSH displays a host fingerprint and asks you to confirm. Verify the fingerprint matches what the cloud console shows (some providers display it on the instance detail page) before typing `yes`. This protects against a man-in-the-middle attack where someone intercepts your connection.

Security Basics for a New VPS

Once you have root access, a few immediate steps protect the server:

1. Update packages — run `apt update && apt upgrade -y` to apply security patches.

2. Disable password authentication — edit `/etc/ssh/sshd_config` and set `PasswordAuthentication no`, then restart SSH. This closes the door to brute-force attacks.

3. Firewall — Ubuntu's `ufw` (Uncomplicated Firewall) lets you allow only the ports you need (`ufw allow OpenSSH`, then `ufw enable`).

4. Do not store sensitive credentials on the server in plain text — use environment variables or a secrets manager.

Lab Log Entry

Accurate documentation is a professional habit. Your lab log entry must include: the provider name, instance name, region, Ubuntu LTS version, plan tier (CPU/RAM/disk), the server's public IP address, and the monthly cost estimate from the pricing page. Use the program's standard log template. Incomplete logs are a common reason students do not pass the lab check.

Why This Skill Connects to Your Credentials

CompTIA Linux+ covers managing Linux systems, remote access, and basic security hardening — all practiced here. CompTIA ITF+ introduces foundational computing concepts including networking and cloud basics. Hands-on VPS work builds the operational context that makes those exam topics concrete.

Key terms9

Virtual Private Server (VPS)A virtualized server instance running on shared physical hardware, given its own OS, IP address, and resources, and managed by the tenant as if it were a dedicated machine.
SSH (Secure Shell)A cryptographic network protocol used to operate network services, especially remote command-line login, securely over an unsecured network.
Ed25519A modern public-key signature algorithm used to generate SSH key pairs; favored for its strong security and compact key size compared to older RSA keys.
Public keyThe shareable half of an SSH key pair, placed on the server in the authorized_keys file so the server can verify the identity of whoever holds the matching private key.
Private keyThe secret half of an SSH key pair, kept only on the user's local machine; it must never be shared and should be protected with a passphrase.
Ubuntu LTSA Long-Term Support release of the Ubuntu Linux distribution that receives security and maintenance updates for an extended period, making it a stable server OS choice.
Host fingerprintA unique cryptographic hash of a server's public host key, displayed during the first SSH connection so the client can confirm it is connecting to the intended server.
Brute-force attackAn automated attempt to gain access by systematically trying large numbers of username and password combinations, a primary reason password SSH authentication is disabled on production servers.
ProvisioningThe process of creating and configuring a cloud resource — such as a VPS — including selecting its image, region, size, and authentication method, so it is ready for use.
In class: Create a VPS instance on a cloud provider (such as DigitalOcean, Linode/Akamai, or AWS Lightsail) using the provider's web console, selecting an Ubuntu LTS image. · Generate an Ed25519 SSH key pair locally, upload the public key during provisioning, and log in to the server without a password. · Document the instance's IP address, region, plan tier, and monthly cost estimate in a lab log entry following the program's standard log template.
Materials: Student laptops, cloud provider account (instructor-provided or free-tier), OpenSSH client, lab log template, cloud provider documentation
Check: Instructor verifies live SSH login to the student's VPS using only key authentication; lab log entry is complete and accurate. Both required to pass.

Practice check8

Answer each question, then check it. Nothing is recorded; this is your own practice.

CompTIA Linux+ — Security
1. Which file should you upload to the cloud provider's console when setting up SSH key authentication for a new VPS?
CompTIA Linux+ — Security
2. Why is disabling SSH password authentication recommended on a public VPS?
CompTIA Linux+ — Security
3. You run ssh-keygen -t ed25519 and accept all defaults. Which permission setting is correct for the private key file?
CompTIA Linux+ — Security
4. When connecting to a VPS for the first time, SSH displays a host fingerprint and asks you to confirm. What is the purpose of this step?
CompTIA ITF+ — Infrastructure
5. Which of the following best describes what a VPS region setting controls?
CompTIA Linux+ — System Management
6. After provisioning an Ubuntu VPS, which command applies available security updates to the system's packages?
CompTIA Linux+ — Security
7. A student generates an Ed25519 key pair but stores the private key in a shared team folder on a cloud drive. What is the primary security risk?
CompTIA Linux+ — System Management
8. Which of the following is a valid reason to choose an Ubuntu LTS release rather than a non-LTS release for a production VPS?
Record this lesson on my transcript. Sign in with your key and enrollment email to record lessons (enroll free if you have no key). This page stays open to read and practise.