def METHOD_NAME():
    if config_opts['post_install']:
        if buildroot.chroot_was_initialized:
            commands.install_build_results(commands.build_results)
        else:
            commands.init()
            commands.install_build_results(commands.build_results)
            if config_opts["cleanup_on_success"]:
                log.info("Cleaning up build root ('cleanup_on_success=True')")
                commands.clean()
    if config_opts["createrepo_on_rpms"]:
        log.info("Running createrepo on binary rpms in resultdir")
        with buildroot.uid_manager:
            util.createrepo(config_opts, buildroot.resultdir)