From cb8ce3160afd963cec6186e535232275d9930b3c Mon Sep 17 00:00:00 2001 From: Wojtek Kosior Date: Wed, 27 Apr 2022 11:45:18 +0200 Subject: fix/improve wsgi deployment --- src/hydrilla/server/serve.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/hydrilla') diff --git a/src/hydrilla/server/serve.py b/src/hydrilla/server/serve.py index d2835f6..d07d44f 100644 --- a/src/hydrilla/server/serve.py +++ b/src/hydrilla/server/serve.py @@ -625,10 +625,13 @@ start = click.command()(start) @click.version_option(version=_version.version, prog_name='Hydrilla', message=_('%(prog)s_%(version)s_license'), help=_('version_printing')) -def start_wsgi(_config=None) -> None: +def start_wsgi() -> None: """""" - return HydrillaApp(_config or config.load()) + return HydrillaApp(click.get_current_context().obj or config.load()) start_wsgi.__doc__ = _('serve_hydrilla_packages_wsgi_help') -start_wsgi = click.command()(start_wsgi) +start_wsgi = click.command(context_settings={ + 'ignore_unknown_options': True, + 'allow_extra_args': True +})(start_wsgi) -- cgit v1.2.3