In order to run the script we need to make the file executable with the following command:<\/p>\n
chmod +x ols1clk.sh<\/pre>\nFor this guide we are going to assume that you want to use PHP7 and install only OLS without WordPress being installed (We prefer to install wordpress separately). So lets run the following command:<\/p>\n
.\/ols1clk.sh --lsphp 70<\/pre>\nWhen the installation is complete, configure an administrative username and password for the OpenLiteSpeed\u2019s web interface by running the following command:<\/p>\n
\/usr\/local\/lsws\/admin\/misc\/admpass.sh<\/pre>\nYou will be asked to provide a username for the administrative user. If you just press ENTER, the username \u201cadmin\u201d will be selected. Afterwards, you will be asked to select and confirm a new password for the account.<\/p>\n
Let’s verify OLS is up and running https:\/\/your-ip-address:7080. You should be able to log into OLS WebAdmin. Now lets get WordPress installed and then we will configure OLS.<\/p>\n
<\/span>7. Install WordPress<\/span><\/h2>\nLets move to the directory where we want to download the WordPress core files:<\/p>\n
cd \/usr\/local\/lsws\/Example<\/pre>\nDownload WordPress using the wget command:<\/p>\n
wget https:\/\/wordpress.org\/latest.zip<\/pre>\nNow we will unzip the WordPress zip file:<\/p>\n
unzip latest.zip<\/pre>\nGive permission of the entire directory structure to the user that the web server runs under so that changes can be made through the WordPress interface:<\/p>\n
chown -R nobody:nogroup \/usr\/local\/lsws\/Example\/wordpress\/<\/pre>\nNow lets go into the \/wordpress directory:<\/p>\n
cd wordpress<\/pre>\nWe are going to configure WordPress to work with our current database we setup earlier. First we will rename the wp-config-sample.php to wp-config.php using the following command:<\/p>\n
mv wp-config-sample.php wp-config.php<\/pre>\nOpen the WordPress configuration file with your favorite text editor and change the database values with the ones you gave at the time of the database creation.<\/p>\n
nano wp-config.php<\/pre>\n\/\/ ** MySQL settings - You can get this info from your web host ** \/\/\r\n\/** The name of the database for WordPress *\/\r\ndefine('DB_NAME', 'wordpress');\r\n\r\n\/** MySQL database username *\/\r\ndefine('DB_USER', 'wordpressuser');\r\n\r\n\/** MySQL database password *\/\r\ndefine('DB_PASSWORD', 'your-password');\r\n\r\n\/** MySQL hostname *\/\r\ndefine('DB_HOST', 'localhost');<\/pre>\n