File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ session.save_handler = files
3030; where MODE is the octal representation of the mode. Note that this
3131; does not overwrite the process's umask.
3232; https://php.net/session.save-path
33- session.save_path = " /var/lib/php-zts /session"
33+ session.save_path = " @varlibdir@ /session"
3434
3535; Whether to use strict session mode.
3636; Strict session mode does not accept an uninitialized session ID, and
Original file line number Diff line number Diff line change @@ -131,4 +131,4 @@ daemonize = yes
131131; Include one or more files. If glob(3) exists, it is used to include a bunch of
132132; files from a glob(3) pattern. This directive can be used everywhere in the
133133; file.
134- include=$ confdir/fpm.d/*.conf
134+ include=@ confdir@ /fpm.d/*.conf
Original file line number Diff line number Diff line change @@ -766,7 +766,7 @@ user_dir =
766766
767767; Directory in which the loadable extensions (modules) reside.
768768; https://php.net/extension-dir
769- ; extension_dir = "$ libdir/modules"
769+ ; extension_dir = "@ libdir@ /modules"
770770; On windows:
771771; extension_dir = "ext"
772772
Original file line number Diff line number Diff line change @@ -433,6 +433,6 @@ php_admin_flag[log_errors] = on
433433; See warning about choosing the location of these directories on your system
434434; at http://php.net/session.save-path
435435php_value[session.save_handler] = files
436- php_value[session.save_path] = /var/lib/php-zts /session
437- php_value[soap.wsdl_cache_dir] = /var/lib/php-zts /wsdlcache
438- ;php_value[opcache.file_cache] = /var/lib/php-zts /opcache
436+ php_value[session.save_path] = @varlibdir@ /session
437+ php_value[soap.wsdl_cache_dir] = @varlibdir@ /wsdlcache
438+ ;php_value[opcache.file_cache] = @varlibdir@ /opcache
Original file line number Diff line number Diff line change @@ -21,7 +21,8 @@ public function getFpmConfig(): array
2121 $ prefix = CreatePackages::getPrefix ();
2222
2323 $ contents = file_get_contents (INI_PATH . '/php.ini ' );
24- $ contents = str_replace ('$libdir ' , getPhpLibdir (), $ contents );
24+ $ contents = str_replace ('@libdir@ ' , getPhpLibdir (), $ contents );
25+ $ contents = str_replace ('@varlib@ ' , getVarLibdir (), $ contents );
2526 // Replace ALL hardcoded /etc/php* paths with prefix-based conf dir
2627 $ contents = preg_replace ('#/etc/php[^/]*# ' , getConfdir (), $ contents );
2728 file_put_contents (TEMP_DIR . '/php.ini ' , $ contents );
@@ -70,6 +71,7 @@ public function getFpmConfig(): array
7071 'is_shared ' => false , // These are static extensions
7172 ]);
7273
74+ $ iniContents = str_replace ('@varlibdir@ ' , getVarLibdir (), $ iniContents );
7375 $ iniContents = preg_replace (
7476 [
7577 '#/usr/share/php[^/]*/# ' ,
Original file line number Diff line number Diff line change @@ -16,7 +16,8 @@ public function getFpmConfig(): array
1616 {
1717 $ prefix = CreatePackages::getPrefix ();
1818 $ contents = file_get_contents (INI_PATH . '/php-fpm.conf ' );
19- $ contents = str_replace ('$confdir ' , getConfdir (), $ contents );
19+ $ contents = str_replace ('@confdir@ ' , getConfdir (), $ contents );
20+ $ contents = str_replace ('@varlibdir@ ' , getVarLibdir (), $ contents );
2021 // Replace ALL hardcoded /var/log/php* paths with prefix-based paths
2122 $ contents = preg_replace ('#/var/log/php[^/]*/# ' , '/var/log/ ' . $ prefix . '/ ' , $ contents );
2223 // Also replace /var/log/php-fpm.log with prefix-based path
@@ -45,6 +46,7 @@ public function getFpmConfig(): array
4546
4647 // Process www.conf to replace ALL hardcoded paths
4748 $ wwwContents = file_get_contents (INI_PATH . '/www.conf ' );
49+ $ wwwContents = str_replace ('@varlibdir@ ' , getVarLibdir (), $ wwwContents );
4850 $ wwwContents = preg_replace (
4951 [
5052 '#/var/lib/php[^/]*/# ' ,
You can’t perform that action at this time.
0 commit comments