Skip to content

Commit 0930f5f

Browse files
author
laking
committed
Added bugfix for php_open_basedir when client changes. line 293.
1 parent e0db878 commit 0930f5f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

server/plugins-available/apache2_plugin.inc.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,9 @@ function update($event_name,$data) {
290290
exec('mv '.$data['old']['document_root'].' '.$new_dir);
291291
$app->log('Moving site to new document root: mv '.$data['old']['document_root'].' '.$new_dir,LOGLEVEL_DEBUG);
292292

293+
// Handle the change in php_open_basedir
294+
$data['new']['php_open_basedir'] = str_replace($data['old']['document_root'],$data['new']['document_root'],$data['old']['php_open_basedir']);
295+
293296
//* Change the owner of the website files to the new website owner
294297
exec('chown --recursive --from='.escapeshellcmd($data['old']['system_user']).':'.escapeshellcmd($data['old']['system_group']).' '.escapeshellcmd($data['new']['system_user']).':'.escapeshellcmd($data['new']['system_group']).' '.$new_dir);
295298

0 commit comments

Comments
 (0)