Hello, is there an example of how I add s3 file as an attachment to prefect email task , I looked at the code and the current attachments param only support local uri , TIA
03/31/2022, 2:27 PM
I haven’t seen a ready example. You’d have to make your own version of the task and modify the existing task. I think you’d need to download that s3 file first
03/31/2022, 2:58 PM
@Prasanth Kothuri sending attachments in automated email tasks is difficult since attachments are generally considered a security risk. Is there any reason you couldn't send just a link to the S3 object in your email text message?
I remember I had a similar use case in the past and solved it using presigned URLs in S3. Basically, you send a normal email message, but within your message, you send a presigned URL that allows downloading the S3 object with a single click from within the email with no extra authentication because the URL is already presigned to be authenticated for up to 6 hours. LMK if you are interested in seeing an example.
03/31/2022, 3:02 PM
thats a great idea, our s3 is based on openstack ceph storage, I will check if we have presigned URL functionality