Redirect request to a complex multi parameter URL (like an AWS S3 presigned URL)

Is that possible?

I am thinking about doing this:

a. Client requests a file from S3 bucket.

b. Phoenix should call AWS to get a pre-signed URL.

c. Redirect the client to the pre-signed URL.

Here’s an example pre-signed URL:

How to do that in the controller? Thank you.

Can just redirect to an external URL via redirect(conn, external: "...url..."), where you getting an error with it?


Works perfectly.

1 Like