Open aidan-gee opened 1 year ago
I don't think the origin re-writing would is possible however, i think there may be a way around this. Watch this space!
I added 2 origins to cloudfront, one goes to lambda as default behavior (not @edge), changed sveltekit's config.kit.paths.assets
to ${ORIGIn}/_assets
the second origin has a origin_path of /_asset/*
and it routes all static assets to the secondary origin "s3", if i understand correctly this how im serving static files from s3 instead of the lambda function itself
Hi,
I believe it would be cheaper / faster to use a cloudfront function to route to static assets rather than Lambda@edge in some cases. It may be beneficial to have the option to choose