Deploying cPanel & WHM on DigitalOcean Marketplace: A Step-by-Step Guide

One-Click Apps1~weeks ago~Updated LetsHosting
338 0
Deploying cPanel & WHM on DigitalOcean Marketplace: A Step-by-Step Guide
If you’re looking to set up a powerful and user-friendly web hosting environment, deploying cPanel and WHM (Web Host Manager) on the DigitalOcean Marketplace is an excellent choice. This guide will walk you through the entire process, from understanding what cPanel and WHM are to configuring your server after deployment. By the end, you’ll have a fully functional hosting environment powered by DigitalOcean’s high-performance cloud infrastructure.

1. Introduction to cPanel and WHM

  • cPanel is a Linux-based web hosting control panel that provides a graphical interface and automation tools to simplify website and server management. With cPanel, you can easily manage:
    • Website files and directories
    • Email accounts and databases
    • Domains and subdomains
    • Security features like SSL certificates
    • And much more
  • WHM (Web Host Manager) is the administrator-level tool that complements cPanel. It allows hosting providers and server admins to manage multiple cPanel accounts and perform server-wide tasks, such as:
    • Creating and managing hosting accounts
    • Configuring server settings and security
    • Monitoring server performance
    • Managing DNS and nameservers
Together, cPanel and WHM offer a complete web hosting management platform, making it easier for both beginners and experienced users to manage websites and servers.

2. Why Use DigitalOcean Marketplace?

DigitalOcean is a popular cloud infrastructure provider known for its simplicity, scalability, and cost-effectiveness. Here’s why deploying cPanel and WHM on DigitalOcean Marketplace is a great option:
  • High-Performance Infrastructure: DigitalOcean’s virtual machines (Droplets) are powered by fast SSDs and offer excellent performance for hosting websites and applications.
  • Ease of Use: The Marketplace provides pre-configured 1-Click Apps, including cPanel & WHM, which simplifies the installation process.
  • Scalability: You can easily scale your resources as your hosting needs grow, ensuring your server can handle increased traffic and more websites.
  • Cost-Effective: DigitalOcean offers transparent pricing with no hidden fees, and you can start with a plan as low as $5/month (though cPanel requires at least 1GB RAM and 20GB disk space).
  • Developer-Friendly: DigitalOcean’s platform is designed for developers, offering features like private networking, API access, and seamless integration with other tools.
By combining cPanel’s ease of use with DigitalOcean’s reliable cloud infrastructure, you get a powerful hosting solution that’s both flexible and affordable.

3. Prerequisites

Before you begin, make sure you have the following:
  • A DigitalOcean Account: If you don’t have one, sign up at DigitalOcean and take advantage of their 60-day free trial with $100 in credits.
  • A Domain Name: You’ll need a fully qualified domain name (FQDN) for your server’s hostname (e.g., server.example.com).
  • Basic Technical Knowledge: Familiarity with SSH, command-line interfaces, and basic server management will be helpful.
  • Minimum Server Requirements: cPanel recommends at least 1GB of RAM and 20GB of disk space, but for better performance, consider 2GB RAM and 40GB of disk space.

4. Step-by-Step Deployment Guide

Follow these steps to deploy cPanel and WHM on a DigitalOcean Droplet:

Step 1: Create a DigitalOcean Droplet

  1. Log in to your DigitalOcean account.
  2. Click the green “Create” button in the top-right corner and select “Droplets”.
  3. In the “Choose an image” section, select the “Marketplace” tab.
  4. Search for “cPanel & WHM” and choose either:
    • cPanel & WHM® for AlmaLinux 8 (recommended for most users)
    • cPanel & WHM® for Ubuntu (if you prefer Ubuntu)
  5. Click “Create cPanel & WHM® Droplet”.

Step 2: Choose Droplet Size and Region

  1. In the “Choose Size” section, select a Droplet plan that meets cPanel’s requirements (at least 1GB RAM and 20GB disk space). For better performance, choose a plan with 2GB RAM or more.
  2. In the “Choose Region” section, select a data center region closest to your target audience for faster access.
  3. (Optional) You can add block storage for backups, but it’s recommended to skip this until after configuring your server.

