Steps to reproduce
- Use a reverse proxy that maps /nextcloud to / (e.g. Traefik with
PathPrefixStrip)
- The prefix will be available as the
X-Forwarded-Prefix header
Expected behaviour
Generated URLs should respect the prefix, e.g. add /nextcloud
Actual behaviour
The provided prefix is ignored and assets use an URL without the prefix.
As a workaround the prefix can be added to the overwritewebroot config option.
e.g.
if (isset($_SERVER['HTTP_X_FORWARDED_PREFIX'])) {
$CONFIG['overwritewebroot'] = $_SERVER['HTTP_X_FORWARDED_PREFIX'];
}
Steps to reproduce
PathPrefixStrip)X-Forwarded-PrefixheaderExpected behaviour
Generated URLs should respect the prefix, e.g. add
/nextcloudActual behaviour
The provided prefix is ignored and assets use an URL without the prefix.
As a workaround the prefix can be added to the
overwritewebrootconfig option.e.g.