If Pleroma.Upload has a custom base_url, don't prefix path with "media"
As seen in lib/pleroma/upload.ex
:
defp url_from_spec(%__MODULE__{name: name}, base_url, {:file, path}) do
path =
URI.encode(path, &char_unescaped?/1) <>
if Pleroma.Config.get([__MODULE__, :link_name], false) do
"?name=#{URI.encode(name, &char_unescaped?/1)}"
else
""
end
[base_url, "media", path]
|> Path.join()
end
"media" is always hardcoded in here which requires you to have a "media" dir in your storage. That's not required for S3 buckets normally when you don't have a different base_url; the "/media" is only there for Pleroma's routing.
Edited by feld