TEXT   22

Debian lighttpd configuration

Guest on 7th June 2022 01:15:09 AM

  1. # Debian lighttpd configuration file
  2. #
  3. server.modules              = (
  4.             "mod_access",
  5.             "mod_alias",
  6.             "mod_accesslog",
  7.            "mod_rewrite",
  8.            "mod_redirect",
  9.            "mod_status",
  10.            "mod_compress"
  11.  )
  12. ## a static document-root, for virtual-hosting take look at the
  13. ## server.virtual-* options
  14. server.document-root       = "/home/lighttpd"
  15.  
  16. ## where to send error-messages to
  17. server.errorlog            = "/var/log/lighttpd/error.log"
  18.  
  19. ## files to check for if .../ is requested
  20. index-file.names           = ( "index.php", "index.html",
  21.                                "index.htm", "default.htm" )
  22. #### accesslog module
  23. accesslog.filename         = "/var/log/lighttpd/access.log"
  24.  
  25. ## deny access the file-extensions
  26. #
  27. # ~    is for backupfiles from vi, emacs, joe, ...
  28. # .inc is often used for code includes which should in general not be part
  29. #      of the document-root
  30. url.access-deny            = ( "~", ".inc" )
  31.  
  32. ######### Options that are good to be but not neccesary to be changed #######
  33.  
  34. ## bind to port (default: 80)
  35. server.port               = 80
  36.  
  37. ## bind to localhost only (default: all interfaces)
  38. #server.bind                = "Server-IP-ADDRESS"
  39.  
  40. ## error-handler for status 404
  41. server.error-handler-404  = "/error-handler.php"
  42.  
  43. ## to help the rc.scripts
  44. server.pid-file            = "/var/run/lighttpd.pid"
  45.  
  46. ## virtual directory listings
  47. dir-listing.encoding        = "utf-8"
  48. server.dir-listing          = "enable"
  49.  
  50. ### only root can use these options
  51. #
  52. # chroot() to directory (default: no chroot() )
  53. server.chroot            = "/webroot"
  54.  
  55. ## change uid to <uid> (default: don't care)
  56. server.username            = "www-data"
  57.  
  58. ## change uid to <uid> (default: don't care)
  59. server.groupname           = "www-data"
  60.  
  61. #### compress module
  62. compress.cache-dir          = "/var/tmp/lighttpd/cache/compress/"
  63. compress.filetype           = ("text/plain", "text/html")
  64.  
  65. #### external configuration files
  66. ## mimetype mapping
  67. include_shell "/usr/share/lighttpd/create-mime.assign.pl"
  68.  
  69. ## load enabled configuration files,
  70. ## read /etc/lighttpd/conf-available/README first
  71. include_shell "/usr/share/lighttpd/include-conf-enabled.pl"

Raw Paste


Login or Register to edit or fork this paste. It's free.