Step 3: Set Authentication and Hostname

  1. In the “Authentication” section, choose “Password” and set a strong root password. (Note: You’ll change this later.)
  2. In the “Hostname” section, enter a fully qualified domain name (FQDN) for your server (e.g., server.example.com).
    • Important: The hostname must be a valid FQDN and should not start with “www” or a number, or end with a hyphen.

Step 4: Create the Droplet

  1. Click “Create Droplet” to provision your server.
  2. DigitalOcean will automatically begin installing cPanel & WHM in the background. This process takes about 10-15 minutes.
  3. Note: You cannot log in to WHM until the installation is complete.

Step 5: Access Your Server via SSH

  1. Once the Droplet is created, you’ll receive an email with your server’s IP address and a one-time root password.
  2. Use an SSH client to connect to your server:
    • On macOS/Linux: Open Terminal and run ssh root@your_server_ip.
    • On Windows: Use an SSH client like PuTTY.
  3. Enter the one-time password from the email, then set a new, secure root password when prompted.

Step 6: Log into WHM

  1. After the installation completes (10-15 minutes), open your browser and navigate to https://your_server_ip:2087.
  2. Log in using the username root and the password you set in Step 5.
  3. Accept the license agreement by clicking “Agree to All”.

Step 7: Configure WHM

  1. You’ll be prompted to log into or create a cPanel Store account to obtain a trial license. Follow the on-screen instructions.
  2. Once logged in, you’ll be taken to the WHM setup wizard:
    • Enter your contact email.
    • Set your server’s hostname (if not already set).
    • Configure nameservers: Choose “BIND” for the nameserver configuration and set your nameservers (e.g., ns1.example.com, ns2.example.com).
    • Set the FTP server to “Pure-FTPD” (default).
    • Select “Use filesystem quotas”.
  3. Click “Finish” to complete the setup.

5. Post-Deployment Configuration

After deploying cPanel and WHM, there are a few additional steps to ensure your server is properly configured and secure.

Step 5.1: Set Up Nameservers

If you plan to host your own DNS on the cPanel server:
  1. Register your nameservers at your domain registrar (e.g., ns1.example.com and ns2.example.com pointing to your server’s IP).
  2. In WHM, go to “Server Configuration” > “Basic WebHost Manager® Setup” and ensure your nameservers are correctly set.

Step 5.2: Secure Your Server

  1. Firewall: Enable and configure a firewall (e.g., CSF) to protect your server.
  2. SSL Certificates: Install SSL certificates for your domains to enable HTTPS.
  3. Regular Updates: Keep your server and cPanel updated to the latest versions for security patches.

Step 5.3: Create cPanel Accounts

  1. In WHM, go to “Account Functions” > “Create a New Account”.
  2. Enter the domain name, username, and password for the new account.
  3. Assign a package or set resource limits manually.
  4. Click “Create” to set up the account.

6. Troubleshooting Common Issues

Here are some common issues you might encounter and how to resolve them:
  • License Errors: Ensure you have a valid cPanel license. If using a trial, make sure it hasn’t expired.
  • Connectivity Issues: If you can’t access WHM, check if the installation has been completed and verify your server’s IP address.
  • Nameserver Problems: If DNS isn’t resolving, double-check your nameserver settings in WHM and at your domain registrar.
  • Firewall Blocking Ports: Ensure ports 2087 (WHM) and 2083 (cPanel) are open in your firewall.
For more detailed troubleshooting, refer to the cPanel Documentation.

7. Conclusion

Deploying cPanel and WHM on DigitalOcean Marketplace is a straightforward process that combines the power of cPanel’s hosting management tools with DigitalOcean’s reliable and scalable cloud infrastructure. By following this guide, you’ve set up a robust hosting environment that’s ready to manage websites, email, databases, and more.
Whether you’re a beginner or an experienced webmaster, this setup offers the flexibility and control you need to succeed. Now that your server is up and running, you can start creating accounts, adding domains, and building your online presence with ease.

Related Posts