From: reyk Date: Sun, 3 Aug 2014 11:28:58 +0000 (+0000) Subject: More examples, include FastCGI for php and cgi-bin and logging. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=bf736b1f7be22ff8510a1f83f28396abe39e3473;p=openbsd More examples, include FastCGI for php and cgi-bin and logging. --- diff --git a/etc/examples/httpd.conf b/etc/examples/httpd.conf index 9c9513981f7..ea70315ffa0 100644 --- a/etc/examples/httpd.conf +++ b/etc/examples/httpd.conf @@ -1,4 +1,4 @@ -# $OpenBSD: httpd.conf,v 1.4 2014/07/30 10:05:14 reyk Exp $ +# $OpenBSD: httpd.conf,v 1.5 2014/08/03 11:28:58 reyk Exp $ # Macros ext_addr="egress" @@ -9,8 +9,24 @@ ext_addr="egress" # Servers server "default" { listen on $ext_addr port 80 + + # Logging is enabled by default, but it can be turned off per server + #no log + location "/pub/*" { directory auto index + log combined + } + + location "*.php" { + fastcgi socket "/run/php-fpm.sock" + } + + location "/cgi-bin/*" { + fastcgi + + # The /cgi-bin directory is outside of the document root + root "/" } }