Advertisement
Guest User

Untitled

a guest
Jul 13th, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.23 KB | None | 0 0
  1. <VirtualHost *:80>
  2. # The ServerName directive sets the request scheme, hostname and port that
  3. # the server uses to identify itself. This is used when creating
  4. # redirection URLs. In the context of virtual hosts, the ServerName
  5. # specifies what hostname must appear in the request's Host: header to
  6. # match this virtual host. For the default virtual host (this file) this
  7. # value is not decisive as it is used as a last resort host regardless.
  8. # However, you must set it for any further virtual host explicitly.
  9. ServerName countryName.domainName.org
  10.  
  11. ServerAdmin webmaster@localhost
  12. DocumentRoot /var/www/html/countryName
  13. #Added the three lines below 15/02/2016
  14. <Directory /var/www/html/countryName>
  15. Options -Indexes
  16. </Directory>
  17.  
  18. # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
  19. # error, crit, alert, emerg.
  20. # It is also possible to configure the loglevel for particular
  21. # modules, e.g.
  22. #LogLevel info ssl:warn
  23.  
  24. ErrorLog ${APACHE_LOG_DIR}/error.log
  25. CustomLog ${APACHE_LOG_DIR}/access.log combined
  26. RewriteEngine on
  27. RewriteCond %{SERVER_NAME} =countryName.domainName.org
  28. RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
  29. </VirtualHost>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement