Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
ISPConfig
ISPConfig 3
Commits
9fd93035
Commit
9fd93035
authored
Mar 02, 2016
by
Marius Burkard
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- make session.save_path overridable in php-fpm (Fixes #3791)
parent
93292a99
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
2 deletions
+10
-2
server/conf/php_fpm_pool.conf.master
server/conf/php_fpm_pool.conf.master
+1
-1
server/plugins-available/apache2_plugin.inc.php
server/plugins-available/apache2_plugin.inc.php
+5
-1
server/plugins-available/nginx_plugin.inc.php
server/plugins-available/nginx_plugin.inc.php
+4
-0
No files found.
server/conf/php_fpm_pool.conf.master
View file @
9fd93035
...
...
@@ -34,7 +34,7 @@ env[TEMP] = <tmpl_var name='document_root'>/tmp
<tmpl_if name='security_level' op='==' value='20'>
<tmpl_var name='enable_php_open_basedir'>php_admin_value[open_basedir] = <tmpl_var name='php_open_basedir'>
php_admin_value[session.save_path] = <tmpl_var name='document_root'>/tmp
<tmpl_if name='custom_session_save_path' op='!=' value='y'>
php_admin_value[session.save_path] = <tmpl_var name='document_root'>/tmp
</tmpl_if>
php_admin_value[upload_tmp_dir] = <tmpl_var name='document_root'>/tmp
php_admin_value[sendmail_path] = "/usr/sbin/sendmail -t -i -f webmaster@<tmpl_var name='domain'>"
</tmpl_if>
...
...
server/plugins-available/apache2_plugin.inc.php
View file @
9fd93035
...
...
@@ -3146,6 +3146,7 @@ class apache2_plugin {
}
}
$custom_session_save_path
=
false
;
if
(
$custom_php_ini_settings
!=
''
){
// Make sure we only have Unix linebreaks
$custom_php_ini_settings
=
str_replace
(
"
\r\n
"
,
"
\n
"
,
$custom_php_ini_settings
);
...
...
@@ -3161,6 +3162,7 @@ class apache2_plugin {
$value
=
trim
(
$value
);
if
(
$value
!=
''
){
$key
=
trim
(
$key
);
if
(
$key
==
'session.save_path'
)
$custom_session_save_path
=
true
;
switch
(
strtolower
(
$value
))
{
case
'0'
:
// PHP-FPM might complain about invalid boolean value if you use 0
...
...
@@ -3181,7 +3183,9 @@ class apache2_plugin {
}
}
}
$tpl
->
setVar
(
'custom_session_save_path'
,
(
$custom_session_save_path
?
'y'
:
'n'
));
$tpl
->
setLoop
(
'custom_php_ini_settings'
,
$final_php_ini_settings
);
$app
->
system
->
file_put_contents
(
$pool_dir
.
$pool_name
.
'.conf'
,
$tpl
->
grab
());
...
...
server/plugins-available/nginx_plugin.inc.php
View file @
9fd93035
...
...
@@ -2757,6 +2757,7 @@ class nginx_plugin {
}
}
$custom_session_save_path
=
false
;
if
(
$custom_php_ini_settings
!=
''
){
// Make sure we only have Unix linebreaks
$custom_php_ini_settings
=
str_replace
(
"
\r\n
"
,
"
\n
"
,
$custom_php_ini_settings
);
...
...
@@ -2772,6 +2773,7 @@ class nginx_plugin {
$value
=
trim
(
$value
);
if
(
$value
!=
''
){
$key
=
trim
(
$key
);
if
(
$key
==
'session.save_path'
)
$custom_session_save_path
=
true
;
switch
(
strtolower
(
$value
))
{
case
'0'
:
// PHP-FPM might complain about invalid boolean value if you use 0
...
...
@@ -2793,6 +2795,8 @@ class nginx_plugin {
}
}
$tpl
->
setVar
(
'custom_session_save_path'
,
(
$custom_session_save_path
?
'y'
:
'n'
));
$tpl
->
setLoop
(
'custom_php_ini_settings'
,
$final_php_ini_settings
);
$app
->
system
->
file_put_contents
(
$pool_dir
.
$pool_name
.
'.conf'
,
$tpl
->
grab
());
...
...
Alex
@savthegood
mentioned in issue
#4964 (closed)
·
Feb 25, 2018
mentioned in issue
#4964 (closed)
mentioned in issue #4964
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment