debug et ajout server_config_default.py
All checks were successful
Build and Push Docker Image / build (push) Successful in 1m40s
All checks were successful
Build and Push Docker Image / build (push) Successful in 1m40s
This commit is contained in:
@@ -15,6 +15,10 @@ jobs:
|
|||||||
apk update && apk add --no-cache mariadb-connector-c-dev && apk add --no-cache gcc musl-dev nodejs npm git docker libffi-dev
|
apk update && apk add --no-cache mariadb-connector-c-dev && apk add --no-cache gcc musl-dev nodejs npm git docker libffi-dev
|
||||||
- name: Check out repository code
|
- name: Check out repository code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
- name: Use server_config_default as primary
|
||||||
|
run : mv /workspace/CLERC/Reskreen/Reskreen/server_config_default.py /workspace/CLERC/Reskreen/Reskreen/server_config.py
|
||||||
|
- name: check server_config_default as primary
|
||||||
|
run : cat /workspace/CLERC/Reskreen/Reskreen/server_config.py
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
- name: Log in to Docker Registry
|
- name: Log in to Docker Registry
|
||||||
|
|||||||
62
Reskreen/server_config_default.py
Normal file
62
Reskreen/server_config_default.py
Normal 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'),
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user