Guest User

Untitled

a guest
Jul 18th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.38 KB | None | 0 0
  1. RewriteEngine On
  2. RewriteBase /
  3. RewriteRule ^index.php$ - [L]
  4.  
  5. # add a trailing slash to /wp-admin
  6. RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
  7.  
  8. RewriteCond %{REQUEST_FILENAME} -f [OR]
  9. RewriteCond %{REQUEST_FILENAME} -d
  10. RewriteRule ^ - [L]
  11. RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
  12. RewriteRule ^([_0-9a-zA-Z-]+/)?(.*.php)$ $2 [L]
  13. RewriteRule . index.php [L]
  14.  
  15. <VirtualHost *:443>
  16. ServerName www.site1.com
  17. ServerAlias site1.com
  18.  
  19. SSLEngine on
  20. SSLCertificateFile "/usr/local/etc/letsencrypt/live/site1.com/cert.pem"
  21. SSLCertificateKeyFile "/usr/local/etc/letsencrypt/live/site1.com/privkey.pem"
  22. SSLCertificateChainFile "/usr/local/etc/letsencrypt/live/site1.com/fullchain.pem"
  23.  
  24. <FilesMatch ".(cgi|shtml|phtml|php)$">
  25. SSLOptions +StdEnvVars
  26. </FilesMatch>
  27.  
  28. BrowserMatch "MSIE [2-5]" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
  29. CustomLog "/var/log/httpd-ssl_request.log" "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x "%r" %b"
  30.  
  31. <Directory "/usr/local/www/apache24/data/">
  32. Options Indexes FollowSymLinks MultiViews
  33. AllowOverride All
  34. Require all granted
  35. </Directory>
  36.  
  37. ErrorLog "/var/log/site1.com.ssl-error.log"
  38. CustomLog "/var/log/site1.com.ssl-access_log" combined
  39. </VirtualHost>
  40.  
  41. <VirtualHost *:80>
  42. ServerName www.site1.com
  43. ServerAlias site1.com
  44.  
  45. Redirect permanent / https://site1.com/
  46. </VirtualHost>
Add Comment
Please, Sign In to add comment