Skip to content

Commit fd9ecfa

Browse files
author
shital.rtcamp
committed
Merge branch 'python' of https://github.com/rtCamp/easyengine into python
2 parents d6e4554 + d97fdcf commit fd9ecfa

File tree

5 files changed

+23
-16
lines changed

5 files changed

+23
-16
lines changed

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,22 @@ EasyEngine (ee) is a linux shell-script collection, which makes it easy to manag
1919
- Ubuntu 12.04 & 14.04
2020
- Debian 7
2121

22+
### This is Beta version. Donot Try on Production/Live servers
23+
2224
## Quick Start
2325

2426
```bash
25-
wget -qO ee rt.cx/ee && sudo bash ee # install easyengine
27+
wget http://rt.cx/eebeta && sudo bash install # install easyengine 3.0.0-beta
2628
sudo ee site create example.com --wp # Install required packages & setup WordPress on example.com
2729
```
2830

2931
## Update EasyEngine
3032

3133

32-
Update Procedure For EasyEngine
34+
Update Procedure For EasyEngine to version 3.0.0-beta
3335

3436
```bash
35-
wget -qO eeup http://rt.cx/eeup && sudo bash eeup
37+
wget http://rt.cx/eebeta && sudo bash install
3638
```
3739

3840
## More Site Creation Commands

config/bash_completion.d/ee_auto.rc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,17 @@ _ee_complete()
106106
case "$mprev" in
107107
# HANDLE EVERYTHING AFTER THE THIRD LEVEL NAMESPACE
108108

109-
"create" | "update")
109+
"create")
110110
COMPREPLY=( $(compgen \
111111
-W "--html --php --mysql --wp --wpsubdir --wpsubdomain --w3tc --wpfc --wpsc" \
112112
-- $cur) )
113113
;;
114+
115+
"update")
116+
COMPREPLY=( $(compgen \
117+
-W "--password --php --mysql --wp --wpsubdir --wpsubdomain --w3tc --wpfc --wpsc" \
118+
-- $cur) )
119+
;;
114120
"delete")
115121
COMPREPLY=( $(compgen \
116122
-W "--db --files --all" \

ee/cli/plugins/site_functions.py

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
import sys
1212
import getpass
1313
import glob
14+
import re
1415

1516

1617
def setupdomain(self, data):
@@ -76,7 +77,7 @@ def setupdatabase(self, data):
7677

7778
if prompt_dbname == 'True' or prompt_dbname == 'true':
7879
try:
79-
ee_db_name = input('Enter the MySQL database name [{0}]:'
80+
ee_db_name = input('Enter the MySQL database name [{0}]: '
8081
.format(ee_replace_dot))
8182
except EOFError as e:
8283
Log.debug(self, "{0}".format(e))
@@ -102,12 +103,11 @@ def setupdatabase(self, data):
102103
ee_db_password = ee_random
103104

104105
if len(ee_db_username) > 16:
105-
Log.info(self, 'Autofix MySQL username (ERROR 1470 (HY000)),'
106-
' please wait')
106+
Log.debug(self, 'Autofix MySQL username (ERROR 1470 (HY000)),'
107+
' please wait')
107108
ee_random10 = (''.join(random.sample(string.ascii_uppercase +
108109
string.ascii_lowercase + string.digits, 10)))
109-
ee_db_name = (ee_db_name[0:6] + ee_random10)
110-
110+
ee_db_username = (ee_db_name[0:6] + ee_random10)
111111
# create MySQL database
112112
Log.info(self, "Setting up database\t\t", end='')
113113
Log.debug(self, "Creating databse {0}".format(ee_db_name))
@@ -146,8 +146,8 @@ def setupwordpress(self, data):
146146
ee_random = (''.join(random.sample(string.ascii_uppercase +
147147
string.ascii_lowercase + string.digits, 15)))
148148
ee_wp_prefix = ''
149-
ee_wp_user = ''
150-
ee_wp_pass = ''
149+
# ee_wp_user = ''
150+
# ee_wp_pass = ''
151151

152152
Log.info(self, "Downloading Wordpress \t\t", end='')
153153
EEFileUtils.chdir(self, '{0}/htdocs/'.format(ee_site_webroot))
@@ -158,9 +158,8 @@ def setupwordpress(self, data):
158158
data = setupdatabase(self, data)
159159
if prompt_wpprefix == 'True' or prompt_wpprefix == 'true':
160160
try:
161-
ee_wp_prefix = input('Enter the WordPress table prefix [wp_]: '
162-
.format(ee_replace_dot))
163-
while re.match('^[A-Za-z0-9_]*$', ee_wp_prefix):
161+
ee_wp_prefix = input('Enter the WordPress table prefix [wp_]: ')
162+
while not re.match('^[A-Za-z0-9_]*$', ee_wp_prefix):
164163
Log.warn(self, "table prefix can only "
165164
"contain numbers, letters, and underscores")
166165
ee_wp_prefix = input('Enter the WordPress table prefix [wp_]: '

ee/core/services.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ def get_service_status(self, service_name):
118118
try:
119119
is_exist = subprocess.getstatusoutput('which {0}'
120120
.format(service_name))
121-
if is_exist == 0:
121+
if is_exist[0] == 0:
122122
retcode = subprocess.getstatusoutput('service {0} status'
123123
.format(service_name))
124124
if retcode[0] == 0:

ee/core/variables.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class EEVariables():
1212
"""Intialization of core variables"""
1313

1414
# EasyEngine version
15-
ee_version = "3.0.0"
15+
ee_version = "3.0.0-beta"
1616

1717
# EasyEngine packages versions
1818
ee_wp_cli = "0.18.0"

0 commit comments

Comments
 (0)