diff options
author | Yulqen <246857+yulqen@users.noreply.github.com> | 2024-06-06 10:31:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-06 10:31:24 +0100 |
commit | ecc1938b16b85cfa98039937815e75b03a30b869 (patch) | |
tree | c1e6fef936382632eda67bfe13e6fb611a336e74 /conf | |
parent | e487ca089ecb3f8ca946f229f5a2058058e401dc (diff) | |
parent | 9f8dcc276b746ba3d3d9365541d88f5423430a3d (diff) |
Merge pull request #83 from defencedigital/postgres-migration
Configures static for the new volume
Diffstat (limited to 'conf')
-rw-r--r-- | conf/settings/prod.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/conf/settings/prod.py b/conf/settings/prod.py index f6b2d77..cb1842a 100644 --- a/conf/settings/prod.py +++ b/conf/settings/prod.py @@ -2,9 +2,6 @@ import os from .base import * -# Database -# https://docs.djangoproject.com/en/4.0/ref/settings/#databases - # Check if running in OpenShift cluster if os.path.exists("/etc/secret-volume"): # Read database credentials from mounted Secret volume @@ -33,3 +30,8 @@ DATABASES = { "PORT": db_port, } } + +if os.getenv("STATIC_ROOT"): + STATIC_ROOT = os.getenv("STATIC_ROOT") +else: + STATIC_ROOT = "/data/static" |