-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
isolate mandatory env vars in test.py, remove corresponding default v…
…alues from base.py
- Loading branch information
1 parent
69bd89d
commit fbc6a4b
Showing
3 changed files
with
40 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -268,14 +268,12 @@ | |
# S3 uploads | ||
# ------------------------------------------------------------------------------ | ||
|
||
AWS_S3_ACCESS_KEY_ID = os.getenv("CELLAR_ADDON_KEY_ID", "123") | ||
AWS_S3_SECRET_ACCESS_KEY = os.getenv("CELLAR_ADDON_KEY_SECRET", "secret") | ||
AWS_S3_ENDPOINT_URL = ( | ||
f"{os.getenv('CELLAR_ADDON_PROTOCOL', 'https')}://{os.getenv('CELLAR_ADDON_HOST', 'set-var-env.com')}" | ||
) | ||
AWS_STORAGE_BUCKET_NAME = os.getenv("S3_STORAGE_BUCKET_NAME", "private-bucket") | ||
AWS_STORAGE_BUCKET_NAME_PUBLIC = os.getenv("S3_STORAGE_BUCKET_NAME_PUBLIC", "public-bucket") | ||
AWS_S3_STORAGE_BUCKET_REGION = os.getenv("S3_STORAGE_BUCKET_REGION", "eu-west-3") | ||
AWS_S3_ACCESS_KEY_ID = os.getenv("CELLAR_ADDON_KEY_ID") | ||
AWS_S3_SECRET_ACCESS_KEY = os.getenv("CELLAR_ADDON_KEY_SECRET") | ||
AWS_S3_ENDPOINT_URL = f"{os.getenv('CELLAR_ADDON_PROTOCOL')}://{os.getenv('CELLAR_ADDON_HOST')}" | ||
AWS_STORAGE_BUCKET_NAME = os.getenv("S3_STORAGE_BUCKET_NAME") | ||
AWS_STORAGE_BUCKET_NAME_PUBLIC = os.getenv("S3_STORAGE_BUCKET_NAME_PUBLIC") | ||
AWS_S3_STORAGE_BUCKET_REGION = os.getenv("S3_STORAGE_BUCKET_REGION") | ||
|
||
# MEDIA CONFIGURATION | ||
# ------------------------------------------------------------------------------ | ||
|
@@ -359,11 +357,11 @@ | |
|
||
# SENDINBLUE | ||
# --------------------------------------- | ||
SIB_URL = os.getenv("SIB_URL", "http://test.com") | ||
SIB_URL = os.getenv("SIB_URL") | ||
SIB_SMTP_ROUTE = "smtp/email" | ||
SIB_CONTACTS_ROUTE = "contacts/import" | ||
|
||
SIB_API_KEY = os.getenv("SIB_API_KEY", "set-sib-api-key") | ||
SIB_API_KEY = os.getenv("SIB_API_KEY") | ||
DEFAULT_FROM_EMAIL = os.getenv("DEFAULT_FROM_EMAIL", "[email protected]") | ||
|
||
SIB_MAGIC_LINK_TEMPLATE = 31 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import os | ||
|
||
from lacommunaute.utils.enums import Environment | ||
|
||
from .base import * # pylint: disable=wildcard-import,unused-wildcard-import # noqa: F403 F401 | ||
|
||
|
||
# Django settings | ||
# --------------- | ||
SECRET_KEY = "v3ry_s3cr3t_k3y" | ||
|
||
ENVIRONMENT = Environment.TEST | ||
|
||
# S3 uploads | ||
# ------------------------------------------------------------------------------ | ||
|
||
AWS_S3_ACCESS_KEY_ID = os.getenv("CELLAR_ADDON_KEY_ID", "minioadmin") | ||
AWS_S3_SECRET_ACCESS_KEY = os.getenv("CELLAR_ADDON_KEY_SECRET", "minioadmin") | ||
AWS_S3_ENDPOINT_URL = ( | ||
f"{os.getenv('CELLAR_ADDON_PROTOCOL', 'http')}://{os.getenv('CELLAR_ADDON_HOST', 'localhost:900')}" | ||
) | ||
AWS_STORAGE_BUCKET_NAME = "private-bucket" | ||
AWS_STORAGE_BUCKET_NAME_PUBLIC = "public-bucket" | ||
AWS_S3_STORAGE_BUCKET_REGION = "eu-west-3" | ||
|
||
MEDIA_URL = f"{AWS_S3_ENDPOINT_URL}/" | ||
|
||
# SENDINBLUE | ||
# --------------------------------------- | ||
SIB_URL = "http://test.com" | ||
SIB_API_KEY = "dummy-sib-api-key" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters