mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-12-24 07:37:04 +00:00
add configurable backup dir to status checks
This commit is contained in:
parent
69e15fa942
commit
727d84004f
@ -20,6 +20,7 @@ from ssl_certificates import get_ssl_certificates, get_domain_ssl_files, check_c
|
|||||||
from mailconfig import get_mail_domains, get_mail_aliases
|
from mailconfig import get_mail_domains, get_mail_aliases
|
||||||
|
|
||||||
from utils import shell, sort_domains, load_env_vars_from_file, load_settings
|
from utils import shell, sort_domains, load_env_vars_from_file, load_settings
|
||||||
|
from backup import get_backup_root
|
||||||
|
|
||||||
def get_services():
|
def get_services():
|
||||||
return [
|
return [
|
||||||
@ -261,7 +262,7 @@ def check_free_disk_space(rounded_values, env, output):
|
|||||||
# Check that there's only one duplicity cache. If there's more than one,
|
# Check that there's only one duplicity cache. If there's more than one,
|
||||||
# it's probably no longer in use, and we can recommend clearing the cache
|
# it's probably no longer in use, and we can recommend clearing the cache
|
||||||
# to save space. The cache directory may not exist yet, which is OK.
|
# to save space. The cache directory may not exist yet, which is OK.
|
||||||
backup_cache_path = os.path.join(env['STORAGE_ROOT'], 'backup/cache')
|
backup_cache_path = os.path.join(get_backup_root(env), 'cache')
|
||||||
try:
|
try:
|
||||||
backup_cache_count = len(os.listdir(backup_cache_path))
|
backup_cache_count = len(os.listdir(backup_cache_path))
|
||||||
except:
|
except:
|
||||||
|
Loading…
Reference in New Issue
Block a user