aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetr Šmerkl <46304018+SveterCZE@users.noreply.github.com>2022-11-19 18:11:13 +0100
committerPetr Šmerkl <46304018+SveterCZE@users.noreply.github.com>2022-11-19 18:11:13 +0100
commitc9f8dc72200e430d64a1f0ce598364a5a5678b8c (patch)
tree0a49115a9dafc899b346b729dedbad0a67ca1a6d
parentb7bcefdffaec476dcc7d67610c7007e90cc89908 (diff)
downloadjustice-c9f8dc72200e430d64a1f0ce598364a5a5678b8c.tar.gz
remove sensitive properties to a hidden file
-rw-r--r--.gitignore3
-rw-r--r--app.py5
2 files changed, 5 insertions, 3 deletions
diff --git a/.gitignore b/.gitignore
index 6b32c79..ba855d5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -17,4 +17,5 @@ __pycache__/db_creation.cpython-38.pyc
__pycache__/download_files.cpython-38.pyc
__pycache__/update_db.cpython-38.pyc
key_gen.py
-__pycache__/* \ No newline at end of file
+__pycache__/*
+config_data.py
diff --git a/app.py b/app.py
index fa47203..e8ac2f7 100644
--- a/app.py
+++ b/app.py
@@ -10,12 +10,13 @@ Created on Sun Jan 17 09:38:19 2021
from flask import Flask
# from flask_debugtoolbar import DebugToolbarExtension
from flask_sqlalchemy import SQLAlchemy
+from config_data import secret_key, db_address
app = Flask(__name__)
-app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///justice.db'
+app.config['SQLALCHEMY_DATABASE_URI'] = db_address
app.config["SQLALCHEMY_ECHO"] = False
app.debug = False
# HIDE THIS BEFORE DEPLOYING TO PRODUCTION :)
-app.secret_key = "123456"
+app.secret_key = secret_key
# toolbar = DebugToolbarExtension(app)
db = SQLAlchemy(app) \ No newline at end of file