mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Merge pull request #10577 from ic4f/dev_uwsgi_debug_mode
Set uwsgi's honour-stdin option when in debug mode
This commit is contained in:
@@ -2388,6 +2388,11 @@
|
||||
use_printdebug. It also causes the files used by PBS/SGE
|
||||
(submission script, output, and error) to remain on disk after the
|
||||
job is complete.
|
||||
In addition, this will set uWSGI's `honour-stdin` option to
|
||||
`true`; thus, preventing uWSGI from remapping stdin to `/dev/null`
|
||||
and enabling debugging with tools like pdb. To keep uWSGI's
|
||||
default setting, set `honor-stdin` to `false` in the `uwsgi`
|
||||
section of this configuration file.
|
||||
:Default: ``false``
|
||||
:Type: bool
|
||||
|
||||
|
||||
@@ -1217,6 +1217,11 @@ galaxy:
|
||||
# use_printdebug. It also causes the files used by PBS/SGE
|
||||
# (submission script, output, and error) to remain on disk after the
|
||||
# job is complete.
|
||||
# In addition, this will set uWSGI's `honour-stdin` option to `true`;
|
||||
# thus, preventing uWSGI from remapping stdin to `/dev/null` and
|
||||
# enabling debugging with tools like pdb. To keep uWSGI's default
|
||||
# setting, set `honor-stdin` to `false` in the `uwsgi` section of this
|
||||
# configuration file.
|
||||
#debug: false
|
||||
|
||||
# Check for WSGI compliance.
|
||||
|
||||
@@ -1731,6 +1731,12 @@ mapping:
|
||||
causes the files used by PBS/SGE (submission script, output, and error)
|
||||
to remain on disk after the job is complete.
|
||||
|
||||
In addition, this will set uWSGI's `honour-stdin` option to `true`;
|
||||
thus, preventing uWSGI from remapping stdin to `/dev/null` and
|
||||
enabling debugging with tools like pdb. To keep uWSGI's default
|
||||
setting, set `honor-stdin` to `false` in the `uwsgi` section of this
|
||||
configuration file.
|
||||
|
||||
use_lint:
|
||||
type: bool
|
||||
default: false
|
||||
|
||||
@@ -118,6 +118,11 @@ def _get_uwsgi_args(cliargs, kwargs):
|
||||
# We always want to append client/src/assets as static-safe.
|
||||
__add_arg(args, 'static-safe', f'{os.getcwd()}/client/src/assets')
|
||||
|
||||
# Do not let uwsgi remap stdin to /dev/null if galaxy is in debug mode
|
||||
galaxy_kwargs = load_app_properties(config_file=config_file, config_section='galaxy')
|
||||
if __arg_set('debug', galaxy_kwargs) and not __arg_set('honour-stdin', uwsgi_kwargs):
|
||||
__add_arg(args, 'honour-stdin', True)
|
||||
|
||||
for arg in DEFAULT_ARGS['_all_'] + DEFAULT_ARGS[cliargs.app]:
|
||||
if not __arg_set(arg, uwsgi_kwargs):
|
||||
__add_arg(args, arg, defaults[arg])
|
||||
|
||||
Reference in New Issue
Block a user