mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2026-05-20 07:51:03 +02:00
enforce disk quotation limit only in public_html
lock only public_html directory when user exceed disk usage limit. Openlitespeed keep restarting when it failed to write logs and cache file inside users home/domain.com/logs/ directory. moreover user cant remove files from trash folder after directory become immutable. It's better to lock only public_html directory upon exceeding the disk quota limit.
This commit is contained in:
committed by
GitHub
parent
5abbceca2b
commit
17e6c63f2e
@@ -764,10 +764,10 @@ 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/public_html/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
else:
|
||||
command = 'chattr -R -i /home/%s' % (website.domain)
|
||||
command = 'chattr -R -i /home/%s/public_html/' % (website.domain)
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
## Calculate bw usage
|
||||
|
||||
Reference in New Issue
Block a user