Mount scans to app on startup
This commit is contained in:
parent
b88487af78
commit
efe2127afb
1 changed files with 7 additions and 0 deletions
|
|
@ -44,3 +44,10 @@ def add_static_files(app: FastAPI) -> None:
|
||||||
StaticFiles(directory=fpath),
|
StaticFiles(directory=fpath),
|
||||||
name=f"static_{fname}",
|
name=f"static_{fname}",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Mount the scan directory to .../scans/, to allow dzi viewing
|
||||||
|
app.mount(
|
||||||
|
"/scans/",
|
||||||
|
StaticFiles(directory="/var/openflexure/scans/"),
|
||||||
|
name="scans",
|
||||||
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue