diff --git a/development.ini b/development.ini --- a/development.ini +++ b/development.ini @@ -60,7 +60,12 @@ smtp_port = #smtp_use_ssl = false #smtp_use_tls = false +## Entry point for 'gearbox serve' [server:main] +#host = 127.0.0.1 +host = 0.0.0.0 +port = 5000 + ## WAITRESS ## use = egg:waitress#main ## number of worker threads @@ -71,11 +76,6 @@ max_request_body_size = 107374182400 ## windows systems. #asyncore_use_poll = True -## COMMON ## -#host = 127.0.0.1 -host = 0.0.0.0 -port = 5000 - ## middleware for hosting the WSGI application under a URL prefix #[filter:proxy-prefix] #use = egg:PasteDeploy#prefix diff --git a/kallithea/lib/paster_commands/template.ini.mako b/kallithea/lib/paster_commands/template.ini.mako --- a/kallithea/lib/paster_commands/template.ini.mako +++ b/kallithea/lib/paster_commands/template.ini.mako @@ -61,7 +61,12 @@ smtp_port = #smtp_use_ssl = false #smtp_use_tls = false +%if http_server != 'uwsgi': +<%text>## Entry point for 'gearbox serve' [server:main] +host = ${host} +port = ${port} + %if http_server == 'gearbox': <%text>## Gearbox default web server ## use = egg:gearbox#wsgiref @@ -103,7 +108,8 @@ max_requests = 1000 <%text>## restarted timeout = 3600 -%elif http_server == 'uwsgi': +%endif +%else: <%text>## UWSGI ## <%text>## run with uwsgi --ini-paste-logged [uwsgi] @@ -165,11 +171,6 @@ workers = 4 cheaper-step = 1 %endif -%if http_server != 'uwsgi': -host = ${host} -port = ${port} - -%endif <%text>## middleware for hosting the WSGI application under a URL prefix #[filter:proxy-prefix] #use = egg:PasteDeploy#prefix