From debfccb67c18b00bc9d468243fb7b4683bdf1b73 Mon Sep 17 00:00:00 2001 From: alexeh Date: Mon, 27 Feb 2023 20:40:56 +0300 Subject: [PATCH] tiler refactor --- tiler/app/middlewares/url_injector.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tiler/app/middlewares/url_injector.py b/tiler/app/middlewares/url_injector.py index 1c51f271d1..ab64c93b03 100644 --- a/tiler/app/middlewares/url_injector.py +++ b/tiler/app/middlewares/url_injector.py @@ -1,8 +1,9 @@ +from botocore.config import Config from fastapi.params import Query import boto3 from ..config.config import get_settings -s3 = boto3.client("s3") +s3 = boto3.client("s3", region_name="eu-west-3", config=Config(signature_version='s3v4')) bucket_name = get_settings().s3_bucket_name default_cog = get_settings().default_cog DATA_PATH_IN_S3 = 'processed/satelligence/' @@ -40,6 +41,7 @@ def s3_presigned_access(url: str | None = Query(default=None, description="Optio }, ExpiresIn=3600 ) + print("Generated pressigned URL: ", presigned_url) return presigned_url