]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/dmca/templates/default/apache.erb
cookstyle
[chef.git] / cookbooks / dmca / templates / default / apache.erb
index 373c63af276c800ccc7c110c52c8eb0bf0bbeedc..d59bb7e228a30a9d16c8896352c05213fd8ebafc 100644 (file)
   CustomLog /var/log/apache2/<%= @name %>-access.log combined
   ErrorLog /var/log/apache2/<%= @name %>-error.log
 
-  DocumentRoot <%= @directory %>/html
+  DocumentRoot <%= @directory %>
 
   Options -Indexes
-
-  ProxyFCGISetEnvIf "true" PHP_ADMIN_VALUE "open_basedir=<%= @directory %>/html/:/usr/share/php/:/tmp/\ndisable_functions=exec,shell_exec,system,passthru,popen"
 </VirtualHost>
 
-<Directory <%= @directory %>/html>
+<Directory <%= @directory %>>
   Require all granted
+
+  <FilesMatch ".+\.ph(ar|p|tml)$">
+    SetHandler "proxy:unix:/run/php/php-<%= @name %>-fpm.sock|fcgi://127.0.0.1"
+  </FilesMatch>
+</Directory>
+
+<Directory ~ "\.git">
+  Require all denied
 </Directory>