Disable HTTP logs in apps platform

I have a flask application running in gunicorn in the app platform. Run command:

gunicorn --config --worker-tmp-dir /dev/shm --log-level error wsgi:app

bind = ''
workers = 2
worker_class = 'gevent'
worker_connections = 1000

flask init:

if logging.getLogger('gunicorn.error').handlers:

But the logs contain http requests:

app-name | 2021-02-18 19:28:13 - - [18/Feb/2021:17:28:13 +0000] "POST /route HTTP/1.1" 200 322 "-" "Apache-HttpClient/4.5.7 (Java/1.8.0_212)"

I want the logs to contain only errors and the messages that I send myself:'some log message')

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

The log messages you’ve referenced aren’t generated by App Platform. I suspect they’re being emitted by either gunicorn or flask. In gunicorn I believe you can disable the access log by setting accesslog = False.