58 lines
2.2 KiB
Plaintext
58 lines
2.2 KiB
Plaintext
Removed transcoding support (#271)
|
|
|
|
|
|
Removed alpha-state transcoding (#271)
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
A few months ago, a basic transcoding feature was implemented. Due to the way
|
|
this feature was designed, it was slow, CPU intensive on the server side,
|
|
and very tightly coupled to the reverse-proxy configuration, preventing
|
|
it to work Apache2, for instance. It was also not compatible with Subsonic clients.
|
|
|
|
Based on that, we're currently removing support for transcoding
|
|
**in its current state**. The work on a better designed transcoding feature
|
|
can be tracked in https://code.eliotberriot.com/funkwhale/funkwhale/issues/272.
|
|
|
|
You don't have to do anything on your side, but you may want to remove
|
|
the now obsolete configuration from your reverse proxy file (nginx only)::
|
|
|
|
# Remove those blocks:
|
|
|
|
# transcode cache
|
|
proxy_cache_path /tmp/funkwhale-transcode levels=1:2 keys_zone=transcode:10m max_size=1g inactive=7d;
|
|
|
|
# Transcoding logic and caching
|
|
location = /transcode-auth {
|
|
include /etc/nginx/funkwhale_proxy.conf;
|
|
# needed so we can authenticate transcode requests, but still
|
|
# cache the result
|
|
internal;
|
|
set $query '';
|
|
# ensure we actually pass the jwt to the underlytin auth url
|
|
if ($request_uri ~* "[^\?]+\?(.*)$") {
|
|
set $query $1;
|
|
}
|
|
proxy_pass http://funkwhale-api/api/v1/trackfiles/viewable/?$query;
|
|
proxy_pass_request_body off;
|
|
proxy_set_header Content-Length "";
|
|
}
|
|
|
|
location /api/v1/trackfiles/transcode/ {
|
|
include /etc/nginx/funkwhale_proxy.conf;
|
|
# this block deals with authenticating and caching transcoding
|
|
# requests. Caching is heavily recommended as transcoding
|
|
# is a CPU intensive process.
|
|
auth_request /transcode-auth;
|
|
if ($args ~ (.*)jwt=[^&]*(.*)) {
|
|
set $cleaned_args $1$2;
|
|
}
|
|
proxy_cache_key "$scheme$request_method$host$uri$is_args$cleaned_args";
|
|
proxy_cache transcode;
|
|
proxy_cache_valid 200 7d;
|
|
proxy_ignore_headers "Set-Cookie";
|
|
proxy_hide_header "Set-Cookie";
|
|
add_header X-Cache-Status $upstream_cache_status;
|
|
proxy_pass http://funkwhale-api;
|
|
}
|
|
# end of transcoding logic
|