diff options
| author | Mike McQuaid | 2013-09-12 17:53:10 +0100 |
|---|---|---|
| committer | Mike McQuaid | 2013-09-12 17:53:23 +0100 |
| commit | ccf32d4e7b34c4ddff9820c313ba1b17f5c57af9 (patch) | |
| tree | 0c8cd2b5a5a5ff459b6bdeaaf7e23007fa746984 /Library | |
| parent | 3d22bf41eaebb3eaf24ce4ba898616e3d885abdc (diff) | |
| download | homebrew-ccf32d4e7b34c4ddff9820c313ba1b17f5c57af9.tar.bz2 | |
lighttpd: update caveats, document_root.
nginx uses var/www so lets use the same.
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Formula/lighttpd.rb | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/Library/Formula/lighttpd.rb b/Library/Formula/lighttpd.rb index 085faeaaf..f2b395c5f 100644 --- a/Library/Formula/lighttpd.rb +++ b/Library/Formula/lighttpd.rb @@ -50,6 +50,7 @@ class Lighttpd < Formula s.sub!(/^var\.home_dir\s*=\s*".+"$/,"var.home_dir = \"#{run_path}\"") s.sub!(/^var\.conf_dir\s*=\s*".+"$/,"var.conf_dir = \"#{config_path}\"") s.sub!(/^server\.port\s*=\s*80$/,'server.port = 8080') + s.sub!(/^server\.document-root\s*=\s*server_root + "\/htdocs"$/,'server.document-root = server_root') # get rid of "warning: please use server.use-ipv6 only for hostnames, not # without server.bind / empty address; your config will break if the kernel @@ -75,19 +76,19 @@ class Lighttpd < Formula run_path.mkpath end - def caveats; <<-EOS.undent - Docroot is: #{www_path}htdocs/ - - The default port has been set to 8080 so that lighttpd can run without sudo. + test do + system "#{bin}/lighttpd", '-t', '-f', "#{HOMEBREW_PREFIX}/etc/lighttpd.conf" + end - If you want to host pages on your local machine to the wider network you - can change the port to 80 in: #{config_path}lighttpd.conf + def caveats; <<-EOS.undent + Docroot is: #{www_path} - You will then need to run lighttpd as root: `sudo lighttpd -f #{config_path}lighttpd.conf`. + The default port has been set in #{config_path}lighttpd.conf to 8080 so that + lighttpd can run without sudo. EOS end - plist_options :manual => "lighttpd" + plist_options :manual => "lighttpd -f #{HOMEBREW_PREFIX}/etc/lighttpd.conf" def plist; <<-EOS.undent <?xml version="1.0" encoding="UTF-8"?> |
