Answers for "apache2 https"

1

apache2 site

a2ensite example.com
a2dissite example.com

sudo systemctl restart apache2
sudo service apache2 restart
Posted by: Guest on October-21-2021
2

apache redirect http to https

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteCond %{HTTPS} off
    RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
</IfModule>
Posted by: Guest on December-21-2020

Browse Popular Code Answers by Language