Exemplo n.º 1
0
def log_menu():
	menu = ['1. Upload logs','2. Remove log archives', '\n     0. Back']
	
	available = build_avaialbe(menu)
	loop = True
	while loop:
		show_menu(menu)
		choice = get_choice(available)
		if choice == '1':
			ds.getLogs(mobilityConfig, gwConfig, XMLconfig ,ldapConfig, dbConfig, trustedConfig, config_files, webConfig)
			print; ds.eContinue()
		elif choice == '2':
			ds.cleanLog()
			print; ds.eContinue()
		elif choice == '0':
			loop = False
			main_menu()
Exemplo n.º 2
0
def log_menu():
    menu = ['1. Upload logs', '2. Remove log archives', '\n     0. Back']

    available = build_avaialbe(menu)
    loop = True
    while loop:
        show_menu(menu)
        choice = get_choice(available)
        if choice == '1':
            ds.getLogs()
            print
            ds.eContinue()
        elif choice == '2':
            ds.cleanLog()
            print
            ds.eContinue()
        elif choice == '0':
            loop = False
            main_menu()
Exemplo n.º 3
0
# Change db pass
if args.db:
	ds.changeDBPass(config_files, XMLconfig)
	ds.eContinue()
	sys.exit(0)

# Run health check
if args.ghc:
	import dsapp_ghc as ghc
	ghc.generalHealthCheck(mobilityConfig, gwConfig, XMLconfig ,ldapConfig, dbConfig, trustedConfig, config_files, webConfig)
	print; ds.eContinue()
	sys.exit(0)

# Get / upload mobility logs
if args.upload:
	ds.getLogs(mobilityConfig, gwConfig, XMLconfig ,ldapConfig, dbConfig, trustedConfig, config_files, webConfig)
	print; ds.eContinue()
	sys.exit(0)

# Run nightly maintenance
if args.check:
	print ds.checkNightlyMaintenance(config_files, mobilityConfig)['output']
	print; ds.eContinue()
	sys.exit(0)

# Show sync status
if args.status:
	ds.showStatus(dbConfig)
	print; ds.eContinue()
	sys.exit(0)
Exemplo n.º 4
0
    ds.eContinue()
    sys.exit(0)

# Run health check
if args.ghc:
    logger.info("Running switch: gHealthCheck")
    import dsapp_ghc as ghc
    ghc.generalHealthCheck()
    print
    ds.eContinue()
    sys.exit(0)

# Get / upload mobility logs
if args.upload:
    logger.info("Running switch: uploadLogs")
    ds.getLogs()
    print
    ds.eContinue()
    sys.exit(0)

# Run nightly maintenance
if args.check:
    logger.info("Running switch: check")
    print ds.checkNightlyMaintenance()['output']
    print
    ds.eContinue()
    sys.exit(0)

# Show sync status
if args.status:
    logger.info("Running switch: status")