@el.provision_event(instance_reference=1)
    def _install_packages_on_instance(self, instance, cluster_context):
        processes = [p for p in self.node_processes if
                     p.ui_name in instance.node_group.node_processes]
        if processes is not None and len(processes) > 0:
            packages = self._get_packages(cluster_context, processes)
            cmd = cluster_context.distro.create_install_cmd(packages)
            with instance.remote() as r:
                r.execute_command(cmd, run_as_root=True,
                                  timeout=_INSTALL_PACKAGES_TIMEOUT)
dataset/ETHPy150Open openstack/sahara/sahara/plugins/mapr/domain/service.py/Service._install_packages_on_instance/original