Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pretty URLs fail to work if overwrite.cli.url has no trailing slash for the no subfolder case #11235

Closed
zapek opened this issue Sep 15, 2018 · 3 comments
Labels

Comments

@zapek
Copy link

zapek commented Sep 15, 2018

Steps to reproduce

  1. install nextcloud as webserver root
  2. try to get Pretty URLs working

Expected behaviour

Pretty URLs are working

Actual behaviour

sudo -u www-data php /var/www/nextcloud/occ maintenance:update:htaccess
returns
Error updating .htaccess file, not enough permissions or "overwrite.cli.url" set to an invalid URL?

Server configuration

Operating system: Ubuntu 18.04

Web server: Apache

Database: MySQL

PHP version: 7.2

Nextcloud version: (see Nextcloud admin page) 14.0

Updated from an older Nextcloud/ownCloud or fresh install: fresh

Where did you install Nextcloud from: nextcloud.com

If you follow the documentation here:
https://docs.nextcloud.com/server/14/admin_manual/installation/source_installation.html#pretty-urls

'overwrite.cli.url' => 'https://example.org',
'htaccess.RewriteBase' => '/',

This example is wrong, it should be https://example.org/ (with a trailing '/').

Otherwise in lib/private/Setup.php in updateHtaccess(), the parse_url($webRoot, PHP_URL_PATH) fails as there's no URL path.

@nextcloud-bot
Copy link
Member

GitMate.io thinks possibly related issues are #9350 (Change URL with overwrite.cli.url), #10678 (Pretty urls don't work after occ upgrade), #9634 (Kerberos SSO fails after configuring pretty urls), #6271 (Theming kills pretty URL), and #7547 ([Clarification Request or Bug] Pretty Urls does not work for me).

@kesselb
Copy link
Contributor

kesselb commented Sep 15, 2018

See also #10678

@zapek
Copy link
Author

zapek commented Sep 15, 2018

Indeed this is the same as #10678. Closing then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants