diff --git a/README.md b/README.md index 3b66fbd..62af1fa 100644 --- a/README.md +++ b/README.md @@ -183,7 +183,7 @@ replaced by coffee). To run ceod on a single host (as root, since the app needs to read the keytab): ```sh export FLASK_APP=ceod.api -export FLASK_ENV=development +export FLASK_DEBUG=true flask run -h 0.0.0.0 -p 9987 ``` diff --git a/ceod/api/app_factory.py b/ceod/api/app_factory.py index 221c3d5..01890e5 100644 --- a/ceod/api/app_factory.py +++ b/ceod/api/app_factory.py @@ -74,7 +74,7 @@ def create_app(flask_config={}): def register_services(app): # Config - if app.config.get('ENV') == 'development' and 'CEOD_CONFIG' not in os.environ: + if app.config.get('DEBUG') and 'CEOD_CONFIG' not in os.environ: with importlib.resources.path('tests', 'ceod_dev.ini') as p: config_file = p.__fspath__() else: diff --git a/ceod/api/utils.py b/ceod/api/utils.py index 394cacf..5408ade 100644 --- a/ceod/api/utils.py +++ b/ceod/api/utils.py @@ -139,7 +139,7 @@ def create_streaming_response(txn: AbstractTransaction): def development_only(f: Callable) -> Callable: @functools.wraps(f) def wrapper(*args, **kwargs): - if current_app.config.get('ENV') == 'development' or \ + if current_app.config.get('DEBUG') or \ current_app.config.get('TESTING'): return f(*args, **kwargs) return { diff --git a/dev-requirements.txt b/dev-requirements.txt index e92273e..db17b7c 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,6 +1,6 @@ -flake8==5.0.4 -setuptools==65.4.1 -wheel==0.37.1 -pytest==7.1.3 +flake8==6.1.0 +setuptools==68.0.0 +wheel==0.41.0 +pytest==7.4.0 aiosmtpd==1.4.2 -aiohttp==3.8.3 +aiohttp==3.8.5 diff --git a/docker-compose.yml b/docker-compose.yml index 4db5345..ef0c81e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -8,7 +8,7 @@ x-common: &common - label:disable environment: FLASK_APP: ceod.api - FLASK_ENV: development + FLASK_DEBUG: "true" working_dir: $PWD entrypoint: - ./docker-entrypoint.sh diff --git a/requirements.txt b/requirements.txt index 6c4f13e..4159ec5 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,16 +1,16 @@ -click==8.1.3 -cryptography==35.0.0 -Flask==2.1.2 -gssapi==1.6.14 -gunicorn==20.1.0 +click==8.1.6 +cryptography==41.0.2 +Flask==2.3.2 +gssapi==1.8.2 +gunicorn==21.2.0 Jinja2==3.1.2 ldap3==2.9.1 -mysql-connector-python==8.0.26 -psycopg2-binary==2.9.1 +mysql-connector-python==8.1.0 +psycopg2-binary==2.9.6 python-augeas==1.1.0 -requests==2.26.0 +requests==2.31.0 requests-gssapi==1.2.3 urwid==2.1.2 -Werkzeug==2.1.2 +Werkzeug==2.3.6 zope.component==5.0.1 zope.interface==5.4.0