Only proxy HTTP and HTTP urls via Media Proxy #860

Merged
floatingghost merged 2 commits from nopjmp/akkoma:media-proxy-only-http into develop 2025-01-03 15:25:14 +00:00
Contributor

We make an assumption that we are only proxying HTTP/HTTPS hosted
media through the media proxy endpoint.

Fixes: #859

We make an assumption that we are only proxying HTTP/HTTPS hosted media through the media proxy endpoint. Fixes: #859
Author
Contributor

The only test I had issues with was "redirects to media proxy URI in case of thumbnailing error" due to having installed html2ps and it was added as a delegate to ImageMagick allowed for the error to be converted into an image. I uninstalled html2ps and everything passed.

We probably don't want to convert html into any images, so if we don't want that I can look at making another PR to see about removing extra ImageMagick functionality.

The only test I had issues with was "redirects to media proxy URI in case of thumbnailing error" due to having installed html2ps and it was added as a delegate to ImageMagick allowed for the error to be converted into an image. I uninstalled html2ps and everything passed. We probably don't want to convert html into any images, so if we don't want that I can look at making another PR to see about removing extra ImageMagick functionality.
Member

cosmetic: mix format

Oh right, you’ve mentioned using elixir 1.14, but the style guide slightly changed with 1.15 or 1.16; sorry i forgot about that. Current develop is already mix format clean with current elixir. Apart from the first commit, i can confirm this patch is mix formatclean too, so just drop the first one and everything should be fine; thanks!

> cosmetic: mix format Oh right, you’ve mentioned using elixir 1.14, but the style guide slightly changed with 1.15 or 1.16; sorry i forgot about that. Current `develop` is already `mix format` clean with current elixir. Apart from the first commit, i can confirm this patch is `mix format`clean too, so just drop the first one and everything should be fine; thanks!
nopjmp force-pushed media-proxy-only-http from 8ea721a5f2 to ff5d197341 2024-12-17 02:35:23 +00:00 Compare
Author
Contributor

fixed, it was unclear what Elixir version I should be using. I'm not super familiar with Elixir so I wasn't aware formatting defaults changed between versions.

fixed, it was unclear what Elixir version I should be using. I'm not super familiar with Elixir so I wasn't aware formatting defaults changed between versions.
Member

it surprised me too when it happened `^^

it surprised me too when it happened `^^
Oneric approved these changes 2024-12-17 03:01:50 +00:00
floatingghost merged commit 67cdc38296 into develop 2025-01-03 15:25:14 +00:00
floatingghost deleted branch media-proxy-only-http 2025-01-03 15:25:15 +00:00
Sign in to join this conversation.
No description provided.