Skip to content

"This is a development server" #354

@solemnwarning

Description

@solemnwarning

Hello,

When running the snappass script, I get the following warning on the console:

WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.

From a very brief skim of the Flask docs, production use is recommended to use something like Waitress as the actual HTTP server rather than the one bundled with Flask, which seems to work if I add the following function to main.py:

def get_app():
    return app

...and then run Waitress with the following command:

waitress-serve --call snappass:main.get_app

Is there a way to host snappass behind a "production recommended" HTTP server without modifications? Is there a reason to stick with the built-in Flask server instead?

Thanks

EDIT: You can use waitress with modifying main.py with the following command:

waitress-serve --call snappass.main:app

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions