diff --git a/.github/workflows/core-tests.yml b/.github/workflows/core-tests.yml index 7021114..627ac50 100644 --- a/.github/workflows/core-tests.yml +++ b/.github/workflows/core-tests.yml @@ -39,4 +39,4 @@ jobs: # Ignore W605 (https://lintlyci.github.io/Flake8Rules/rules/W605.html) because # flake8 does not understand escaping dots inside templates for nginx and SSH # TODO: pare down complexity and line length as we shrink piku core - flake8 . --ignore=W605 --count --max-complexity=76 --max-line-length=255 --statistics + flake8 . --ignore=W605 --count --max-complexity=78 --max-line-length=255 --statistics diff --git a/legacy/piku_python35.py b/legacy/piku_python35.py index a804385..20e9cb6 100755 --- a/legacy/piku_python35.py +++ b/legacy/piku_python35.py @@ -919,7 +919,7 @@ def spawn_app(app, deltas={}): # change any unecessary uWSGI specific directives to standard proxy ones if 'wsgi' not in workers and 'jwsgi' not in workers: buffer = buffer.replace("uwsgi_", "proxy_") - + # map Cloudflare connecting IP to REMOTE_ADDR if env.get('NGINX_CLOUDFLARE_ACL', 'false').lower() == 'true': buffer = buffer.replace("REMOTE_ADDR $remote_addr", "REMOTE_ADDR $http_cf_connecting_ip") diff --git a/piku.py b/piku.py index cc261ed..314e1e7 100755 --- a/piku.py +++ b/piku.py @@ -919,7 +919,7 @@ def spawn_app(app, deltas={}): # change any unecessary uWSGI specific directives to standard proxy ones if 'wsgi' not in workers and 'jwsgi' not in workers: buffer = buffer.replace("uwsgi_", "proxy_") - + # map Cloudflare connecting IP to REMOTE_ADDR if env.get('NGINX_CLOUDFLARE_ACL', 'false').lower() == 'true': buffer = buffer.replace("REMOTE_ADDR $remote_addr", "REMOTE_ADDR $http_cf_connecting_ip")