mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2026-01-19 05:52:05 +01:00
Merge pull request #774 from bdgreenweb/patch-2
enforce disk quotation limit only in public_html
This commit is contained in:
@@ -764,10 +764,23 @@ Automatic backup failed for %s on %s.
|
||||
|
||||
if website.package.enforceDiskLimits:
|
||||
if config['DiskUsagePercentage'] >= 100:
|
||||
command = 'chattr -R +i /home/%s' % (website.domain)
|
||||
command = 'chattr -R +i /home/%s/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
command = 'chattr -R -i /home/%s/logs/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
command = 'chattr -R -i /home/%s/.trash/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
command = 'chattr -R -i /home/%s/backup/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
command = 'chattr -R -i /home/%s/incbackup/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
else:
|
||||
command = 'chattr -R -i /home/%s' % (website.domain)
|
||||
command = 'chattr -R -i /home/%s/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
## Calculate bw usage
|
||||
|
||||
Reference in New Issue
Block a user