This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Need assistance with .htaccess on a subdomain with NextCloud
#1
Need assistance with .htaccess on a subdomain with NextCloud
The title sort of covers it. I have been banging my head against the wall with NextCloud. Everything is on a dedicated server and NextCloud works just fine if I do not try to have the .htaccess remove the "index.php" entry from its addresses for "pretty links."

Here is where I think I am at.

There is nothing wrong with NextCloud's .htaccess when I update it for removing the index.php - it looks like this:

Code:
#### DO NOT CHANGE ANYTHING ABOVE THIS LINE ####
ErrorDocument 403 /core/templates/403.php
ErrorDocument 404 /core/templates/404.php
<IfModule mod_rewrite.c>
 Options -MultiViews
 RewriteRule ^core/js/oc.js$ index.php [PT,E=PATH_INFO:$1]
 RewriteRule ^core/preview.png$ index.php [PT,E=PATH_INFO:$1]
 RewriteCond %{REQUEST_FILENAME} !\.(css|js|svg|gif|png|html|ttf|woff|ico|jpg|jpeg)$
 RewriteCond %{REQUEST_FILENAME} !core/img/favicon.ico$
 RewriteCond %{REQUEST_FILENAME} !/remote.php
 RewriteCond %{REQUEST_FILENAME} !/public.php
 RewriteCond %{REQUEST_FILENAME} !/cron.php
 RewriteCond %{REQUEST_FILENAME} !/core/ajax/update.php
 RewriteCond %{REQUEST_FILENAME} !/status.php
 RewriteCond %{REQUEST_FILENAME} !/ocs/v1.php
 RewriteCond %{REQUEST_FILENAME} !/ocs/v2.php
 RewriteCond %{REQUEST_FILENAME} !/updater/
 RewriteCond %{REQUEST_FILENAME} !/ocs-provider/
 RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/.*
 RewriteRule . index.php [PT,E=PATH_INFO:$1]
 RewriteBase /
 <IfModule mod_env.c>
   SetEnv front_controller_active true
   <IfModule mod_dir.c>
     DirectorySlash off
   </IfModule>
 </IfModule>
</IfModule>

To me, that looks proper and is backed up by everyone over in the NextCloud forums as being A-OK. I have also tried a number of variations from online and all of them fail. I get returned from NextCloud like these:

*forum image linking not working*

First attempt to navigate after .htaccess is updated.

and

Attempt to navigate to a folder in NextCloud with the updated .htaccess.

After all of the time put in this, I am at a point I am pretty positive it is Apache related and also Sentora related. I have the NextCloud site on a subdomain in Sentora (cloud.example.com) - I am pretty convinced considering my work with NextCloud and not finding a solution that it is something in the Sentora Vhosts or perhaps Global Sentora Config.

Can anyone point me in the right direction? As I mentioned after all the time put into this the only thing left is that it has to be a setting in Sentora Apache/php configuration. I have too much time in this simple issue to give up now, I want the "index.php" removed from my web addresses in NextCloud and I will settle for no less!  Undecided
Everyone makes mistakes, but to truly screw up it takes the root password!
Reply
Thanks given by:
#2
RE: Need assistance with .htaccess on a subdomain with NextCloud
Not sure buddy Sad
Make sure AllowOveride = All in httpd.conf
Check to see if it is also anywhere else in your configs..?
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by: worksmarter
#3
RE: Need assistance with .htaccess on a subdomain with NextCloud
(03-04-2017, 12:57 PM)TGates Wrote: Not sure buddy Sad
Make sure AllowOveride = All in httpd.conf
Check to see if it is also anywhere else in your configs..?

Yeah, I was hoping too that it was just a missing AllowOverride = All statement, but it is in there.

Thanks for commenting. This is such a strange issue - maybe a permissions thing; I will spin up a VM and see what happens.
Everyone makes mistakes, but to truly screw up it takes the root password!
Reply
Thanks given by:
#4
RE: Need assistance with .htaccess on a subdomain with NextCloud
Right on, good luck!
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by:


Possibly Related Threads…
Thread Author Replies Views Last Post
Public_html Inside Domain/Subdomain zHostingSolutions 2 5 ,031 07-23-2021, 09:57 AM
Last Post: Nigel
redirect error after letsencrypt + subdomain mizerek 1 4 ,841 08-06-2020, 04:54 AM
Last Post: mizerek
Global .htaccess for Sentora and/or Apache rsthomas 2 6 ,477 01-13-2020, 06:52 AM
Last Post: Vedran B

Forum Jump:


Users browsing this thread: 1 Guest(s)