Please help us by providing the following info. Before posting please also check the pinned “Known issues” threads and make sure that you’re running the latest available version for your oC release: Changelog - ownCloud
Steps to reproduce
Just visit the site
When visiting the site it is suppose to always re-direct to SSL.
It does not re-direct to HTTPS
Comes back with an error indicating to many redirects
Nothing
Server configuration
Operating system: CentOS 7
Web server: Apache
Database: Maria 10
PHP version: 7
ownCloud version (see ownCloud admin page): 9.1
Updated from an older ownCloud or fresh install: Fresh Install
ownCloud log (data/owncloud.log, see How to find webserver or OC logfile / enable php logfile):
Special configuration (external storage, external authentication, reverse proxy, server-side-encryption):
When I research the web on how to force a site to always redirect to HTTPS it indicates you need to make modifications in the .htaccess file. I know with Owncloud if you touch that file at all things can go wrong real fast. Has anyone sucessfully added SSL to their site and used the .htaccess method with no problems?
Pazu, many users have done what to get it working? I thought I was not supposed to touch the .htaccess file or Owncloud would not work properly. I tried inputting
several times into the .htaaccess file, so there must be something “off” with my VPS. It runs good without trying to run without using HTTPS, so I’ll keep at it and see what happens.
For those of you using SSL for your domain and Owncloud where exactly did you add this line of code that needs to be intered into the .htaccess file? The current .htaccess has loads of data in it already so I’m a little weary and confused about where to enter this line.
I’m using CentOS with Apache as well, and I actually have all the “Listen” entries commented out in my httpd.conf file. My VirtualHost line opening in httpd.conf is as follows:
That’s not an italic default. For some reason, even with “code” specified, it’s not letting me use underscores. So there should be a space after VirtualHost, then underscore default underscore:443
All my SSL parameters follow that. ServerName, SSLEngine on, SSLProtocol, etc.
I also don’t have a main .htaccess file. The conf.d/ssl.conf file has a Listen line as follows (with my server’s IP in the x’s:
Listen x.x.x.x:443 https
So I think probably that VirtualHosts default:443 is handling the redirect and nothing else really needs to be done? Seems cleaner this way and no need to redirect.