remoção de arquivos desnecessários

This commit is contained in:
joao.herculano
2026-05-18 16:39:29 -03:00
parent 826fccf678
commit ab1445574f
7 changed files with 9 additions and 4 deletions
-1
View File
@@ -14,7 +14,6 @@ class LogIPMiddleware:
ip = self.get_client_ip(request)
# Loga o IP da requisição
print(f"Request from IP: {ip}")
logger.info(f"Request from IP: {ip} - Method: {request.method} - Path: {request.path}")
response = self.get_response(request)
+4 -1
View File
@@ -170,7 +170,10 @@ STATIC_ROOT = os.path.join(BASE_DIR, "staticfiles")
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
# CSRF e segurança
CSRF_TRUSTED_ORIGINS = os.getenv('CSRF_TRUSTED_ORIGINS', 'http://localhost:8000,http://127.0.0.1:8000').split(',')
CSRF_TRUSTED_ORIGINS = [origin.strip() for origin in os.getenv(
'CSRF_TRUSTED_ORIGINS',
'http://localhost:8000,http://127.0.0.1:8000'
).split(',') if origin.strip()]
SESSION_COOKIE_SECURE = not DEBUG
CSRF_COOKIE_SECURE = not DEBUG
SESSION_COOKIE_HTTPONLY = True