mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2026-01-22 22:34:20 -06:00
Still support conf
This commit is contained in:
@@ -6,12 +6,25 @@ import os
|
||||
from pathlib import Path
|
||||
from typing import Any
|
||||
|
||||
from dotenv import load_dotenv
|
||||
|
||||
BASE_DIR = Path(__file__).resolve().parent.parent
|
||||
|
||||
DEBUG = False
|
||||
|
||||
ALLOWED_HOSTS = ["*"]
|
||||
|
||||
# Tap paperless.conf if it's available
|
||||
for path in [
|
||||
os.getenv("PAPERLESS_CONFIGURATION_PATH"),
|
||||
"../paperless.conf",
|
||||
"/etc/paperless.conf",
|
||||
"/usr/local/etc/paperless.conf",
|
||||
]:
|
||||
if path and Path(path).exists():
|
||||
load_dotenv(path)
|
||||
break
|
||||
|
||||
|
||||
def __get_path(
|
||||
key: str,
|
||||
|
||||
Reference in New Issue
Block a user