Advertisement
Guest User

Untitled

a guest
Mar 14th, 2016
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.47 KB | None | 0 0
  1. ############ Options you really have to take care of
  2. ####################
  3. ## modules to load
  4. # at least mod_access and mod_accesslog should be loaded
  5. # all other module should only be loaded if really neccesary
  6. # - saves some time
  7. # - saves memory
  8. server.modules = (
  9. # "mod_rewrite",
  10. # "mod_redirect",
  11. # "mod_alias",
  12. "mod_access",
  13. # "mod_cml",
  14. # "mod_trigger_b4_dl",
  15. # "mod_auth",
  16. # "mod_status",
  17. # "mod_setenv",
  18. # "mod_fastcgi",
  19. # "mod_proxy",
  20. "mod_simple_vhost",
  21. # "mod_evhost",
  22. # "mod_userdir",
  23. # "mod_cgi",
  24. # "mod_compress",
  25. # "mod_ssi",
  26. # "mod_usertrack",
  27. # "mod_expire",
  28. "mod_secdownload",
  29. # "mod_rrdtool",
  30. "mod_secdownload",
  31. "mod_flv_streaming",
  32. "mod_h264_streaming",
  33. "mod_accesslog" )
  34.  
  35.  
  36.  
  37.  
  38. ## a static document-root, for virtual-hosting take look at the
  39. ## server.virtual-* options
  40.  
  41. server.document-root = "/var/www/vhosts/domain.com/httpdocs"
  42.  
  43. $HTTP["host"] == "domain.com" {
  44. flv-streaming.extensions = ( ".flv" )
  45. h264-streaming.extensions = ( ".mp4", ".f4v" )
  46. h264-streaming.buffer-seconds = 10
  47. secdownload.secret = "secret"
  48. secdownload.document-root = "/var/www/vhosts/domain.com/httpdocs/media/videos/"
  49. secdownload.uri-prefix = "/video/"
  50. secdownload.timeout = "7200"
  51. server.document-root = "/var/www/vhosts/domain.com/httpdocs"
  52. }
  53.  
  54. $HTTP["host"] == "www.domain.com" {
  55. flv-streaming.extensions = ( ".flv" )
  56. h264-streaming.extensions = ( ".mp4", ".f4v" )
  57. h264-streaming.buffer-seconds = 10
  58. secdownload.secret = "secret"
  59. secdownload.document-root = "/var/www/vhosts/domain.com/httpdocs/media/videos/"
  60. secdownload.uri-prefix = "/video/"
  61. secdownload.timeout = "7200"
  62. server.document-root = "/var/www/vhosts/domain.com/httpdocs"
  63. }
  64.  
  65.  
  66.  
  67. ## where to send error-messages to
  68. server.errorlog = "/var/log/lighttpd/error.log"
  69. server.port = 8080
  70.  
  71. # files to check for if .../ is requested
  72. index-file.names = ( "index.php", "index.html",
  73. "index.htm", "default.htm" )
  74.  
  75. ## set the event-handler (read the performance section in the manual)
  76.  
  77. ## set the event-handler (read the performance section in the manual)
  78. # server.event-handler = "freebsd-kqueue" # needed on OS X
  79.  
  80. # mimetype mapping
  81. mimetype.assign = (
  82. ".rpm" => "application/x-rpm",
  83. ".pdf" => "application/pdf",
  84. ".sig" => "application/pgp-signature",
  85. ".spl" => "application/futuresplash",
  86. ".class" => "application/octet-stream",
  87. ".ps" => "application/postscript",
  88. ".torrent" => "application/x-bittorrent",
  89. ".dvi" => "application/x-dvi",
  90. ".gz" => "application/x-gzip",
  91. ".pac" => "application/x-ns-proxy-autoconfig",
  92. ".swf" => "application/x-shockwave-flash",
  93. ".tar.gz" => "application/x-tgz",
  94. ".tgz" => "application/x-tgz",
  95. ".tar" => "application/x-tar",
  96. ".zip" => "application/zip",
  97. ".mp3" => "audio/mpeg",
  98. ".m3u" => "audio/x-mpegurl",
  99. ".wma" => "audio/x-ms-wma",
  100. ".wax" => "audio/x-ms-wax",
  101. ".ogg" => "application/ogg",
  102. ".wav" => "audio/x-wav",
  103. ".gif" => "image/gif",
  104. ".jar" => "application/x-java-archive",
  105. ".jpg" => "image/jpeg",
  106. ".jpeg" => "image/jpeg",
  107. ".png" => "image/png",
  108. ".xbm" => "image/x-xbitmap",
  109. ".xpm" => "image/x-xpixmap",
  110. ".xwd" => "image/x-xwindowdump",
  111. ".css" => "text/css",
  112. ".html" => "text/html",
  113. ".htm" => "text/html",
  114. ".js" => "text/javascript",
  115. ".asc" => "text/plain",
  116. ".c" => "text/plain",
  117. ".cpp" => "text/plain",
  118. ".log" => "text/plain",
  119. ".conf" => "text/plain",
  120. ".text" => "text/plain",
  121. ".txt" => "text/plain",
  122. ".dtd" => "text/xml",
  123. ".xml" => "text/xml",
  124. ".mpeg" => "video/mpeg",
  125. ".mpg" => "video/mpeg",
  126. ".mov" => "video/quicktime",
  127. ".qt" => "video/quicktime",
  128. ".avi" => "video/x-msvideo",
  129. ".asf" => "video/x-ms-asf",
  130. ".asx" => "video/x-ms-asf",
  131. ".wmv" => "video/x-ms-wmv",
  132. # default mime type
  133. "" => "application/octet-stream",
  134. )
  135.  
  136.  
  137. # Use the "Content-Type" extended attribute to obtain mime type if
  138. #mimetype.use-xattr = "enable"
  139.  
  140.  
  141. ## send a different Server: header
  142. ## be nice and keep it at lighttpd
  143. # server.tag = "lighttpd"
  144.  
  145. #### accesslog module
  146. accesslog.filename = "/var/log/lighttpd/access.log"
  147.  
  148. ## deny access the file-extensions
  149. #
  150. # ~ is for backupfiles from vi, emacs, joe, ...
  151. # .inc is often used for code includes which should in general not be part
  152. # of the document-root url.access-deny = ( "~", ".in
  153.  
  154. ##
  155. # which extensions should not be handle via static-file transfer
  156. #
  157. # .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
  158.  
  159. debug.log-request-header = "enable"
  160. debug.log-response-header = "enable"
  161. debug.log-request-handling = "enable"
  162. debug.log-file-not-found = "enable"
  163.  
  164.  
  165. #server.username = "lighttpd"
  166. #server.groupname = "lighttpd"
  167.  
  168.  
  169.  
  170. $HTTP["url"] =~ "\.pdf$" {
  171. server.range-requests = "disable"
  172. }
  173. static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
  174. server.pid-file = "/var/run/lighttpd.pid"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement