Fix app load failure.

This commit is contained in:
Leo Vasanko 2023-10-19 00:13:47 +00:00 committed by Leo Vasanko
parent a00610a738
commit 7484795ce5
2 changed files with 3 additions and 3 deletions

View File

@ -4,10 +4,10 @@ from pathlib import Path
from docopt import docopt
from . import app, config, droppy, serve
from . import app, config, droppy, serve, httpredir
from ._version import version
app # Needed for Sanic multiprocessing
app, httpredir.app # Needed for Sanic multiprocessing
doc = f"""Cista {version} - A file storage for the web.

View File

@ -11,7 +11,7 @@ def redirect_everything_else(request, exception):
return response.text("Bad Request. Please use HTTPS!", status=400)
# ACME challenge for LetsEncrypt
app.get("/.well-known/acme-challenge/<challenge>")
@app.get("/.well-known/acme-challenge/<challenge>")
async def letsencrypt(request, challenge):
try:
return response.text(acme_challenges[challenge])