keeping tidy
This commit is contained in:
parent
9a63464300
commit
97c0a22cf6
|
@ -24,5 +24,4 @@ services:
|
||||||
depends_on:
|
depends_on:
|
||||||
- web
|
- web
|
||||||
volumes:
|
volumes:
|
||||||
static_volume:
|
static_volume:
|
||||||
db_persist:
|
|
|
@ -14,5 +14,4 @@ to_register = [
|
||||||
[models.LegislationClassification]
|
[models.LegislationClassification]
|
||||||
]
|
]
|
||||||
for i in to_register:
|
for i in to_register:
|
||||||
admin.site.register(*i)
|
admin.site.register(*i)
|
||||||
print(i)
|
|
|
@ -11,6 +11,7 @@ https://docs.djangoproject.com/en/4.2/ref/settings/
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
import random
|
||||||
|
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
|
@ -18,6 +19,9 @@ from pathlib import Path
|
||||||
BASE_DIR = Path(__file__).resolve().parent.parent
|
BASE_DIR = Path(__file__).resolve().parent.parent
|
||||||
|
|
||||||
SECRET_KEY = os.environ.get("SECRET_KEY")
|
SECRET_KEY = os.environ.get("SECRET_KEY")
|
||||||
|
if not SECRET_KEY:
|
||||||
|
print("[!!!] YOU'RE USING A RANDOM SECRET_KEY -- CHANGE THIS IF YOU'RE GOING INTO PROD")
|
||||||
|
SECRET_KEY = random.randint(1, 100000000000000)
|
||||||
|
|
||||||
DEBUG = bool(os.environ.get("DEBUG", default=0))
|
DEBUG = bool(os.environ.get("DEBUG", default=0))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue