Mini Shell

Direktori : /usr/share/lve-stats/
Upload File :
Current File : //usr/share/lve-stats/lvechart.py

# coding=utf-8
#
# Copyright © Cloud Linux GmbH & Cloud Linux Software, Inc 2010-2019 All Rights Reserved
#
# Licensed under CLOUD LINUX LICENSE AGREEMENT
# http://cloudlinux.com/docs/LICENSE.TXT
from __future__ import absolute_import

import sys
from lvestats.lib.chart.lvechartmain import LveChart
from clcommon.lib.cledition import lve_supported_or_exit
from clcommon.utils import silence_stdout_until_process_exit
import lvestats.lib.config as config
import lvestats.lib.commons.decorators

__author__ = 'shaman'


@lvestats.lib.commons.decorators.no_sigpipe
@lve_supported_or_exit
def main(cnf):
    result = LveChart(cnf).main(args=sys.argv[1:])
    silence_stdout_until_process_exit()
    return result


if __name__ == '__main__':
    try:
        exitcode = main(config.read_config())
    except config.ConfigError as ce:
        ce.log_and_exit()
    else:
        sys.exit(exitcode)

Zerion Mini Shell 1.0