mirror of
https://github.com/thiagoralves/OpenPLC_v3.git
synced 2025-12-17 10:14:15 +08:00
[RTOP-26] Update webserver/config.py
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
e0f35c32ac
commit
301930e2b1
@@ -1,8 +1,12 @@
|
||||
from dotenv import load_dotenv
|
||||
import os
|
||||
|
||||
load_dotenv() # Loads variables from .env into os.environ
|
||||
from pathlib import Path
|
||||
from dotenv import load_dotenv
|
||||
|
||||
# Always resolve .env relative to the repo root to guarantee it is found
|
||||
ENV_PATH = Path(__file__).resolve().parent.parent / ".env"
|
||||
load_dotenv(dotenv_path=ENV_PATH, override=False)
|
||||
BASE_DIR = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
class Config:
|
||||
|
||||
Reference in New Issue
Block a user