Created
July 22, 2020 11:50
-
-
Save khasky/c7404ec6b58d6af44afd3c7ec6a7bf04 to your computer and use it in GitHub Desktop.
Apache2 VPS http conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
ServerAdmin [email protected] | |
ServerName khasky.com | |
ServerAlias www.khasky.com | |
DocumentRoot /var/www/khasky.com/public_html | |
ErrorLog ${APACHE_LOG_DIR}/error.log | |
CustomLog ${APACHE_LOG_DIR}/access.log combined | |
RewriteEngine on | |
RewriteCond %{SERVER_NAME} =khasky.com [OR] | |
RewriteCond %{SERVER_NAME} =www.khasky.com | |
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent] | |
</VirtualHost> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment