+2
-2
@@ -370,8 +370,8 @@ def wsgibase(environ, responder):
|
|||||||
cid = env.http_web2py_component_element,
|
cid = env.http_web2py_component_element,
|
||||||
is_local = (env.remote_addr in local_hosts and
|
is_local = (env.remote_addr in local_hosts and
|
||||||
client == env.remote_addr),
|
client == env.remote_addr),
|
||||||
is_shell = cmd_opts and cmd_opts.shell,
|
is_shell = False,
|
||||||
is_sheduler = cmd_opts and cmd_opts.scheduler,
|
is_scheduler = False,
|
||||||
is_https = env.wsgi_url_scheme in HTTPS_SCHEMES or \
|
is_https = env.wsgi_url_scheme in HTTPS_SCHEMES or \
|
||||||
request.env.http_x_forwarded_proto in HTTPS_SCHEMES \
|
request.env.http_x_forwarded_proto in HTTPS_SCHEMES \
|
||||||
or env.https == 'on'
|
or env.https == 'on'
|
||||||
|
|||||||
@@ -129,6 +129,8 @@ def env(
|
|||||||
if global_settings.cmd_options:
|
if global_settings.cmd_options:
|
||||||
ip = global_settings.cmd_options.ip
|
ip = global_settings.cmd_options.ip
|
||||||
port = global_settings.cmd_options.port
|
port = global_settings.cmd_options.port
|
||||||
|
request.is_shell = global_settings.cmd_options.shell is not None
|
||||||
|
request.is_scheduler = global_settings.cmd_options.scheduler is not None
|
||||||
else:
|
else:
|
||||||
ip, port = '127.0.0.1', '8000'
|
ip, port = '127.0.0.1', '8000'
|
||||||
request.env.http_host = '%s:%s' % (ip, port)
|
request.env.http_host = '%s:%s' % (ip, port)
|
||||||
|
|||||||
Reference in New Issue
Block a user