blob: 774e674cc130c4b93ab109b3da09bf1007a908c7 [file] [log] [blame]
Alex Savatieievc9055712019-03-01 14:43:56 -06001import checker
2
3from cfg_checker.helpers import args_utils
4
5
6def do_report(args):
Alex41485522019-04-12 17:26:18 -05007 """Create package versions report, HTML
Alex Savatieievc9055712019-03-01 14:43:56 -06008
9 :args: - parser arguments
10 :return: - no return value
11 """
Alex41485522019-04-12 17:26:18 -050012 _type, _filename = args_utils.get_report_type_and_filename(args)
Alex Savatieievc9055712019-03-01 14:43:56 -060013
14 # init connection to salt and collect minion data
15 pChecker = checker.CloudPackageChecker()
16 # collect data on installed packages
17 pChecker.collect_installed_packages()
18 # diff installed and candidates
Alex Savatieiev3db12a72019-03-22 16:32:31 -050019 pChecker.collect_packages()
Alex Savatieievc9055712019-03-01 14:43:56 -060020 # report it
Alex41485522019-04-12 17:26:18 -050021 pChecker.create_report(_filename, rtype=_type, full=args.full)