What Is OpenLiteSpeed?
OpenLiteSpeed is a high-performance, open-source web server that offers an event-driven architecture, built-in page caching, and a graphical admin interface. It is well-suited for hosting dynamic PHP applications on a Breeze with excellent resource efficiency.
Prerequisites
- A Breeze running Ubuntu 22.04 or later
- Root or sudo access
- A domain name pointed to your Breeze
Step 1: Install OpenLiteSpeed
wget -O - https://repo.litespeed.sh | sudo bash
sudo apt install openlitespeed lsphp83 lsphp83-mysql lsphp83-curl lsphp83-commonStep 2: Set Admin Password
sudo /usr/local/lsws/admin/misc/admpass.shEnter your desired username and password for the web admin console.
Step 3: Access the Admin Panel
Open your browser and navigate to https://your-breeze-ip:7080. Log in with the credentials you just set.
Step 4: Configure a Virtual Host
In the admin panel:
- Go to Virtual Hosts > Add
- Set the Virtual Host Name and document root (e.g.,
/var/www/yourdomain) - Under Listeners, map port 80 to your virtual host
- Set the PHP handler to
lsphp83
Step 5: Enable Rewrite Rules
Under the virtual host settings, navigate to Rewrite and enable rewrite. Add your rules in the rewrite rules text area, just as you would with Apache .htaccess syntax.
Step 6: Restart the Server
sudo /usr/local/lsws/bin/lswsctrl restartPerformance Tips
- Enable LiteSpeed Cache for dramatic speed improvements
- Use the built-in
.htaccesscompatibility for easy migration from Apache - Monitor server stats from the admin panel under Dashboard