Skip to content

Build CyberPanel Image

E.L edited this page Sep 17, 2021 · 20 revisions

Build CyberPanel

Follow this guide to build a CyberPanel + OpenLiteSpeed image/template/snapshot.

Build Process

1. Launch a Server

Choose the Long Term Support version for the base image, e.g. Ubuntu 20.04.

Select a basic plan from the cloud platform.

2. Install CyberPanel

You can use a single command to install CyberPanel (with OpenLiteSpeed) easily. It is totally free and does not requires any kind of license.

bash <( curl -sk https://raw.githubusercontent.com/litespeedtech/ls-cloud-image/master/Setup/cybersetup.sh )

This installation may take around 8-12 minutes to finish.

3. Install Launch script

bash <( curl -sk https://raw.githubusercontent.com/litespeedtech/ls-cloud-image/master/Cloud-init/claunch.sh ) 

This step may clean up all SSH access methods, which means once you exit the server, you will not be able to SSH back

Launch script will do following:

a. Set up Welcome Banner

This is just a basic SSH console welcome message template. The banner will do the following:

  • Check the public IP address

  • Show the CyberPanel URL

  • Display how to get panel login access

  • Display how to get SQL access

  • Check if the CyberPanel version is up to date.

b. Install Upgrade Script

c. Others

  • Regenerate SSL Certificate

  • Regenerate Django secret key

  • Regenerate phpMyAdmin key

  • Regenerate SQL password

  • Regenerate CyberPanel password

  • Regenerate PowerDNS password

  • Regenerate pure-ftp password

  • Clean up passwords

  • Clean up SSH keys

  • Clean up logs

4. Build

Start building your image by SnapShot, Image or Template, which are provided by cloud providers, and that's it. You can now launch any type of servers from the snapshot you just built.

Test (Optional)

Validate script from DigitalOcean which can do some basic check if any log left in the system.

bash <(curl -sk https://raw.githubusercontent.com/digitalocean/marketplace-partners/master/scripts/99-img-check.sh )
bash <(curl -sk https://raw.githubusercontent.com/digitalocean/marketplace-partners/master/scripts/90-cleanup.sh )

There are many functions on the CyberPanel image. You can try some basic tests to make sure the important functions are working fine. For example:

  • Build an image via the cloud platform's build function

  • Launch a new server with same image you just built

  • Check if both the .db_password and .litespeed_password files generated on root or the /home/ubuntu folder correctly

  • Visit CyberPanel and try to access with the password found in the .litespeed_password file

  • Create a domain and WordPress site

  • Try PHP parameter

  • Try to access phpMyAdmin

  • Try Mail Service

  • Try PowerDNS

  • Try FTP Service

  • Try Docker Service

  • Try Security Service

  • Try to switch OpenLiteSpeed to LiteSpeed Web Server