Umask 026

Tuning {
	NumConnections 64
	BufSize 12288
	InputBufSize 2048
	ScriptBufSize 4096
	NumHeaders 100
	Timeout 60
	ScriptTimeout 60
}

User www-data
StayRoot On

PIDFile /var/run/mathopd.pid
Log /var/log/mathopd/access.log
ErrorLog /var/log/mathopd/error.log

LogFormat {
	RemoteAddress
	RemoteUser
	Ctime
	ServerName
	LocalPort
	Method
	URI
	QueryString
	Version
	Status
	BytesRead
	Referer
	UserAgent
}

Control {
	ScriptUser nobody
	ChildLog /var/log/mathopd/child.log
	Types {
		text/html { html }
		text/plain { txt }
		image/gif { gif }
		image/jpeg { jpg }
		image/png { png }
		text/css { css }
		application/octet-stream { * }
	}
	Specials {
		Dump { /dump }
		CGI { cgi }
		Imagemap { map }
		Redirect { url }
	}
	External {
		/usr/bin/php { php }
	}
	IndexNames { index.html }
}

Server {
	Port 80
	Address 0.0.0.0
	Virtual {
		AnyHost
		Control {
			Alias /
			Location /var/www
		}
		Control {
			Alias /cgi-bin
			Location /usr/lib/cgi-bin
			Specials {
				CGI { * }
			}
		}
		Control {
			Alias /~
			Location public_html
			UserDirectory On
			RunScriptsAsOwner On
		}
		Control {
			Alias /~root
			Location /nosuchdirectory
		}
		Control {
			Alias /doc
			Location /usr/share/doc
			Access {
				Deny 0/0
				Allow 127.0.0.1/32
			}
		}
	}
}

