- added yes/no to decide whether to store the default index-file to a new customers docroot or not, fixes #369

This commit is contained in:
Michael Kaufmann (d00p)
2010-09-07 10:46:50 +00:00
parent 1fee5d7242
commit e356957592
6 changed files with 17 additions and 4 deletions

View File

@@ -178,7 +178,10 @@ while($row = $db->fetch_array($result_tasks))
//check if admin of customer has added template for new customer directories
$destdir = makeCorrectDir($settings['system']['documentroot_prefix'] . '/' . $row['data']['loginname']);
storeDefaultIndex($row['data']['loginname'], $destdir, $cronlog, true);
if((int)$row['data']['store_defaultindex'] == 1)
{
storeDefaultIndex($row['data']['loginname'], $destdir, $cronlog, true);
}
$cronlog->logAction(CRON_ACTION, LOG_NOTICE, 'Running: chown -R ' . (int)$row['data']['uid'] . ':' . (int)$row['data']['gid'] . ' ' . escapeshellarg($settings['system']['documentroot_prefix'] . $row['data']['loginname']));
safe_exec('chown -R ' . (int)$row['data']['uid'] . ':' . (int)$row['data']['gid'] . ' ' . escapeshellarg($settings['system']['documentroot_prefix'] . $row['data']['loginname']));