/[smecontribs]/rpms/smeserver-shared-folders/contribs9/smeserver-shared-folders-0.3-support_php_fpm.patch
ViewVC logotype

Contents of /rpms/smeserver-shared-folders/contribs9/smeserver-shared-folders-0.3-support_php_fpm.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (show annotations) (download)
Thu Jul 13 13:21:25 2017 UTC (7 years, 4 months ago) by vip-ire
Branch: MAIN
CVS Tags: smeserver-shared-folders-0_3-11_el6_sme, smeserver-shared-folders-0_3-10_el6_sme, HEAD
Changes since 1.1: +3 -3 lines
* Thu Jul 13 2017 Daniel Berteaud <daniel@firewall-services.com> 0.3-10.sme
- Missing \n in httpd templates when using mod_fastcgi

1 diff -Nur smeserver-shared-folders-0.3/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/90e-smithAccess50shares smeserver-shared-folders-0.3_phpfpm/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/90e-smithAccess50shares
2 --- smeserver-shared-folders-0.3/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/90e-smithAccess50shares 2017-07-13 15:20:20.341603722 +0200
3 +++ smeserver-shared-folders-0.3_phpfpm/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/90e-smithAccess50shares 2017-07-13 15:19:49.045596077 +0200
4 @@ -120,20 +120,33 @@
5
6 if ($dynamicContent eq 'enabled') {
7 $OUT .= " Options +Includes\n";
8 - $OUT .= " AddType application/x-httpd-php .php .php3 .phtml\n";
9 - $OUT .= " AddType application/x-httpd-php-source .phps\n";
10 + if ($fastcgi_mod eq 'mod_fastcgi'){
11 + $OUT .= ' AddHandler php' . $key . '-fastcgi .php' . "\n";
12 + }
13 + elsif ($fastcgi_mod eq 'mod_proxy_fcgi'){
14 + my $version = $properties{'PHPVersion'} || '';
15 + $OUT .=<<"_EOF";
16 + <FilesMatch \.php\$>
17 + SetHandler "proxy:unix:/var/run/php-fpm/php$version-$key.sock|fcgi://localhost"
18 + </FilesMatch>
19 +_EOF
20 + }
21 + else{
22 + $OUT .= " AddType application/x-httpd-php .php .php3 .phtml\n";
23 + $OUT .= " AddType application/x-httpd-php-source .phps\n";
24
25 - my $basedir = $properties{PHPBaseDir}
26 - || ("/home/e-smith/files/shares/$key/");
27 - $OUT .= " php_admin_value open_basedir $basedir\n";
28 - $OUT .= " php_admin_flag register_globals on\n"
29 - if (($properties{PHPRegisterGlobals} || 'disabled') eq 'enabled');
30 - $OUT .= " php_admin_flag allow_url_fopen on\n"
31 - if (($properties{PHPAllowUrlFopen} || 'disabled') eq 'enabled');
32 - $OUT .= " php_admin_value memory_limit $properties{PHPMemoryLimit}\n"
33 - if ($properties{PHPMemoryLimit});
34 - $OUT .= " php_admin_value max_execution_time $properties{PHPMaxExecutionTime}\n"
35 - if ($properties{PHPMaxExecutionTime});
36 + my $basedir = $properties{PHPBaseDir}
37 + || ("/home/e-smith/files/shares/$key/");
38 + $OUT .= " php_admin_value open_basedir $basedir\n";
39 + $OUT .= " php_admin_flag register_globals on\n"
40 + if (($properties{PHPRegisterGlobals} || 'disabled') eq 'enabled');
41 + $OUT .= " php_admin_flag allow_url_fopen on\n"
42 + if (($properties{PHPAllowUrlFopen} || 'disabled') eq 'enabled');
43 + $OUT .= " php_admin_value memory_limit $properties{PHPMemoryLimit}\n"
44 + if ($properties{PHPMemoryLimit});
45 + $OUT .= " php_admin_value max_execution_time $properties{PHPMaxExecutionTime}\n"
46 + if ($properties{PHPMaxExecutionTime});
47 + }
48 }
49 else {
50 $OUT .= " DirectoryIndex index.shtml index.htm index.html\n";

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed