Actions

Help

Difference between revisions of "1-Click Install"

From OpenLiteSpeed Wiki

(Flags)
(Flags)
Line 43: Line 43:
 
* <code>--wordpressplus SITEDOMAIN</code> - Install, setup, and configure wordpress, eliminating the need to use the /wp-admin/wp-config.php setup.
 
* <code>--wordpressplus SITEDOMAIN</code> - Install, setup, and configure wordpress, eliminating the need to use the /wp-admin/wp-config.php setup.
 
* <code>--wordpresspath WORDPRESSPATH</code> - Use an existing wordpress installation if one is detected at <code>WORDPRESSPATH</code>, otherwise install wordpress there.
 
* <code>--wordpresspath WORDPRESSPATH</code> - Use an existing wordpress installation if one is detected at <code>WORDPRESSPATH</code>, otherwise install wordpress there.
* <code>--dbrootpassword(-r) [PASSWORD]</code> - Set the mysql server root password instead of using a random one.
+
* <code>--dbrootpassword(-r) [PASSWORD]</code> - Set the mysql/mariadb server root password instead of using a random one.
 
** If you omit <code>[PASSWORD]</code>, ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.  
 
** If you omit <code>[PASSWORD]</code>, ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.  
 
* <code>--dbname DATABASENAME</code> - Set the database name to be used by wordpress.
 
* <code>--dbname DATABASENAME</code> - Set the database name to be used by wordpress.
* <code>--dbuser DBUSERNAME</code> - Set the username of wordpress in mysql.
+
* <code>--dbuser DBUSERNAME</code> - Set the username of wordpress in mysql/mariadb.
* <code>--dbpassword [PASSWORD]</code> - Set the password of wordpress in mysql instead of using a random one.
+
* <code>--dbpassword [PASSWORD]</code> - Set the password of wordpress in mysql/mariadb instead of using a random one.
 
** If you omit <code>[PASSWORD]</code>, ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.  
 
** If you omit <code>[PASSWORD]</code>, ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.  
 
* <code>--listenport WORDPRESSPORT</code> - Set the listener port, default is 80.
 
* <code>--listenport WORDPRESSPORT</code> - Set the listener port, default is 80.
Line 56: Line 56:
 
* <code>--sitetitle WORDPRESSSITETITLE</code> - Set the wordpress site title, default is mySite.
 
* <code>--sitetitle WORDPRESSSITETITLE</code> - Set the wordpress site title, default is mySite.
 
* <code>--uninstall</code> - Uninstall OpenLiteSpeed and remove installation directory.
 
* <code>--uninstall</code> - Uninstall OpenLiteSpeed and remove installation directory.
* <code>--purgeall</code> - Uninstall OpenLiteSpeed, remove installation directory, and purge all data in mysql.
+
* <code>--purgeall</code> - Uninstall OpenLiteSpeed, remove installation directory, and purge all data in mysql/mariadb.
 
* <code>--version(-v)</code> Display version information.
 
* <code>--version(-v)</code> Display version information.
 
* <code>[ -h | --help ]</code> - Display usage.
 
* <code>[ -h | --help ]</code> - Display usage.

Revision as of 21:38, 29 August 2016

ols1clk is our one click script to install OpenLiteSpeed. It can also install WordPress, lsphp, and MySQL


Requirements

  • Operating System:
    • CentOS 5,6,7
    • Debian 7, 8, 9
    • Ubuntu 12,14,16
  • User Permission:
    • Must be run with superuser access (you may run it as root or use the sudo command).

Installation

  • Directly download ols1clk.sh.
  • Run the ols1clk script ./ols1clk.sh

OR

Run the following in the command line: wget --no-check-certificate https://raw.githubusercontent.com/litespeedtech/ols1clk/master/ols1clk.sh ; bash ols1clk.sh

OR

