Skip to content

Commit

Permalink
Add limits (#42)
Browse files Browse the repository at this point in the history
* initial changes - testing still required

* Update Dockerfile to match version 16

---------

Co-authored-by: Malte <[email protected]>
  • Loading branch information
doughoke and maltekrupa authored Jul 6, 2023
1 parent a8260b1 commit 2ac412a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
24 changes: 13 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,14 +67,16 @@ Some metrics are available at `GET /metrics`.

## Environment variables

| Environment variable | Required | Default | Purpose |
|----------------------|----------|---------|------------------------------------------|
| LOGLEVEL | false | INFO | Loglevel |
| LOGJSON | false | True | If enabled, most logs are in JSON format |
| CLAMD_HOST | false | clamav | Hostname where to reach clamav container |
| CLAMD_PORT | false | 3310 | Port where to reach clamav container |
| LISTEN_HOST | false | 0.0.0.0 | IP to listen on inside container |
| LISTEN_PORT | false | 8080 | Port to listen on inside container |
| AUTH_USERNAME | false | | Username for optional basic auth |
| AUTH_PASSWORD | false | | Password for optional basic auth |
| MAX_CONTENT_LENGTH | false | 16 MB | The maximum request size in bytes |
| Environment variable | Required | Default | Purpose |
|----------------------|----------|----------|---------------------------------------------|
| LOGLEVEL | false | INFO | Loglevel |
| LOGJSON | false | True | If enabled, most logs are in JSON format |
| CLAMD_HOST | false | clamav | Hostname where to reach clamav container |
| CLAMD_PORT | false | 3310 | Port where to reach clamav container |
| LISTEN_HOST | false | 0.0.0.0 | IP to listen on inside container |
| LISTEN_PORT | false | 8080 | Port to listen on inside container |
| AUTH_USERNAME | false | | Username for optional basic auth |
| AUTH_PASSWORD | false | | Password for optional basic auth |
| MAX_CONTENT_LENGTH | false | 16777216 | The maximum request size in bytes (16MB) |
| RESPONSE_TIMEOUT | false | 60 | Override default response timeout for Flask |
| BODY_TIMEOUT | false | 60 | Override default body timeout for Flask |
2 changes: 2 additions & 0 deletions config.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@
AUTH_PASSWORD = os.environ.get('AUTH_PASSWORD', None)

MAX_CONTENT_LENGTH = int(os.environ.get('MAX_CONTENT_LENGTH', 16777216))
RESPONSE_TIMEOUT = int(os.environ.get('RESPONSE_TIMEOUT', 60))
BODY_TIMEOUT = int(os.environ.get('BODY_TIMEOUT', 60))

0 comments on commit 2ac412a

Please sign in to comment.