Browse Source

Don't use "egg:" for gunicorn option.

INADA Naoki 12 years ago
parent
commit
c45d8518db
4 changed files with 7 additions and 5 deletions
  1. 2 2
      bottle/setup.py
  2. 1 1
      django-stripped/setup.py
  3. 2 1
      django/setup.py
  4. 2 1
      flask/setup.py

+ 2 - 2
bottle/setup.py

@@ -5,8 +5,8 @@ import os
 
 def start(args):
   setup_util.replace_text("bottle/app.py", "DBHOSTNAME", args.database_host)
-  subprocess.Popen("gunicorn app:app --worker-class=\"egg:meinheld#gunicorn_worker\" -b 0.0.0.0:8080 -w " + str((args.max_threads * 2)) + " --preload --log-level=critical", shell=True, cwd="bottle")
-  
+  subprocess.Popen("gunicorn app:app --worker-class=meinheld.gmeinheld.MeinheldWorker -b 0.0.0.0:8080 -w " +
+                   str((args.max_threads * 2)) + " --preload --log-level=critical", shell=True, cwd="bottle")
   return 0
 
 def stop():

+ 1 - 1
django-stripped/setup.py

@@ -6,7 +6,7 @@ import os
 
 def start(args):
   setup_util.replace_text("django-stripped/hello/hello/settings.py", "HOST': '.*'", "HOST': '" + args.database_host + "'")
-  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=\"egg:meinheld#gunicorn_worker\" -b 0.0.0.0:8080 -w " +
+  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=meinheld.gmeinheld.MeinheldWorker -b 0.0.0.0:8080 -w " +
                    str((multiprocessing.cpu_count() * 3)) + " --log-level=critical", shell=True, cwd="django-stripped/hello")
   return 0
 def stop():

+ 2 - 1
django/setup.py

@@ -10,9 +10,10 @@ home = expanduser("~")
 def start(args):
   setup_util.replace_text("django/hello/hello/settings.py", "HOST': '.*'", "HOST': '" + args.database_host + "'")
   setup_util.replace_text("django/hello/hello/settings.py", "\/home\/ubuntu",  home)
-  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=\"egg:meinheld#gunicorn_worker\"  -b 0.0.0.0:8080 -w " +
+  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=meinheld.gmeinheld.MeinheldWorker -b 0.0.0.0:8080 -w " +
                    str((multiprocessing.cpu_count() * 3)) + " --log-level=critical", shell=True, cwd="django/hello")
   return 0
+
 def stop():
   p = subprocess.Popen(['ps', 'aux'], stdout=subprocess.PIPE)
   out, err = p.communicate()

+ 2 - 1
flask/setup.py

@@ -5,7 +5,8 @@ import os
 
 def start(args):
   setup_util.replace_text("flask/app.py", "DBHOSTNAME", args.database_host)
-  subprocess.Popen("gunicorn app:app --worker-class=\"egg:meinheld#gunicorn_worker\" -b 0.0.0.0:8080 -w " + str((args.max_threads * 2)) + " --preload --log-level=critical", shell=True, cwd="flask")
+  subprocess.Popen("gunicorn app:app --worker-class=meinheld.gmeinheld.MeinheldWorker -b 0.0.0.0:8080 -w " +
+                   str((args.max_threads * 2)) + " --preload --log-level=critical", shell=True, cwd="flask")
   
   return 0