🔧 adds config file for Clever Cloud deployment

This commit is contained in:
Jean-Louis Jouannic 2022-06-08 21:43:52 +02:00 committed by Christopher Charbonneau Wells
parent e950aeb4da
commit e8de147657
2 changed files with 18 additions and 0 deletions

View File

@ -9,3 +9,4 @@
!railway.py
!render.py
!test.py
!clever-cloud.py

View File

@ -0,0 +1,17 @@
from .base import *
import os
if os.getenv("POSTGRESQL_ADDON_HOST"):
config["ENGINE"] = "django.db.backends.postgresql"
config["HOST"] = os.getenv("POSTGRESQL_ADDON_HOST")
config["PORT"] = os.getenv("POSTGRESQL_ADDON_PORT")
config["NAME"] = os.getenv("POSTGRESQL_ADDON_DB")
config["USER"] = os.getenv("POSTGRESQL_ADDON_USER")
config["PASSWORD"] = os.getenv("POSTGRESQL_ADDON_PASSWORD")
if os.getenv("CELLAR_ADDON_HOST"):
BABY_BUDDY["ALLOW_UPLOADS"] = True
AWS_S3_ENDPOINT_URL = "https://{}".format(
os.environ.get("CELLAR_ADDON_HOST"))
AWS_ACCESS_KEY_ID = os.environ.get("CELLAR_ADDON_KEY_ID")
AWS_SECRET_ACCESS_KEY = os.environ.get("CELLAR_ADDON_KEY_SECRET")