Skip to content

Commit

Permalink
✨🐞 Improve/rethink/fix Live Preview (#357)
Browse files Browse the repository at this point in the history
Parent issue: sequentech/meta#752
  • Loading branch information
Findeton authored Jun 25, 2024
1 parent 090feed commit 0a44750
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ config:
# play.http.parser.maxDiskBuffer (in ballot-box config)
# play.http.parser.maxMemoryBuffer (in ballot-box config)
# parsers.text.maxLength (in ballot-box config)
# DATA_UPLOAD_MAX_MEMORY_SIZE (in iam config)
# client_max_body_size (in nginx)
max_body_size: 2m

Expand Down
3 changes: 3 additions & 0 deletions iam/templates/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,4 +223,7 @@ def on_celery_setup_logging(**kwargs):
{{extra_option}}
{% endfor %}

{% set max_body_size_bytes = (config.http.max_body_size[:-1] | int) * 1024 * 1024 %}

DATA_UPLOAD_MAX_MEMORY_SIZE = {{ max_body_size_bytes }}

4 changes: 4 additions & 0 deletions iam/templates/test_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,10 @@ class CeleryConfig:

ENABLE_MULTIPLE_TALLIES = False

{% set max_body_size_bytes = (config.http.max_body_size[:-1] | int) * 1024 * 1024 %}

DATA_UPLOAD_MAX_MEMORY_SIZE = {{ max_body_size_bytes }}

if not os.path.exists(IMAGE_STORE_PATH):
os.mkdir(IMAGE_STORE_PATH)

Expand Down

0 comments on commit 0a44750

Please sign in to comment.