diff --git a/.env.template b/.env.template index c00713cf6..2e2eff3b5 100644 --- a/.env.template +++ b/.env.template @@ -1,22 +1,23 @@ +AIRFLOW_CONN_QFDMO_DJANGO_DB=postgresql+psycopg2://qfdmo:qfdmo@localhost:6543/qfdmo +AIRFLOW_WEBSERVER_REFRESHACTEUR_URL=http://localhost:8080 ALLOWED_HOSTS=localhost,127.0.0.1 +AWS_ACCESS_KEY_ID= +AWS_S3_ENDPOINT_URL='https://s3.fr-par.scw.cloud' +AWS_S3_REGION_NAME='fr-par' +AWS_SECRET_ACCESS_KEY= +AWS_STORAGE_BUCKET_NAME='qfdmo-interface' BASE_URL=http://localhost:8000 +CARTE_MAX_SOLUTION_DISPLAYED=10 +CONN_MAX_AGE=0 +CORS_ALLOWED_ORIGINS=http://localhost:8000,http://127.0.0.1:8000 DATABASE_URL=postgis://qfdmo:qfdmo@localhost:6543/qfdmo DB_READONLY=postgis://qfdmo:qfdmo@localhost:6543/qfdmo DEBUG=True +DEFAULT_MAX_SOLUTION_DISPLAYED=10 DISTANCE_MAX=30000 DJANGO_IMPORT_EXPORT_LIMIT=0 ENVIRONMENT=development INSEE_KEY= INSEE_SECRET= -DEFAULT_MAX_SOLUTION_DISPLAYED=10 -CARTE_MAX_SOLUTION_DISPLAYED=10 SECRET_KEY=my-secret-key SENTRY_DSN=https://examplePublicKey@o0.ingest.sentry.io/0 -AWS_ACCESS_KEY_ID= -AWS_SECRET_ACCESS_KEY= -AWS_S3_REGION_NAME='fr-par' -AWS_S3_ENDPOINT_URL='https://s3.fr-par.scw.cloud' -AWS_STORAGE_BUCKET_NAME='qfdmo-interface' -AIRFLOW_WEBSERVER_REFRESHACTEUR_URL=http://localhost:8080 -CORS_ALLOWED_ORIGINS=http://localhost:8000,http://127.0.0.1:8000 -AIRFLOW_CONN_QFDMO_DJANGO_DB=postgresql+psycopg2://qfdmo:qfdmo@localhost:6543/qfdmo \ No newline at end of file diff --git a/.secrets.baseline b/.secrets.baseline index a3d2dbe6c..0c72808f9 100644 --- a/.secrets.baseline +++ b/.secrets.baseline @@ -133,7 +133,7 @@ "filename": ".env.template", "hashed_secret": "ccffafd813756ba7475f90e3c210d08d8edeb761", "is_verified": false, - "line_number": 3 + "line_number": 1 } ], "README.md": [ @@ -207,5 +207,5 @@ } ] }, - "generated_at": "2024-11-21T09:58:18Z" + "generated_at": "2024-12-03T07:57:02Z" } diff --git a/core/settings.py b/core/settings.py index f824c8ea1..52480fce0 100644 --- a/core/settings.py +++ b/core/settings.py @@ -213,11 +213,7 @@ def context_processors(): readonly_settings = dj_database_url.parse(DB_READONLY) DATABASES = { - "default": { - **default_settings, - "CONN_MAX_AGE": 60, - "CONN_HEALTH_CHECKS": True, - }, + "default": default_settings, "readonly": readonly_settings, } @@ -225,7 +221,7 @@ def context_processors(): EXPLORER_DEFAULT_CONNECTION = "readonly" CONN_HEALTH_CHECKS = True -CONN_MAX_AGE = None +CONN_MAX_AGE = decouple.config("CONN_MAX_AGE", cast=int, default=0) # Password validation # https://docs.djangoproject.com/en/4.2/ref/settings/#auth-password-validators