laking
2011-04-02 0930f5fc2fb0d46757cc6e8ba50efcb34e1f7d33
Added bugfix for php_open_basedir when client changes. line 293.
1 files modified
3 ■■■■■ changed files
server/plugins-available/apache2_plugin.inc.php 3 ●●●●● patch | view | raw | blame | history
server/plugins-available/apache2_plugin.inc.php
@@ -290,6 +290,9 @@
            exec('mv '.$data['old']['document_root'].' '.$new_dir);
            $app->log('Moving site to new document root: mv '.$data['old']['document_root'].' '.$new_dir,LOGLEVEL_DEBUG);
            // Handle the change in php_open_basedir
            $data['new']['php_open_basedir'] = str_replace($data['old']['document_root'],$data['new']['document_root'],$data['old']['php_open_basedir']);
            //* Change the owner of the website files to the new website owner
            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);