os.getenv -> config.py

This commit is contained in:
xds
2026-02-19 13:00:51 +03:00
parent 4af5134726
commit dd0f8a1cb6
11 changed files with 48 additions and 52 deletions

View File

@@ -1,15 +1,14 @@
import asyncio
import os
from dotenv import load_dotenv
from config import settings
from adapters.s3_adapter import S3Adapter
async def test_s3():
load_dotenv()
endpoint = os.getenv("MINIO_ENDPOINT", "http://localhost:9000")
access_key = os.getenv("MINIO_ACCESS_KEY")
secret_key = os.getenv("MINIO_SECRET_KEY")
bucket = os.getenv("MINIO_BUCKET")
endpoint = settings.MINIO_ENDPOINT
access_key = settings.MINIO_ACCESS_KEY
secret_key = settings.MINIO_SECRET_KEY
bucket = settings.MINIO_BUCKET
print(f"Connecting to {endpoint}, bucket: {bucket}")