Browse Source

Remove Extra Space From Installation Messages

old-stable
Mitesh Shah 11 years ago
parent
commit
b89fec80c7
  1. 288
      usr/local/sbin/easyengine

288
usr/local/sbin/easyengine

@ -24,8 +24,8 @@ EasyEngine()
# Add TimeStamps In Install Log File # Add TimeStamps In Install Log File
echo &>> $INSTALLLOG echo &>> $INSTALLLOG
echo &>> $INSTALLLOG echo &>> $INSTALLLOG
echo -e "\033[34m EasyEngine Installation Started At [$(date)] \e[0m" &>> $INSTALLLOG echo -e "\033[34mEasyEngine Installation Started At [$(date)] \e[0m" &>> $INSTALLLOG
echo -e "\033[34m EasyEngine Command: $0 $@ \e[0m" &>> $INSTALLLOG echo -e "\033[34mEasyEngine Command: $0 $@ \e[0m" &>> $INSTALLLOG
# Check Auto Assume Yes Or No To Apt-Get # Check Auto Assume Yes Or No To Apt-Get
@ -49,7 +49,7 @@ OwnError()
PYTHONSOFTWARE() PYTHONSOFTWARE()
{ {
# Install Python Software Properties # Install Python Software Properties
echo -e "\033[34m Installing Python Software Properties... \e[0m" echo -e "\033[34mInstalling Python Software Properties... \e[0m"
sudo $EEAPTGET install python-software-properties \ sudo $EEAPTGET install python-software-properties \
|| OwnError "Unable To Install Python Software Properties" || OwnError "Unable To Install Python Software Properties"
} }
@ -57,7 +57,7 @@ PYTHONSOFTWARE()
NGINXREPO() NGINXREPO()
{ {
# Add Nginx Launchpad Repository # Add Nginx Launchpad Repository
echo -e "\033[34m Adding Brianmercer Nginx Launchpad Repository... \e[0m" echo -e "\033[34mAdding Brianmercer Nginx Launchpad Repository... \e[0m"
sudo add-apt-repository -y ppa:brianmercer/nginx \ sudo add-apt-repository -y ppa:brianmercer/nginx \
|| OwnError "Unable To Add Nginx Launchpad Repository" || OwnError "Unable To Add Nginx Launchpad Repository"
} }
@ -65,7 +65,7 @@ NGINXREPO()
PHPREPO() PHPREPO()
{ {
# Add PHP Launchpad Repository # Add PHP Launchpad Repository
echo -e "\033[34m Adding PHP5 Launchpad Repository... \e[0m" echo -e "\033[34mAdding PHP5 Launchpad Repository... \e[0m"
sudo add-apt-repository -y ppa:ondrej/php5 \ sudo add-apt-repository -y ppa:ondrej/php5 \
|| OwnError "Unable To Add PHP5 Launchpad Repository" || OwnError "Unable To Add PHP5 Launchpad Repository"
} }
@ -78,13 +78,13 @@ GPGKEY()
if [ $? -eq 0 ] if [ $? -eq 0 ]
then then
# Fix GPG Key Problems # Fix GPG Key Problems
echo -e "\033[34m Checking GPG Keys For Brianmercer Nginx Repository... \e[0m" echo -e "\033[34mChecking GPG Keys For Brianmercer Nginx Repository... \e[0m"
sudo apt-get update > /dev/null 2> /tmp/keymissing \ sudo apt-get update > /dev/null 2> /tmp/keymissing \
|| OwnError "Unable To Fix GPG Keys For Brianmercer Nginx Repository " || OwnError "Unable To Fix GPG Keys For Brianmercer Nginx Repository "
for key in $(grep "NO_PUBKEY" /tmp/keymissing |sed "s/.*NO_PUBKEY //") for key in $(grep "NO_PUBKEY" /tmp/keymissing |sed "s/.*NO_PUBKEY //")
do do
echo -e "\033[34m Processing key: $key \e[0m" echo -e "\033[34mProcessing key: $key \e[0m"
gpg --keyserver subkeys.pgp.net --recv $key && sudo gpg --export --armor $key | apt-key add - gpg --keyserver subkeys.pgp.net --recv $key && sudo gpg --export --armor $key | apt-key add -
done done
fi fi
@ -93,14 +93,14 @@ GPGKEY()
UPDATEAPT() UPDATEAPT()
{ {
# Update The APT Cache # Update The APT Cache
echo -e "\033[34m Updating APT Cache... \e[0m" echo -e "\033[34mUpdating APT Cache... \e[0m"
sudo apt-get update || OwnError "Unable To Update APT Cache" sudo apt-get update || OwnError "Unable To Update APT Cache"
} }
INSTALLNGINX() INSTALLNGINX()
{ {
# Install Nginx # Install Nginx
echo -e "\033[34m Installing Nginx... \e[0m" echo -e "\033[34mInstalling Nginx... \e[0m"
sudo $EEAPTGET install nginx-custom || OwnError "Unable To Install Nginx" sudo $EEAPTGET install nginx-custom || OwnError "Unable To Install Nginx"
} }
@ -134,7 +134,7 @@ EEMD5SUM()
COMMONNGINX() COMMONNGINX()
{ {
# Personal Settings For Nginx # Personal Settings For Nginx
echo -e "\033[34m Updating Nginx Configuration Files... \e[0m" echo -e "\033[34mUpdating Nginx Configuration Files... \e[0m"
grep "Easy Engine" /etc/nginx/nginx.conf &> /dev/null grep "Easy Engine" /etc/nginx/nginx.conf &> /dev/null
if [ $? -ne 0 ] if [ $? -ne 0 ]
@ -177,7 +177,7 @@ COMMONNGINX()
INSTALLPHP() INSTALLPHP()
{ {
# Install PHP5 # Install PHP5
echo -e "\033[34m Installing PHP5... \e[0m" echo -e "\033[34mInstalling PHP5... \e[0m"
sudo $EEAPTGET install php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET install php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached || OwnError "Unable To Install PHP5" php5-memcache memcached || OwnError "Unable To Install PHP5"
@ -186,7 +186,7 @@ INSTALLPHP()
COMMONPHP() COMMONPHP()
{ {
# Personal Settings For PHP # Personal Settings For PHP
echo -e "\033[34m Updating PHP Configuration Files... \e[0m" echo -e "\033[34mUpdating PHP Configuration Files... \e[0m"
grep "Easy Engine" /etc/php5/fpm/php.ini &> /dev/null grep "Easy Engine" /etc/php5/fpm/php.ini &> /dev/null
if [ $? -ne 0 ] if [ $? -ne 0 ]
@ -221,8 +221,8 @@ WP-CLI()
# Install WP-CLI # Install WP-CLI
if [ ! -d /usr/share/easyengine/wp-cli ] if [ ! -d /usr/share/easyengine/wp-cli ]
then then
echo -e "\033[31m WP-CLI Command Not Found ! \e[0m" echo -e "\033[31mWP-CLI Command Not Found ! \e[0m"
echo -e "\033[34m Installing WP-CLI, Please Wait... \e[0m" echo -e "\033[34mInstalling WP-CLI, Please Wait... \e[0m"
curl http://wp-cli.org/installer.sh | INSTALL_DIR='/usr/share/easyengine/wp-cli' bash \ curl http://wp-cli.org/installer.sh | INSTALL_DIR='/usr/share/easyengine/wp-cli' bash \
|| OwnError "Unable To Install WP-CLI" || OwnError "Unable To Install WP-CLI"
@ -232,6 +232,8 @@ WP-CLI()
# Add WP-CLI Auto Completion # Add WP-CLI Auto Completion
cp -vi /usr/share/easyengine/wp-cli/vendor/wp-cli/wp-cli/utils/wp-completion.bash /etc/bash_completion.d/ cp -vi /usr/share/easyengine/wp-cli/vendor/wp-cli/wp-cli/utils/wp-completion.bash /etc/bash_completion.d/
source /etc/bash_completion.d/wp-completion.bash source /etc/bash_completion.d/wp-completion.bash
else
echo -e "\033[34mAlready Installed WP-CLI (/usr/share/easyengine/wp-cli)... \e[0m"
fi fi
} }
@ -240,7 +242,7 @@ INSTALLPMA()
# Install PMA/phpMyAdmin # Install PMA/phpMyAdmin
if [ ! -d /var/www/shared/pma ] if [ ! -d /var/www/shared/pma ]
then then
echo -e "\033[34m Installing phpMyAdmin... \e[0m" echo -e "\033[34mInstalling phpMyAdmin... \e[0m"
# Setup PMA/phpMyAdmin # Setup PMA/phpMyAdmin
mkdir -p /var/www/shared/pma/ || OwnError "Unable To Create phpMyAdmin Directory: /var/www/shared/pma/" mkdir -p /var/www/shared/pma/ || OwnError "Unable To Create phpMyAdmin Directory: /var/www/shared/pma/"
@ -256,7 +258,7 @@ INSTALLPMA()
# Remove Unwanted Files # Remove Unwanted Files
rm -f /var/www/shared/pma/pma.tar.gz rm -f /var/www/shared/pma/pma.tar.gz
else else
echo -e "\033[34m Already Installed phpMyAdmin (/var/www/shared/pma)... \e[0m" echo -e "\033[34mAlready Installed phpMyAdmin (/var/www/shared/pma)... \e[0m"
fi fi
} }
@ -284,7 +286,7 @@ INSTALLMYSQL()
MYSQLINSTALLTWEAKS MYSQLINSTALLTWEAKS
# Install MySQL # Install MySQL
echo -e "\033[34m Installing MySQL... \e[0m" echo -e "\033[34mInstalling MySQL... \e[0m"
sudo $EEAPTGET install mysql-server mysqltuner \ sudo $EEAPTGET install mysql-server mysqltuner \
|| OwnError "Unable To Install MySQL" || OwnError "Unable To Install MySQL"
} }
@ -302,7 +304,7 @@ INSTALLPOSTFIX()
POSTFIXINSTALLTWEAKS POSTFIXINSTALLTWEAKS
# Install Postfix # Install Postfix
echo -e "\033[34m Installing Postfix... \e[0m" echo -e "\033[34mInstalling Postfix... \e[0m"
sudo $EEAPTGET install postfix || OwnError "Unable To Install Postfix" sudo $EEAPTGET install postfix || OwnError "Unable To Install Postfix"
} }
@ -313,7 +315,7 @@ INSTALLALL()
POSTFIXINSTALLTWEAKS POSTFIXINSTALLTWEAKS
# Install Nginx PHP5 MySQL Postfix # Install Nginx PHP5 MySQL Postfix
echo -e "\033[34m Installing Nginx PHP5 MySQL Postfix... \e[0m" echo -e "\033[34mInstalling Nginx PHP5 MySQL Postfix... \e[0m"
sudo $EEAPTGET install nginx-custom php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET install nginx-custom php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached mysql-server mysqltuner postfix \ php5-memcache memcached mysql-server mysqltuner postfix \
@ -325,14 +327,14 @@ INSTALLALL()
REMOVENGINX() REMOVENGINX()
{ {
# Remove Nginx # Remove Nginx
echo -e "\033[34m Removing Nginx... \e[0m" echo -e "\033[34mRemoving Nginx... \e[0m"
sudo $EEAPTGET remove nginx-custom nginx-common || OwnError "Unable To Remove Nginx" sudo $EEAPTGET remove nginx-custom nginx-common || OwnError "Unable To Remove Nginx"
} }
REMOVEPHP() REMOVEPHP()
{ {
# Remove PHP5 # Remove PHP5
echo -e "\033[34m Removing PHP5... \e[0m" echo -e "\033[34mRemoving PHP5... \e[0m"
sudo $EEAPTGET remove php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET remove php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached || OwnError "Unable To Remove PHP5" php5-memcache memcached || OwnError "Unable To Remove PHP5"
@ -341,21 +343,21 @@ REMOVEPHP()
REMOVEWPCLI() REMOVEWPCLI()
{ {
# Remove WP-CLI # Remove WP-CLI
echo -e "\033[34m Removing WP-CLI... \e[0m" echo -e "\033[34mRemoving WP-CLI... \e[0m"
rm -rf /usr/share/easyengine/wp-cli /usr/bin/wp /etc/bash_completion.d/wp-completion.bash || OwnError "Unable To Remove WP-CLI" rm -rf /usr/share/easyengine/wp-cli /usr/bin/wp /etc/bash_completion.d/wp-completion.bash || OwnError "Unable To Remove WP-CLI"
} }
REMOVEPMA() REMOVEPMA()
{ {
# Remove PMA/phpMyAdmin # Remove PMA/phpMyAdmin
echo -e "\033[34m Removing phpMyAdmin... \e[0m" echo -e "\033[34mRemoving phpMyAdmin... \e[0m"
rm -rf /var/www/shared/pma || OwnError "Unable To Remove phpMyAdmin" rm -rf /var/www/shared/pma || OwnError "Unable To Remove phpMyAdmin"
} }
REMOVEMYSQL() REMOVEMYSQL()
{ {
# Remove MySQL # Remove MySQL
echo -e "\033[34m Removing MySQL... \e[0m" echo -e "\033[34mRemoving MySQL... \e[0m"
sudo $EEAPTGET remove mysql-server mysqltuner \ sudo $EEAPTGET remove mysql-server mysqltuner \
|| OwnError "Unable To Remove MySQL" || OwnError "Unable To Remove MySQL"
} }
@ -363,14 +365,14 @@ REMOVEMYSQL()
REMOVEPOSTFIX() REMOVEPOSTFIX()
{ {
# Remove Postfix # Remove Postfix
echo -e "\033[34m Removing Postfix... \e[0m" echo -e "\033[34mRemoving Postfix... \e[0m"
sudo $EEAPTGET remove postfix || OwnError "Unable To Remove Postfix" sudo $EEAPTGET remove postfix || OwnError "Unable To Remove Postfix"
} }
REMOVEALL() REMOVEALL()
{ {
# Remove Nginx PHP5 MySQL Postfix # Remove Nginx PHP5 MySQL Postfix
echo -e "\033[34m Removing Nginx PHP5 MySQL Postfix... \e[0m" echo -e "\033[34mRemoving Nginx PHP5 MySQL Postfix... \e[0m"
sudo $EEAPTGET remove nginx-custom nginx-common php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET remove nginx-custom nginx-common php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached mysql-server mysqltuner postfix \ php5-memcache memcached mysql-server mysqltuner postfix \
@ -380,7 +382,7 @@ REMOVEALL()
AUTOREMOVE() AUTOREMOVE()
{ {
# Remove Unwanted Packages # Remove Unwanted Packages
echo -e "\033[34m Removing Unwanted Packages... \e[0m" echo -e "\033[34mRemoving Unwanted Packages... \e[0m"
sudo $EEAPTGET autoremove || OwnError "Unable To Auto Remove" sudo $EEAPTGET autoremove || OwnError "Unable To Auto Remove"
} }
@ -389,14 +391,14 @@ AUTOREMOVE()
PURGENGINX() PURGENGINX()
{ {
# Purge Nginx # Purge Nginx
echo -e "\033[34m Purge Nginx... \e[0m" echo -e "\033[34mPurge Nginx... \e[0m"
sudo $EEAPTGET purge nginx-custom nginx-common || OwnError "Unable To Purge Nginx" sudo $EEAPTGET purge nginx-custom nginx-common || OwnError "Unable To Purge Nginx"
} }
PURGEPHP() PURGEPHP()
{ {
# Purge PHP5 # Purge PHP5
echo -e "\033[34m Purge PHP5... \e[0m" echo -e "\033[34mPurge PHP5... \e[0m"
sudo $EEAPTGET purge php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET purge php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached || OwnError "Unable To Purge PHP5" php5-memcache memcached || OwnError "Unable To Purge PHP5"
@ -405,7 +407,7 @@ PURGEPHP()
PURGEMYSQL() PURGEMYSQL()
{ {
# Purge MySQL # Purge MySQL
echo -e "\033[34m Purge MySQL... \e[0m" echo -e "\033[34mPurge MySQL... \e[0m"
sudo $EEAPTGET purge mysql-server mysqltuner \ sudo $EEAPTGET purge mysql-server mysqltuner \
|| OwnError "Unable To Purge MySQL" || OwnError "Unable To Purge MySQL"
} }
@ -413,14 +415,14 @@ PURGEMYSQL()
PURGEPOSTFIX() PURGEPOSTFIX()
{ {
# Purge Postfix # Purge Postfix
echo -e "\033[34m Purge Postfix... \e[0m" echo -e "\033[34mPurge Postfix... \e[0m"
sudo $EEAPTGET purge postfix || OwnError "Unable To Purge Postfix" sudo $EEAPTGET purge postfix || OwnError "Unable To Purge Postfix"
} }
PURGEALL() PURGEALL()
{ {
# Purge Nginx PHP5 MySQL Postfix # Purge Nginx PHP5 MySQL Postfix
echo -e "\033[34m Removing Nginx PHP5 MySQL Postfix... \e[0m" echo -e "\033[34mRemoving Nginx PHP5 MySQL Postfix... \e[0m"
sudo $EEAPTGET purge nginx-custom nginx-common php5-common php5-mysqlnd php5-xmlrpc \ sudo $EEAPTGET purge nginx-custom nginx-common php5-common php5-mysqlnd php5-xmlrpc \
php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \ php5-curl php5-gd php5-cli php5-fpm php5-imap php5-mcrypt \
php5-memcache memcached mysql-server mysqltuner postfix \ php5-memcache memcached mysql-server mysqltuner postfix \
@ -438,7 +440,7 @@ EEGITINIT()
if [ ! -d .git ] if [ ! -d .git ]
then then
# Initialise Git # Initialise Git
echo -e "\033[34m Initialise Git On $EEGITDIR... \e[0m" echo -e "\033[34mInitialise Git On $EEGITDIR... \e[0m"
git init || OwnError "Unable To Initialise Git On $EEGITDIR" git init || OwnError "Unable To Initialise Git On $EEGITDIR"
fi fi
@ -460,7 +462,7 @@ EEGITCOMMIT()
if [ $? -ne 0 ] if [ $? -ne 0 ]
then then
# Git Commit Functionality # Git Commit Functionality
echo -e "\033[34m Take $GITDIR Configuration In Git Version Control... \e[0m" echo -e "\033[34mTake $GITDIR Configuration In Git Version Control... \e[0m"
# Add Newly Created Files && Commit It # Add Newly Created Files && Commit It
git add . && git commit -am "$EEGITMESSAGE" \ git add . && git commit -am "$EEGITMESSAGE" \
@ -532,7 +534,7 @@ MYSQLINFO()
# Display WPDBPREFIX Valid Characters Warning & Try Again # Display WPDBPREFIX Valid Characters Warning & Try Again
while [ $(echo $WPDBPREFIX | grep '[^[:alnum:] _]') ] while [ $(echo $WPDBPREFIX | grep '[^[:alnum:] _]') ]
do do
echo -e "\033[31m Warning: \033[34mTable Prefix Can Only Contain Numbers, Letters, And Underscores. \e[0m" echo -e "\033[31mWarning: \033[34mTable Prefix Can Only Contain Numbers, Letters, And Underscores. \e[0m"
read -p "Enter The MySQL Database Table Prefix [wp_]: " WPDBPREFIX read -p "Enter The MySQL Database Table Prefix [wp_]: " WPDBPREFIX
done done
@ -566,14 +568,14 @@ SYSTEMINFO()
CLIENTMAXBODYSIZE=$(grep client_max_body_size /etc/nginx/nginx.conf | cut -d' ' -f2 | cut -d';' -f1) CLIENTMAXBODYSIZE=$(grep client_max_body_size /etc/nginx/nginx.conf | cut -d' ' -f2 | cut -d';' -f1)
NGINXALLOWEDIPADD=$(grep ^allow /etc/nginx/common/allowed_ip.conf | cut -d' ' -f2 | cut -d';' -f1 | tr '\n' ' ') NGINXALLOWEDIPADD=$(grep ^allow /etc/nginx/common/allowed_ip.conf | cut -d' ' -f2 | cut -d';' -f1 | tr '\n' ' ')
echo -e "\033[34m Nginx ($NGINXVER) Information:\n \e[0m" echo -e "\033[34mNginx ($NGINXVER) Information:\n \e[0m"
echo -e "\033[34m Nginx User:\t\t\t \033[37m $NGINXUSER \e[0m" echo -e "\033[34mNginx User:\t\t\t \033[37m $NGINXUSER \e[0m"
echo -e "\033[34m Nginx worker_processes:\t \033[37m $NGINXPROCESSES \e[0m" echo -e "\033[34mNginx worker_processes:\t \033[37m $NGINXPROCESSES \e[0m"
echo -e "\033[34m Nginx worker_connections:\t \033[37m $NGINXCONNECTIONS \e[0m" echo -e "\033[34mNginx worker_connections:\t \033[37m $NGINXCONNECTIONS \e[0m"
echo -e "\033[34m Nginx keepalive_timeout:\t \033[37m $NGINXKEEPALIVE \e[0m" echo -e "\033[34mNginx keepalive_timeout:\t \033[37m $NGINXKEEPALIVE \e[0m"
echo -e "\033[34m Nginx fastcgi_read_timeout:\t \033[37m $FASTCGITIMEOUT \e[0m" echo -e "\033[34mNginx fastcgi_read_timeout:\t \033[37m $FASTCGITIMEOUT \e[0m"
echo -e "\033[34m Nginx client_max_body_size:\t \033[37m $CLIENTMAXBODYSIZE \e[0m" echo -e "\033[34mNginx client_max_body_size:\t \033[37m $CLIENTMAXBODYSIZE \e[0m"
echo -e "\033[34m Nginx Allowed IP Address:\t \033[37m $NGINXALLOWEDIPADD \e[0m" echo -e "\033[34mNginx Allowed IP Address:\t \033[37m $NGINXALLOWEDIPADD \e[0m"
# PHP Information # PHP Information
# Collect Information From php.ini # Collect Information From php.ini
@ -595,42 +597,42 @@ SYSTEMINFO()
PHPREQUESTTERMINATE=$(grep ^request_terminate_timeout /etc/php5/fpm/pool.d/www.conf | cut -d'=' -f2| cut -d' ' -f2) PHPREQUESTTERMINATE=$(grep ^request_terminate_timeout /etc/php5/fpm/pool.d/www.conf | cut -d'=' -f2| cut -d' ' -f2)
PHPFASTCGIREQUEST=$(grep ^listen /etc/php5/fpm/pool.d/www.conf | cut -d'=' -f2| cut -d' ' -f2) PHPFASTCGIREQUEST=$(grep ^listen /etc/php5/fpm/pool.d/www.conf | cut -d'=' -f2| cut -d' ' -f2)
echo -e "\033[34m \n\n PHP ($PHPVER) Information:\n \e[0m" echo -e "\033[34m\n\n PHP ($PHPVER) Information:\n \e[0m"
echo -e "\033[34m PHP User:\t\t\t \033[37m $PHPUSER \e[0m" echo -e "\033[34mPHP User:\t\t\t \033[37m $PHPUSER \e[0m"
echo -e "\033[34m PHP expose_php:\t\t \033[37m $PHPEXPOSE \e[0m" echo -e "\033[34mPHP expose_php:\t\t \033[37m $PHPEXPOSE \e[0m"
echo -e "\033[34m PHP post_max_size:\t\t \033[37m $PHPPOSTMAXSIZE \e[0m" echo -e "\033[34mPHP post_max_size:\t\t \033[37m $PHPPOSTMAXSIZE \e[0m"
echo -e "\033[34m PHP upload_max_filesize:\t \033[37m $PHPUPLOADMAXFSIZE \e[0m" echo -e "\033[34mPHP upload_max_filesize:\t \033[37m $PHPUPLOADMAXFSIZE \e[0m"
echo -e "\033[34m PHP max_execution_time:\t \033[37m $PHPMAXEXECUTIONTIME \e[0m" echo -e "\033[34mPHP max_execution_time:\t \033[37m $PHPMAXEXECUTIONTIME \e[0m"
echo -e "\033[34m\n PHP ping.path:\t\t\t \033[37m $PHPPINGPATH \e[0m" echo -e "\033[34m\n PHP ping.path:\t\t\t \033[37m $PHPPINGPATH \e[0m"
echo -e "\033[34m PHP pm.status_path:\t\t \033[37m $PHPSTATUSPATH \e[0m" echo -e "\033[34mPHP pm.status_path:\t\t \033[37m $PHPSTATUSPATH \e[0m"
echo -e "\033[34m PHP pm.max_requests:\t\t \033[37m $PMMAXREQUEST \e[0m" echo -e "\033[34mPHP pm.max_requests:\t\t \033[37m $PMMAXREQUEST \e[0m"
echo -e "\033[34m PHP pm.max_children:\t\t \033[37m $PMMAXCHILDREN \e[0m" echo -e "\033[34mPHP pm.max_children:\t\t \033[37m $PMMAXCHILDREN \e[0m"
echo -e "\033[34m PHP pm.start_servers:\t\t \033[37m $PMSTARTSERVERS \e[0m" echo -e "\033[34mPHP pm.start_servers:\t\t \033[37m $PMSTARTSERVERS \e[0m"
echo -e "\033[34m PHP pm.min_spare_servers:\t \033[37m $PMMINSPARESERVERS \e[0m" echo -e "\033[34mPHP pm.min_spare_servers:\t \033[37m $PMMINSPARESERVERS \e[0m"
echo -e "\033[34m PHP pm.max_spare_servers:\t \033[37m $PMMAXSPARESERVERS \e[0m" echo -e "\033[34mPHP pm.max_spare_servers:\t \033[37m $PMMAXSPARESERVERS \e[0m"
echo -e "\033[34m PHP request_terminate_timeout:\t \033[37m $PHPREQUESTTERMINATE \e[0m" echo -e "\033[34mPHP request_terminate_timeout:\t \033[37m $PHPREQUESTTERMINATE \e[0m"
echo -e "\033[34m PHP Fastcgi Listen:\t\t \033[37m $PHPFASTCGIREQUEST \e[0m" echo -e "\033[34mPHP Fastcgi Listen:\t\t \033[37m $PHPFASTCGIREQUEST \e[0m"
} }
NGINXRELOAD() NGINXRELOAD()
{ {
# Reload Nginx Configuration # Reload Nginx Configuration
echo -e "\033[34m Reloading Nginx Configuration, Please Wait... \e[0m" echo -e "\033[34mReloading Nginx Configuration, Please Wait... \e[0m"
nginx -t && service nginx reload || OwnError "Unable To Reload Nginx" nginx -t && service nginx reload || OwnError "Unable To Reload Nginx"
} }
NGINXRESTART() NGINXRESTART()
{ {
# Test & Reload Nginx # Test & Reload Nginx
echo -e "\033[34m Restarting Nginx Configuration, Please Wait... \e[0m" echo -e "\033[34mRestarting Nginx Configuration, Please Wait... \e[0m"
nginx -t && service nginx restart || OwnError "Unable To Restart Nginx" nginx -t && service nginx restart || OwnError "Unable To Restart Nginx"
} }
PHPRESTART() PHPRESTART()
{ {
# Reload PHP # Reload PHP
echo -e "\033[34m Restarting PHP5-FPM Configuration, Please Wait... \e[0m" echo -e "\033[34mRestarting PHP5-FPM Configuration, Please Wait... \e[0m"
service php5-fpm restart || OwnError "Unable To Restart PHP5-FPM" service php5-fpm restart || OwnError "Unable To Restart PHP5-FPM"
} }
@ -655,7 +657,7 @@ EESITENAME()
NGINXSYMBOLICLINK() NGINXSYMBOLICLINK()
{ {
# Creating Symbolic Link # Creating Symbolic Link
echo -e "\033[34m Creating Symbolic Link For $DOMAIN \e[0m" echo -e "\033[34mCreating Symbolic Link For $DOMAIN \e[0m"
ln -s /etc/nginx/sites-available/$DOMAIN /etc/nginx/sites-enabled/ \ ln -s /etc/nginx/sites-available/$DOMAIN /etc/nginx/sites-enabled/ \
|| OwnError "Unable To Create Symbolic Link For $DOMAIN" || OwnError "Unable To Create Symbolic Link For $DOMAIN"
} }
@ -668,7 +670,7 @@ EEDOMAINSETUP()
if [ $? -ne 0 ] if [ $? -ne 0 ]
then then
# Creating Website $DOMAIN # Creating Website $DOMAIN
echo -e "\033[34m Creating $DOMAIN, Please Wait... \e[0m" echo -e "\033[34mCreating $DOMAIN, Please Wait... \e[0m"
sed "s/example.com/$DOMAIN/g" \ sed "s/example.com/$DOMAIN/g" \
/usr/share/easyengine/nginx/$NGINXCONF \ /usr/share/easyengine/nginx/$NGINXCONF \
> /etc/nginx/sites-available/$DOMAIN \ > /etc/nginx/sites-available/$DOMAIN \
@ -678,12 +680,12 @@ EEDOMAINSETUP()
NGINXSYMBOLICLINK NGINXSYMBOLICLINK
# Creating Htdocs & Logs Directory # Creating Htdocs & Logs Directory
echo -e "\033[34m Creating htdocs & logs Directory \e[0m" echo -e "\033[34mCreating htdocs & logs Directory \e[0m"
mkdir -p /var/www/$DOMAIN/htdocs && mkdir -p /var/www/$DOMAIN/logs \ mkdir -p /var/www/$DOMAIN/htdocs && mkdir -p /var/www/$DOMAIN/logs \
|| OwnError "Unable To Create htdocs & logs Directory" || OwnError "Unable To Create htdocs & logs Directory"
# Creating Symbolic Links For Logs # Creating Symbolic Links For Logs
echo -e "\033[34m Creating Symbolic Link For Logs \e[0m" echo -e "\033[34mCreating Symbolic Link For Logs \e[0m"
ln -s /var/log/nginx/$DOMAIN.access.log /var/www/$DOMAIN/logs/access.log \ ln -s /var/log/nginx/$DOMAIN.access.log /var/www/$DOMAIN/logs/access.log \
&& ln -s /var/log/nginx/$DOMAIN.error.log /var/www/$DOMAIN/logs/error.log \ && ln -s /var/log/nginx/$DOMAIN.error.log /var/www/$DOMAIN/logs/error.log \
|| OwnError "Unable To Create Symbolic Link For $DOMAIN Logs" || OwnError "Unable To Create Symbolic Link For $DOMAIN Logs"
@ -695,7 +697,7 @@ EEDOMAINSETUP()
EEWPSETUP() EEWPSETUP()
{ {
# Download Latest Wordpress # Download Latest Wordpress
echo -e "\033[34m Downloading WordPress, Please Wait... \e[0m" echo -e "\033[34mDownloading WordPress, Please Wait... \e[0m"
wget -cO /var/www/$DOMAIN/htdocs/latest.tar.gz \ wget -cO /var/www/$DOMAIN/htdocs/latest.tar.gz \
http://wordpress.org/latest.tar.gz \ http://wordpress.org/latest.tar.gz \
|| OwnError "Unable To Download WordPress" || OwnError "Unable To Download WordPress"
@ -738,7 +740,7 @@ EEWPSETUP()
EEWPDBSETUP() EEWPDBSETUP()
{ {
# Get WordPress Site Title # Get WordPress Site Title
echo -e "\033[34m WordPress Information Required... \e[0m" echo -e "\033[34mWordPress Information Required... \e[0m"
read -p "Site Title [$DOMAIN]: " SITETITLE read -p "Site Title [$DOMAIN]: " SITETITLE
@ -764,7 +766,7 @@ EEWPDBSETUP()
# Cross Check Blank WordPress Admin Password # Cross Check Blank WordPress Admin Password
while [ -z $WPADMINPASS ] while [ -z $WPADMINPASS ]
do do
echo -e "\033[31m \n Warning: \033[34m WordPress Admin Password Should Not Blank \e[0m" echo -e "\033[31m\nWarning: \033[34mWordPress Admin Password Should Not Blank \e[0m"
# Turn Off Echo For Passwords # Turn Off Echo For Passwords
stty -echo stty -echo
@ -778,12 +780,12 @@ EEWPDBSETUP()
# Cross Check Blank WordPress Admin Email Address # Cross Check Blank WordPress Admin Email Address
while [ -z $WPADMINEMAIL ] while [ -z $WPADMINEMAIL ]
do do
echo -e "\033[31m Warning: \033[34m WordPress Admin Email Should Not Blank \e[0m" echo -e "\033[31mWarning: \033[34mWordPress Admin Email Should Not Blank \e[0m"
read -p "Email: " WPADMINEMAIL read -p "Email: " WPADMINEMAIL
done done
# Create WordPress Tables # Create WordPress Tables
echo -e "\033[34m Setting Up WordPress, Please Wait... \e[0m" echo -e "\033[34mSetting Up WordPress, Please Wait... \e[0m"
cd /var/www/$DOMAIN/htdocs || OwnError "Unable To Change Directory To Install WordPress" cd /var/www/$DOMAIN/htdocs || OwnError "Unable To Change Directory To Install WordPress"
wp core install --url=$DOMAIN --title="$SITETITLE" \ wp core install --url=$DOMAIN --title="$SITETITLE" \
--admin_name=$WPADMINUSER --admin_password=$WPADMINPASS --admin_email=$WPADMINEMAIL \ --admin_name=$WPADMINUSER --admin_password=$WPADMINPASS --admin_email=$WPADMINEMAIL \
@ -796,7 +798,7 @@ EEPERMISSION()
PHPUSERINFO PHPUSERINFO
# Change Ownership # Change Ownership
echo -e "\033[34m Changing Ownership \e[0m" echo -e "\033[34mChanging Ownership \e[0m"
chown -R $PHPUSER:$PHPUSER /var/www/$DOMAIN/ || OwnError "Unable To Change Ownership For $DOMAIN" chown -R $PHPUSER:$PHPUSER /var/www/$DOMAIN/ || OwnError "Unable To Change Ownership For $DOMAIN"
# Reload Nginx Configuration # Reload Nginx Configuration
@ -862,7 +864,7 @@ TOTALCACHENGINX()
{ {
# Installing W3 Total Cache # Installing W3 Total Cache
cd /var/www/$DOMAIN/htdocs/ cd /var/www/$DOMAIN/htdocs/
echo -e "\033[34m Installing W3 Total Cache Plugin, Please Wait... \e[0m" echo -e "\033[34mInstalling W3 Total Cache Plugin, Please Wait... \e[0m"
wp plugin install w3-total-cache || OwnError "Unable To Install W3 Total Cache Plugin" wp plugin install w3-total-cache || OwnError "Unable To Install W3 Total Cache Plugin"
# Activate W3 Total Cache # Activate W3 Total Cache
@ -876,7 +878,7 @@ SUPERCACHENGINX()
{ {
# Installing WP Super Cache # Installing WP Super Cache
cd /var/www/$DOMAIN/htdocs/ cd /var/www/$DOMAIN/htdocs/
echo -e "\033[34m Installing WP Super Cache Plugin, Please Wait... \e[0m" echo -e "\033[34mInstalling WP Super Cache Plugin, Please Wait... \e[0m"
wp plugin install wp-super-cache || OwnError "Unable To Install WP Super Cache Plugin" wp plugin install wp-super-cache || OwnError "Unable To Install WP Super Cache Plugin"
# Activate WP Super Cache # Activate WP Super Cache
@ -887,7 +889,7 @@ NGINXHELPER()
{ {
# Installing Nginx Helper # Installing Nginx Helper
cd /var/www/$DOMAIN/htdocs/ cd /var/www/$DOMAIN/htdocs/
echo -e "\033[34m Installing Nginx Helper Plugin, Please Wait... \e[0m" echo -e "\033[34mInstalling Nginx Helper Plugin, Please Wait... \e[0m"
wp plugin install nginx-helper || OwnError "Unable To Install Nginx Helper" wp plugin install nginx-helper || OwnError "Unable To Install Nginx Helper"
# Activate Nginx Helper # Activate Nginx Helper
@ -931,7 +933,7 @@ REMOVEDB()
|| OwnError "Unable To Drop $WPDBNAME Database" || OwnError "Unable To Drop $WPDBNAME Database"
else else
# User Denied Messages # User Denied Messages
echo -e "\033[31m User Denied To Drop $WPDBNAME Database. \e[0m" echo -e "\033[31mUser Denied To Drop $WPDBNAME Database. \e[0m"
fi fi
} }
@ -947,7 +949,7 @@ REMOVEFILES()
rm -rf /var/www/$DOMAIN || OwnError "Unable To Remove $DOMAIN Webroot" rm -rf /var/www/$DOMAIN || OwnError "Unable To Remove $DOMAIN Webroot"
else else
# User Denied Messages # User Denied Messages
echo -e "\033[31m User Denied To Remove $DOMAIN Webroot. \e[0m" echo -e "\033[31mUser Denied To Remove $DOMAIN Webroot. \e[0m"
fi fi
} }
@ -964,7 +966,7 @@ REMOVENGINXCONF()
|| OwnError "Unable To Remove $DOMAIN Nginx Configuration" || OwnError "Unable To Remove $DOMAIN Nginx Configuration"
else else
# User Denied Messages # User Denied Messages
echo -e "\033[31m User Denied To Remove $DOMAIN Nginx Configuration. \e[0m" echo -e "\033[31mUser Denied To Remove $DOMAIN Nginx Configuration. \e[0m"
fi fi
} }
@ -1023,7 +1025,7 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx Successfully Installed \e[0m" echo -e "\033[34mNginx Successfully Installed \e[0m"
elif [ "$3" = "php" ] elif [ "$3" = "php" ]
then then
@ -1057,7 +1059,7 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m PHP5 & WP-CLI Successfully Installed \e[0m" echo -e "\033[34mPHP5 & WP-CLI Successfully Installed \e[0m"
elif [ "$3" = "pma" ] elif [ "$3" = "pma" ]
then then
@ -1070,7 +1072,7 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m phpMyAdmin Successfully Installed \e[0m" echo -e "\033[34mphpMyAdmin Successfully Installed \e[0m"
elif [ "$3" = "mysql" ] elif [ "$3" = "mysql" ]
then then
@ -1086,7 +1088,7 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m MySQL Successfully Installed \e[0m" echo -e "\033[34mMySQL Successfully Installed \e[0m"
elif [ "$3" = "postfix" ] elif [ "$3" = "postfix" ]
then then
@ -1102,7 +1104,7 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m Postfix Successfully Installed \e[0m" echo -e "\033[34mPostfix Successfully Installed \e[0m"
elif [ "$3" = "all" ] || [ "$3" = "" ] elif [ "$3" = "all" ] || [ "$3" = "" ]
then then
@ -1164,8 +1166,8 @@ then
EEGITINIT EEGITINIT
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Installed \e[0m" echo -e "\033[34mNginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Installed \e[0m"
echo -e "\033[34m You Can Now Create Your First WordPress Site Powered By Nginx Using: \e[0m" echo -e "\033[34mYou Can Now Create Your First WordPress Site Powered By Nginx Using: \e[0m"
echo -e "\033[37m ee site create wp basic $(hostname -f) \e[0m" echo -e "\033[37m ee site create wp basic $(hostname -f) \e[0m"
fi fi
@ -1184,7 +1186,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx Successfully Removed \e[0m" echo -e "\033[34mNginx Successfully Removed \e[0m"
elif [ "$3" = "php" ] elif [ "$3" = "php" ]
then then
@ -1197,7 +1199,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m PHP5 & WP-CLI Successfully Removed \e[0m" echo -e "\033[34mPHP5 & WP-CLI Successfully Removed \e[0m"
elif [ "$3" = "pma" ] elif [ "$3" = "pma" ]
then then
@ -1206,7 +1208,7 @@ then
REMOVEPMA REMOVEPMA
# Display Success Message # Display Success Message
echo -e "\033[34m phpMyAdmin Successfully Removed \e[0m" echo -e "\033[34mphpMyAdmin Successfully Removed \e[0m"
elif [ "$3" = "mysql" ] elif [ "$3" = "mysql" ]
then then
@ -1218,7 +1220,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m MySQL Successfully Removed \e[0m" echo -e "\033[34mMySQL Successfully Removed \e[0m"
elif [ "$3" = "postfix" ] elif [ "$3" = "postfix" ]
then then
@ -1230,7 +1232,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m Postfix Successfully Removed \e[0m" echo -e "\033[34mPostfix Successfully Removed \e[0m"
elif [ "$3" = "all" ] || [ "$3" = "" ] elif [ "$3" = "all" ] || [ "$3" = "" ]
then then
@ -1244,7 +1246,7 @@ then
REMOVEPMA REMOVEPMA
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Removed \e[0m" echo -e "\033[34mNginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Removed \e[0m"
fi fi
@ -1262,7 +1264,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx Successfully Purged \e[0m" echo -e "\033[34mNginx Successfully Purged \e[0m"
elif [ "$3" = "php" ] elif [ "$3" = "php" ]
then then
@ -1275,7 +1277,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m PHP5 & WP-CLI Successfully Purged \e[0m" echo -e "\033[34mPHP5 & WP-CLI Successfully Purged \e[0m"
elif [ "$3" = "pma" ] elif [ "$3" = "pma" ]
then then
@ -1284,7 +1286,7 @@ then
REMOVEPMA REMOVEPMA
# Display Success Message # Display Success Message
echo -e "\033[34m phpMyAdmin Successfully Purged \e[0m" echo -e "\033[34mphpMyAdmin Successfully Purged \e[0m"
elif [ "$3" = "mysql" ] elif [ "$3" = "mysql" ]
then then
@ -1296,7 +1298,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m MySQL Successfully Purged \e[0m" echo -e "\033[34mMySQL Successfully Purged \e[0m"
elif [ "$3" = "postfix" ] elif [ "$3" = "postfix" ]
then then
@ -1308,7 +1310,7 @@ then
AUTOREMOVE AUTOREMOVE
# Display Success Message # Display Success Message
echo -e "\033[34m Postfix Successfully Purged \e[0m" echo -e "\033[34mPostfix Successfully Purged \e[0m"
elif [ "$3" = "all" ] || [ "$3" = "" ] elif [ "$3" = "all" ] || [ "$3" = "" ]
then then
@ -1322,7 +1324,7 @@ then
REMOVEPMA REMOVEPMA
# Display Success Message # Display Success Message
echo -e "\033[34m Nginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Purged \e[0m" echo -e "\033[34mNginx PHP5 WP-CLI MySQL Postfix phpMyAdmin Successfully Purged \e[0m"
fi fi
@ -1345,7 +1347,7 @@ then
then then
# Display The List Of Enabled Websites # Display The List Of Enabled Websites
echo -e "\033[34m Display The List Of Enabled Websites: \e[0m" echo -e "\033[34mDisplay The List Of Enabled Websites: \e[0m"
ls /etc/nginx/sites-enabled/ \ ls /etc/nginx/sites-enabled/ \
|| OwnError "Unable To Display The List Of Enabled Websites" || OwnError "Unable To Display The List Of Enabled Websites"
@ -1353,7 +1355,7 @@ then
then then
# Display The List Of Available Sites # Display The List Of Available Sites
echo -e "\033[34m Display The List Of Available Websites: \e[0m" echo -e "\033[34mDisplay The List Of Available Websites: \e[0m"
ls /etc/nginx/sites-available/ \ ls /etc/nginx/sites-available/ \
|| OwnError "Unable To Display The List Of Available Websites" || OwnError "Unable To Display The List Of Available Websites"
@ -1372,7 +1374,7 @@ then
then then
# Display The Specific Site Configuration # Display The Specific Site Configuration
echo -e "\033[34m Display Nginx Configuration For $DOMAIN \e[0m" echo -e "\033[34mDisplay Nginx Configuration For $DOMAIN \e[0m"
cat /etc/nginx/sites-available/$DOMAIN \ cat /etc/nginx/sites-available/$DOMAIN \
|| OwnError "Unable To Display Nginx Configuration For $DOMAIN" || OwnError "Unable To Display Nginx Configuration For $DOMAIN"
@ -1399,7 +1401,7 @@ then
EEGITCOMMIT EEGITCOMMIT
# Display Success Message # Display Success Message
echo -e "\033[34m http://$DOMAIN Domain Successfully Created \e[0m" echo -e "\033[34mhttp://$DOMAIN Domain Successfully Created \e[0m"
elif [ "$3" = "php" ] elif [ "$3" = "php" ]
then then
@ -1419,7 +1421,7 @@ then
EEGITCOMMIT EEGITCOMMIT
# Display Success Message # Display Success Message
echo -e "\033[34m http://$DOMAIN Domain Successfully Created \e[0m" echo -e "\033[34mhttp://$DOMAIN Domain Successfully Created \e[0m"
elif [ "$3" = "wp" ] elif [ "$3" = "wp" ]
then then
@ -1441,7 +1443,7 @@ then
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "w3tc" ] elif [ "$4" = "w3tc" ]
then then
@ -1461,13 +1463,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpsc" ] elif [ "$4" = "wpsc" ]
then then
@ -1487,13 +1489,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m WP Super Cache: http://$DOMAIN/wp-admin/options-general.php?page=wpsupercache \e[0m" echo -e "\033[34mWP Super Cache: http://$DOMAIN/wp-admin/options-general.php?page=wpsupercache \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpfc" ] elif [ "$4" = "wpfc" ]
then then
@ -1513,14 +1515,14 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m Nginx Helper: http://$DOMAIN/wp-admin/options-general.php?page=nginx \e[0m" echo -e "\033[34mNginx Helper: http://$DOMAIN/wp-admin/options-general.php?page=nginx \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
fi fi
@ -1549,7 +1551,7 @@ then
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "w3tc" ] elif [ "$4" = "w3tc" ]
then then
@ -1575,13 +1577,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpsc" ] elif [ "$4" = "wpsc" ]
then then
@ -1607,13 +1609,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m WP Super Cache: http://$DOMAIN/wp-admin/network/settings.php?page=wpsupercache \e[0m" echo -e "\033[34mWP Super Cache: http://$DOMAIN/wp-admin/network/settings.php?page=wpsupercache \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpfc" ] elif [ "$4" = "wpfc" ]
then then
@ -1639,14 +1641,14 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m Nginx Helper: http://$DOMAIN/wp-admin/network/settings.php?page=nginx \e[0m" echo -e "\033[34mNginx Helper: http://$DOMAIN/wp-admin/network/settings.php?page=nginx \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
fi fi
@ -1676,7 +1678,7 @@ then
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "w3tc" ] elif [ "$4" = "w3tc" ]
then then
@ -1703,13 +1705,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpsc" ] elif [ "$4" = "wpsc" ]
then then
@ -1736,13 +1738,13 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m WP Super Cache: http://$DOMAIN/wp-admin/network/settings.php?page=wpsupercache \e[0m" echo -e "\033[34mWP Super Cache: http://$DOMAIN/wp-admin/network/settings.php?page=wpsupercache \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
elif [ "$4" = "wpfc" ] elif [ "$4" = "wpfc" ]
then then
@ -1769,14 +1771,14 @@ then
# Display WordPress Plugin Configuration Message # Display WordPress Plugin Configuration Message
echo echo
echo -e "\033[34m Please Configure The Following Settings... \e[0m" echo -e "\033[34mPlease Configure The Following Settings... \e[0m"
echo -e "\033[34m Permalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m" echo -e "\033[34mPermalink Settings: http://$DOMAIN/wp-admin/options-permalink.php \e[0m"
echo -e "\033[34m Nginx Helper: http://$DOMAIN/wp-admin/network/settings.php?page=nginx \e[0m" echo -e "\033[34mNginx Helper: http://$DOMAIN/wp-admin/network/settings.php?page=nginx \e[0m"
echo -e "\033[34m W3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m" echo -e "\033[34mW3 Total Cache: http://$DOMAIN/wp-admin/network/admin.php?page=w3tc_general \e[0m"
# Display Success Message # Display Success Message
echo echo
echo -e "\033[34m Successfully Created New $3 $4 Website: http://$DOMAIN \e[0m" echo -e "\033[34mSuccessfully Created New $3 $4 Website: http://$DOMAIN \e[0m"
fi fi
fi fi
@ -1807,7 +1809,7 @@ then
EESITENAME EESITENAME
# Remove Symbolic Link # Remove Symbolic Link
echo -e "\033[34m Removing Symbolic Link For $DOMAIN \e[0m" echo -e "\033[34mRemoving Symbolic Link For $DOMAIN \e[0m"
rm /etc/nginx/sites-enabled/$DOMAIN \ rm /etc/nginx/sites-enabled/$DOMAIN \
|| OwnError "Unable To Remove Symbolic Link For $DOMAIN" || OwnError "Unable To Remove Symbolic Link For $DOMAIN"

Loading…
Cancel
Save