]> Frank Brehm's Git Trees - config/berta/etc.git/commitdiff
committing changes in /etc after emerge run
authorFrank Brehm <frank@brehm-online.com>
Tue, 20 Dec 2016 16:59:54 +0000 (17:59 +0100)
committerFrank Brehm <frank@brehm-online.com>
Tue, 20 Dec 2016 16:59:54 +0000 (17:59 +0100)
Package changes:
+app-eselect/eselect-php-0.9.2

.etckeeper
apache2/modules.d/70_mod_php.conf [new file with mode: 0644]
apache2/modules.d/70_mod_php5.conf [new file with mode: 0644]

index ef828dfb729f74aff09dee17cb48c8e1cedeae4f..2ee3f88ef41fd93f02c74b1a3433605676c02a07 100755 (executable)
@@ -41,6 +41,8 @@ maybe chmod 0644 'apache2/modules.d/41_mod_http2.conf'
 maybe chmod 0644 'apache2/modules.d/45_mod_dav.conf'
 maybe chmod 0644 'apache2/modules.d/46_mod_ldap.conf'
 maybe chmod 0644 'apache2/modules.d/47_mod_dav_svn.conf'
+maybe chmod 0644 'apache2/modules.d/70_mod_php.conf'
+maybe chmod 0644 'apache2/modules.d/70_mod_php5.conf'
 maybe chmod 0755 'apache2/vhosts.d'
 maybe chmod 0644 'apache2/vhosts.d/.keep_www-servers_apache-2'
 maybe chmod 0644 'apache2/vhosts.d/00_default_ssl_vhost.conf'
diff --git a/apache2/modules.d/70_mod_php.conf b/apache2/modules.d/70_mod_php.conf
new file mode 100644 (file)
index 0000000..3f36ba4
--- /dev/null
@@ -0,0 +1,24 @@
+<IfDefine PHP>
+       # The mod_php.so symlink is controlled by
+       # eselect-php. However, the module name changed from
+       # php5_module to php7_module so we can't blindly load whatever
+       # is there. Instead we let eselect-php manage a small
+       # configuration file that loads the appropriate module.
+       Include "/var/lib/eselect-php/mod_php.conf"
+
+       # Tell apache that mod_php should handle PHP files.
+       #
+       # NOTE: Avoiding AddHandler/AddType for security (bug
+       # #538822). Please read the related news item!
+       <FilesMatch "\.(php|php[57]|phtml)$">
+               SetHandler application/x-httpd-php
+       </FilesMatch>
+
+       # PHP source files which are meant to be displayed as
+       # syntax-highlighted source code.
+       <FilesMatch "\.phps$">
+               SetHandler application/x-httpd-php-source
+       </FilesMatch>
+
+       DirectoryIndex index.php index.phtml
+</IfDefine>
diff --git a/apache2/modules.d/70_mod_php5.conf b/apache2/modules.d/70_mod_php5.conf
new file mode 100644 (file)
index 0000000..bd79f78
--- /dev/null
@@ -0,0 +1,28 @@
+###########
+# WARNING #
+###########
+#
+# This file is provided for backwards compatibility only. The Apache
+# PHP configuration is now located in 70_mod_php.conf and requires you
+# to set -DPHP in your Apache conf.d file. Please examine
+# 70_mod_php.conf and update your Apache configuration to use -DPHP
+# instead of -DPHP5. Afterwards you may delete this file.
+#
+<IfDefine PHP5>
+       # Load the module first
+       <IfModule !mod_php5.c>
+               LoadModule php5_module    modules/libphp5.so
+       </IfModule>
+
+       # Set it to handle the files
+       # NOTE: Avoiding AddHandler/AddType for security (bug #538822)
+       # NOTE: Please read the related news item!
+       <FilesMatch "\.(php|php5|phtml)$">
+               SetHandler application/x-httpd-php
+       </FilesMatch>
+       <FilesMatch "\.phps$">
+               SetHandler application/x-httpd-php-source
+       </FilesMatch>
+
+       DirectoryIndex index.php index.phtml
+</IfDefine>