Compare commits
1 Commits
main
...
revert-2-r
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1d12ac7d6f |
10
app.py
10
app.py
@@ -41,20 +41,12 @@ sys.path.insert(0, os.path.dirname(__file__)) # Todo: why?
|
|||||||
|
|
||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
app.secret_key = os.getenv('KEY_SECRET_FLASK')
|
|
||||||
|
|
||||||
# AppConfig(app)
|
# AppConfig(app)
|
||||||
app.config.from_object(app_config) # for db init with required keys
|
app.config.from_object(app_config) # for db init with required keys
|
||||||
app.app_config = app_config
|
app.app_config = app_config
|
||||||
# app.config["config"] = app_config()
|
# app.config["config"] = app_config()
|
||||||
|
|
||||||
print('sql vars')
|
|
||||||
print(app.config['DB_PASSWORD'])
|
|
||||||
print(app.config['DB_USER'])
|
|
||||||
print(app.config['SQLALCHEMY_DATABASE_URI'])
|
|
||||||
print(app.config['SECRET_KEY'])
|
|
||||||
print(os.getenv('KEY_SECRET_FLASK'))
|
|
||||||
|
|
||||||
# logging
|
# logging
|
||||||
handler = RotatingFileHandler('app.log', maxBytes=10000, backupCount=3)
|
handler = RotatingFileHandler('app.log', maxBytes=10000, backupCount=3)
|
||||||
handler.setLevel(logging.DEBUG)
|
handler.setLevel(logging.DEBUG)
|
||||||
@@ -122,4 +114,4 @@ app.register_blueprint(routes_user)
|
|||||||
@app.template_filter('console_log')
|
@app.template_filter('console_log')
|
||||||
def console_log(value):
|
def console_log(value):
|
||||||
Helper_App.console_log(value)
|
Helper_App.console_log(value)
|
||||||
return value
|
return value
|
||||||
@@ -1,6 +1,5 @@
|
|||||||
|
|
||||||
Flask==3.0.3
|
flask
|
||||||
gunicorn==23.0.0
|
|
||||||
flask_wtf
|
flask_wtf
|
||||||
flask_sqlalchemy
|
flask_sqlalchemy
|
||||||
flask_cors
|
flask_cors
|
||||||
|
|||||||
Reference in New Issue
Block a user