httpd.conf 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. ServerRoot "/etc/httpd"
  2. Include conf.modules.d/*.conf
  3. User apache
  4. Group apache
  5. ServerAdmin root@localhost
  6. <Directory />
  7. AllowOverride none
  8. </Directory>
  9. DocumentRoot "/var/www/html"
  10. <Directory "/var/www">
  11. AllowOverride None
  12. Require all granted
  13. </Directory>
  14. <Directory "/var/www/html">
  15. Options Indexes FollowSymLinks
  16. AllowOverride None
  17. Require all granted
  18. </Directory>
  19. DirectoryIndex index.php index.html
  20. <Files ".ht*">
  21. Require all denied
  22. </Files>
  23. ErrorLog "logs/error_log"
  24. LogLevel warn
  25. LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
  26. LogFormat "%h %l %u %t \"%r\" %>s %b" common
  27. LogFormat "%b" bytes
  28. CustomLog "logs/access_log" combined
  29. TypesConfig /etc/mime.types
  30. AddType application/x-compress .Z
  31. AddType application/x-gzip .gz .tgz
  32. AddType text/html .shtml
  33. AddOutputFilter INCLUDES .shtml
  34. #AddHandler cgi-script .cgi
  35. AddDefaultCharset UTF-8
  36. <IfModule mime_magic_module>
  37. MIMEMagicFile conf/magic
  38. </IfModule>
  39. EnableSendfile on
  40. <IfModule remoteip_module>
  41. RemoteIPHeader X-Real-IP
  42. LogFormat "%a %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
  43. LogFormat "%a %l %u %t \"%r\" %>s %b" common
  44. </IfModule>
  45. IncludeOptional conf.d/*.conf