launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #26087
[Merge] ~pappacena/launchpad:enabling-gunicorn-in-tests into launchpad:master
Thiago F. Pappacena has proposed merging ~pappacena/launchpad:enabling-gunicorn-in-tests into launchpad:master with ~pappacena/launchpad:enabling-gunicorn-in-development as a prerequisite.
Commit message:
Using gunicorn when running tests
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~pappacena/launchpad/+git/launchpad/+merge/396770
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~pappacena/launchpad:enabling-gunicorn-in-tests into launchpad:master.
diff --git a/configs/replicated-development/gunicorn.conf.py b/configs/replicated-development/gunicorn.conf.py
new file mode 100644
index 0000000..b667109
--- /dev/null
+++ b/configs/replicated-development/gunicorn.conf.py
@@ -0,0 +1,6 @@
+bind = [":8085", ":8086", ":8087", ":8088", ":8089"]
+workers = 2
+threads = 10
+max_requests = 1000
+log_level = "DEBUG"
+reload = True
diff --git a/configs/replicated-development/launchpad-lazr.conf b/configs/replicated-development/launchpad-lazr.conf
index 364d5e6..750c283 100644
--- a/configs/replicated-development/launchpad-lazr.conf
+++ b/configs/replicated-development/launchpad-lazr.conf
@@ -8,3 +8,7 @@ extends: ../development/launchpad-lazr.conf
[database]
rw_main_master: dbname=launchpad_dev_master port=5433
rw_main_slave: dbname=launchpad_dev_slave port=5433
+
+[launchpad]
+devmode: true
+use_gunicorn: true
diff --git a/configs/test-playground/gunicorn.conf.py b/configs/test-playground/gunicorn.conf.py
new file mode 100644
index 0000000..ba22ec1
--- /dev/null
+++ b/configs/test-playground/gunicorn.conf.py
@@ -0,0 +1,12 @@
+import os
+config_dir = os.path.dirname(__file__)
+log_dir = os.path.join(config_dir, '..', '..', 'logs')
+
+bind = [":8085", ":8087"]
+workers = 1
+threads = 10
+log_level = "DEBUG"
+
+log_file = os.path.join(log_dir, 'gunicorn.log')
+error_logfile = os.path.join(log_dir, 'gunicorn-error.log')
+access_logfile = os.path.join(log_dir, 'gunicorn-access.log')
diff --git a/configs/test-playground/launchpad-lazr.conf b/configs/test-playground/launchpad-lazr.conf
index 8790cb6..77818e4 100644
--- a/configs/test-playground/launchpad-lazr.conf
+++ b/configs/test-playground/launchpad-lazr.conf
@@ -8,3 +8,7 @@ extends: ../development/launchpad-lazr.conf
[database]
rw_main_master: dbname=launchpad_ftest_playground
rw_main_slave: dbname=launchpad_ftest_playground
+
+[launchpad]
+devmode: true
+use_gunicorn: true
diff --git a/configs/testrunner-appserver/launchpad-lazr.conf b/configs/testrunner-appserver/launchpad-lazr.conf
index 80faefb..3653a4d 100644
--- a/configs/testrunner-appserver/launchpad-lazr.conf
+++ b/configs/testrunner-appserver/launchpad-lazr.conf
@@ -12,6 +12,9 @@ launch: False
launch: False
[launchpad]
+# Make this work a little more like production.
+devmode: false
+use_gunicorn: true
openid_provider_root: http://testopenid.test:8085/
internal_macaroon_secret_key: internal-dev-macaroon-secret
diff --git a/configs/testrunner/launchpad-lazr.conf b/configs/testrunner/launchpad-lazr.conf
index e5a0ad8..1e930d6 100644
--- a/configs/testrunner/launchpad-lazr.conf
+++ b/configs/testrunner/launchpad-lazr.conf
@@ -101,6 +101,8 @@ public_https: True
max_scaling: 2
[launchpad]
+devmode: true
+use_gunicorn: true
basic_auth_password: test
max_attachment_size: 1024
geoip_database: lib/lp/services/geoip/tests/data/test.mmdb
Follow ups