import os import sys sys.path.append(os.path.dirname(__file__)) from core import src if __name__ == '__main__': src.run()
# -*- coding: utf-8 -*- ''' 系统界面 ''' import os, sys from core.src import run #1.添加环境变量 BASE_PATH = sys.path.append(os.path.dirname('__file__')) if __name__ == '__main__': run()
def client(): c = socket.socket() c.connect(("127.0.0.1", 8888)) src.run(c)
import os, sys path = os.path.dirname(__file__) sys.path.append(path) from core import src if __name__ == '__main__': src.run()
# -*- coding: utf-8 -*- # @Author: BigHead import sys import os sys.path.append(os.path.dirname(os.path.dirname(__file__))) from core import src from lib import common_log logger = common_log.get_logger(__name__) BASE_DIR = os.path.dirname(os.path.dirname(__file__)) if __name__ == "__main__": # 定义 RDS 需要查询的 Key try: src.run( 'MySQL_Sessions,MySQL_InnoDBDataReadWriten,MySQL_InnoDBBufferRatio,MySQL_QPSTPS' ) except Exception as e: logger.error(e)
def logout(): src.run()