updated digiserver 2
This commit is contained in:
@@ -49,10 +49,11 @@ class DevelopmentConfig(Config):
|
||||
DEBUG = True
|
||||
TESTING = False
|
||||
|
||||
# Database
|
||||
# Database - construct absolute path
|
||||
_basedir = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
|
||||
SQLALCHEMY_DATABASE_URI = os.getenv(
|
||||
'DATABASE_URL',
|
||||
'sqlite:///instance/dev.db'
|
||||
f'sqlite:///{os.path.join(_basedir, "instance", "dev.db")}'
|
||||
)
|
||||
|
||||
# Cache (simple in-memory for development)
|
||||
@@ -70,10 +71,11 @@ class ProductionConfig(Config):
|
||||
DEBUG = False
|
||||
TESTING = False
|
||||
|
||||
# Database
|
||||
# Database - construct absolute path
|
||||
_basedir = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
|
||||
SQLALCHEMY_DATABASE_URI = os.getenv(
|
||||
'DATABASE_URL',
|
||||
'sqlite:///instance/dashboard.db'
|
||||
f'sqlite:///{os.path.join(_basedir, "instance", "dashboard.db")}'
|
||||
)
|
||||
|
||||
# Redis Cache
|
||||
|
||||
Reference in New Issue
Block a user