From a2267189aacf92e2a301afa77635c2cdafbcc9a3 Mon Sep 17 00:00:00 2001 From: Jairo Matos Da Rocha Date: Fri, 22 Nov 2024 15:38:54 -0300 Subject: [PATCH] https --- main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 28b9e48..9d06bd7 100644 --- a/main.py +++ b/main.py @@ -1,6 +1,7 @@ from contextlib import asynccontextmanager import json +import os import ee from fastapi import FastAPI, status @@ -64,7 +65,7 @@ async def http_exception_handler(request, exc): ) base_url = request.base_url - if settings.HTTPS: + if os.environ.get('HTTPS',False): base_url = f'{base_url}'.replace('http://', 'https://') return { 'request': request,