Skip to content

Commit

Permalink
S3 config for test
Browse files Browse the repository at this point in the history
  • Loading branch information
amandine-sahl committed Jul 28, 2023
1 parent 37c99e1 commit 605308b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 0 additions & 1 deletion apptax/admin/admin_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,6 @@ def postprocess_form(self, form):
else:
form_class.chemin = FileUploadField(
base_path=current_app.config["MEDIA_FOLDER"],

namegen=taxref_media_file_name,
)
return form_class
Expand Down
1 change: 1 addition & 0 deletions apptax/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ def create_app():

app.config["DB"] = db

app.config["USE_S3"] = app.config.get("USE_S3", False)
app.config["S3_BUCKET_NAME"] = app.config.get("S3_BUCKET_NAME", None)
app.config["S3_KEY"] = app.config.get("S3_KEY", None)
app.config["S3_SECRET"] = app.config.get("S3_SECRET", None)
Expand Down
2 changes: 2 additions & 0 deletions apptax/test_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@
COOKIE_EXPIRATION = 3600

MEDIA_FOLDER = 'medias'

USE_S3=False

0 comments on commit 605308b

Please sign in to comment.