From a89eb2fde33d052a815767f17111a05a2b763e24 Mon Sep 17 00:00:00 2001 From: tbrehm <t.brehm@ispconfig.org> Date: Sat, 14 Feb 2009 15:58:32 +0000 Subject: [PATCH] Fixed moving of site when the client is changed. --- server/plugins-available/apache2_plugin.inc.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php index 3a5cbda09e..f88cff20d3 100644 --- a/server/plugins-available/apache2_plugin.inc.php +++ b/server/plugins-available/apache2_plugin.inc.php @@ -269,6 +269,11 @@ class apache2_plugin { 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); + $command = 'usermod'; + $command .= ' --home '.escapeshellcmd($data["new"]["document_root"]); + $command .= ' '.escapeshellcmd($data["new"]["system_user"]); + exec($command); + } //print_r($data); -- GitLab