Run the following in the command line: bash <( curl -k https://raw.githubusercontent.com/litespeedtech/ols1clk/master/ols1clk.sh )

    • These will install OpenLiteSpeed and lsphp.
    • To install WordPress and (if not already present) MySQL as well, run ./ols1clk.sh -w.
  • Answer any prompts within the script and you're done!

CLI Installation

  • Simply run the following command with any necessary flags added in:

bash <(curl https://raw.githubusercontent.com/litespeedtech/ols1clk/master/ols1clk.sh) [ flags ]

Flags

  • --adminpassword(-a)[PASSWORD] - Set the webAdmin password for OpenLiteSpeed instead of a random one.
    • If you omit [PASSWORD], ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.
  • --email(-e) EMAIL - Set the email of the administrator, wordpress may require formatting such as test@example.com
  • --lsphp VERSION - Set the version of lsphp, such as 56. Currently we support '54 55 56 70'.
  • --wordpress(-w) - Install and setup wordpress, you will still need to access the /wp-admin/wp-config.php file to finish your wordpress installation.
  • --wordpressplus SITEDOMAIN - Install, setup, and configure wordpress, eliminating the need to use the /wp-admin/wp-config.php setup.
  • --wordpresspath WORDPRESSPATH - Use an existing wordpress installation if one is detected at WORDPRESSPATH, otherwise install wordpress there.
  • --dbrootpassword(-r) [PASSWORD] - Set the mysql/mariadb server root password instead of using a random one.
    • If you omit [PASSWORD], ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.
  • --dbname DATABASENAME - Set the database name to be used by wordpress.
  • --dbuser DBUSERNAME - Set the username of wordpress in mysql/mariadb.
  • --dbpassword [PASSWORD] - Set the password of wordpress in mysql/mariadb instead of using a random one.
    • If you omit [PASSWORD], ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.
  • --listenport WORDPRESSPORT - Set the listener port, default is 80.
  • --wpuser WORDPRESSUSER - Set the wordpress user for admin login to the wordpress dashboard, default is wpuser.
  • --wppassword [PASSWORD] - Set the wordpress password for admin login to the wordpress dashboard.
    • If you omit [PASSWORD], ols1clk will prompt you to provide a password. If you omit this flag, ols1clk will set a random password.
  • --wplang WORDPRESSLANGUAGE - Set the wordpress language, default is "en" for English. Check out our list of language codes supported by WordPress.
  • --sitetitle WORDPRESSSITETITLE - Set the wordpress site title, default is mySite.
  • --uninstall - Uninstall OpenLiteSpeed and remove installation directory.
  • --purgeall - Uninstall OpenLiteSpeed, remove installation directory, and purge all data in mysql/mariadb.
  • --version(-v) Display version information.
  • [ -h | --help ] - Display usage.

Examples

  1. bash ols1clk.sh -r rootpass -a 123456 --lsphpversion 70 -w
    • This will install OLS and WordPress, set the version of lsphp to 7.0, set the MySQL server root password to rootpass and the WebAdmin password to 123456.
  2. bash ols1clk.sh -r -a -w
    • This will install OLS and WordPress and ask for the MySQL server root password and the WebAdmin password during installation.
  3. bash ols1clk.sh -w
    • This will install OLS and WordPress using random passwords which will be written to a file when done.

FAQs

Why should I use this?

If you are trying to install WordPress on your own machine and have no idea where to start, this is your one stop shop! This will install the web server, and optionally MySQL and WordPress as well, giving you a running start. After the script finishes, you can get straight to configuring the web server or jump right into setting up WordPress.

Do I need super user access?

Yes, you need root access to use the script. You may use a super user account, or you may use sudo as well.

Where is OLS installed to?

/usr/local/lsws

Where is WordPress installed?

By default, WordPress is installed to: /usr/local/lsws/wordpress/

What PHP version is installed?

The latest version from our repositories. Currently, it is version 5.6.x

I tried installing OLS once and it threw a bunch of text at me saying there was an error!

This one click install script should automatically install any dependencies you are missing.

Can I use it for my existing WordPress installation?

Yes! All you need to do is point the script to the installation path using the --wordpresspath option.

Will it break my existing WordPress installation?

Open LiteSpeed cannot read .htaccess files. However, this script will parse your .htaccess file and try to extract the relevant rewrite rules. Depending on how complex the file is, there may be issues in the conversion.

What happens when there is an OLS update?

The Web Admin says there is an update for OLS! The script installs using your OS's package manager. Just run update in the package manager to update your installation. e.g. yum update