fix: aws storage construction (#895)

This commit is contained in:
Juan Diego García
2026-03-03 13:04:22 -05:00
committed by GitHub
parent ac46c60a7c
commit f5ec2d28cf
2 changed files with 273 additions and 4 deletions

View File

@@ -90,6 +90,9 @@ def get_dailyco_storage() -> Storage:
"""
Get storage config for Daily.co (for passing to Daily API).
Uses role_arn only — access keys are excluded because they're for
worker reads (get_source_storage), not for the Daily API.
Usage:
daily_storage = get_dailyco_storage()
daily_api.create_meeting(
@@ -100,13 +103,15 @@ def get_dailyco_storage() -> Storage:
Do NOT use for our file operations - use get_transcripts_storage() instead.
"""
# Fail fast if platform-specific config missing
if not settings.DAILYCO_STORAGE_AWS_BUCKET_NAME:
raise ValueError(
"DAILYCO_STORAGE_AWS_BUCKET_NAME required for Daily.co with AWS storage"
)
return Storage.get_instance(
name="aws",
settings_prefix="DAILYCO_STORAGE_",
from reflector.storage.storage_aws import AwsStorage
return AwsStorage(
aws_bucket_name=settings.DAILYCO_STORAGE_AWS_BUCKET_NAME,
aws_region=settings.DAILYCO_STORAGE_AWS_REGION or "us-east-1",
aws_role_arn=settings.DAILYCO_STORAGE_AWS_ROLE_ARN,
)