diff options
Diffstat (limited to 'ihatemoney/run.py')
| -rw-r--r-- | ihatemoney/run.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ihatemoney/run.py b/ihatemoney/run.py index 1d02405..e3a7c1e 100644 --- a/ihatemoney/run.py +++ b/ihatemoney/run.py @@ -28,6 +28,13 @@ def setup_database(app): alembic_setup = db.engine.dialect.has_table(con, 'alembic_version') return tables_exist and not alembic_setup + sqlalchemy_url = app.config.get('SQLALCHEMY_DATABASE_URI') + if sqlalchemy_url.startswith('sqlite:////tmp'): + warnings.warn( + 'The database is currently stored in /tmp and might be lost at ' + 'next reboot.' + ) + db.init_app(app) db.app = app |
