Force HTTPS for entire domain

#1
Hi,

I would like to setup a global http -> https redirect for a specific domain on a cPanel server.
The server is running cPanel v60, EA4, LiteSpeed 5.1.10 with LSCache.

Currently I use:
Code:
RewriteCond %{HTTPS} !on
RewriteRule ^(.*)$ https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]
on each .htaccess file for every software installed under this domain. The domain has various software installations in subdirectories, ie:

domain.com/forum (forum software)
domain.com/blog (a WordPress site)
domain.com/support (helpdesk software)
etc

but I would prefer a single entry that would cover the entire site, so that I don't have to force HTTPS on each .htaccess file of every script. We want every request to this domain to redirect to HTTPS regardless of the URL it's hitting.
Could we add something into httpd.conf that would accomplish this?

btw: Is there any speed difference between entering the force https rewrite entry in httpd.conf or .htaccess in LiteSpeed?
 
Top