debug et ajout server_config_default.py
All checks were successful
Build and Push Docker Image / build (push) Successful in 1m40s

This commit is contained in:
2024-07-16 02:31:31 +02:00
parent 17890a3380
commit 2cd63b8a1b
2 changed files with 66 additions and 0 deletions

View File

@@ -0,0 +1,62 @@
from pathlib import Path
import os
BASE_DIR = Path(__file__).resolve().parent.parent
cfg_dev_mode = True
# SECURITY WARNING: keep the secret key used in production secret!
# SECURITY WARNING: keep the secret key used in production secret!
#SECRET_KEY = 'django-prod-j4jd&+4j^t_=@zr(#q@n!8e*58vkql6&_6w-t14ju8pw%ei%^s'
SECRET_KEY = 'django-insecure-j4jd&+4j^t_=@zr(#q@n!8e*58vkql6&_6w-t14ju8pw%ei%^s'
cfg_status_badge = "https://status.resk-u.ch/api/badge/22/uptime/744"
ALLOWED_HOSTS = ["reskreen-back.prod.resk-u.ch"]
ALLOWED_HOSTS.append("rh.ambulance-clerc.ch")
ALLOWED_HOSTS.append("reskreen-back.ambulance-clerc.ch")
CSRF_TRUSTED_ORIGINS = ['https://reskreen-back.prod.resk-u.ch']
CSRF_TRUSTED_ORIGINS.append("https://reskreen-back.ambulance-clerc.ch")
CORS_ALLOWED_ORIGINS = [
"https://reskreen-val.prod.resk-u.ch",
"https://reskreen.ambulance-clerc.ch",
"http://33.144.144.13:4173",
"http://33.144.144.13:5173",
"http://33.144.144.13:3000",
]
if cfg_dev_mode:
NEXTCLOUD_HOST = "cloud.ambulance-clerc.ch"
else:
NEXTCLOUD_HOST = "cloud.ambulance-clerc.ch"
NEXTCLOUD_USER_DEFAULT_PASSWORD = "Mc144*1870"
if cfg_dev_mode:
'''DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': BASE_DIR / 'db.sqlite3',
}
}
'''
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'OPTIONS': {
'read_default_file': os.path.join(BASE_DIR, 'Reskreen/my_dev.cnf'),
},
}
}
else:
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'OPTIONS': {
'read_default_file': os.path.join(BASE_DIR, 'Reskreen/my.cnf'),
},
}
}