Removed not needed puppet handler parts

This commit is contained in:
Jedrzej Nowak 2015-09-04 17:07:27 +02:00
parent 7d6790d312
commit 93d56cab92

View File

@ -12,70 +12,6 @@ from solar.core.provider import GitProvider
from solar import errors
# class ResourceSSHMixin(object):
# @staticmethod
# def _ssh_command(resource, *args, **kwargs):
# log.debug('SSH: %s', args)
# executor = fabric_api.run
# if kwargs.get('use_sudo', False):
# executor = fabric_api.sudo
# managers = [
# fabric_api.settings(**ResourceSSHMixin._fabric_settings(resource)),
# ]
# if 'cwd' in kwargs:
# managers.append(
# fabric_api.cd(kwargs['cwd'])
# )
# if 'env' in kwargs:
# managers.append(
# fabric_api.shell_env(**kwargs['env'])
# )
# if 'warn_only' in kwargs:
# managers.append(
# fabric_api.warn_only())
# with nested(*managers):
# return executor(' '.join(args))
# @staticmethod
# def _scp_command(resource, _from, _to, use_sudo=False):
# log.debug('SCP: %s -> %s', _from, _to)
# executor = partial(
# fabric_project.upload_project,
# remote_dir=_to,
# local_dir=_from,
# use_sudo=use_sudo
# )
# if os.path.isfile(_from):
# executor = partial(
# fabric_project.put,
# remote_path=_to,
# local_path=_from,
# use_sudo=use_sudo
# )
# with fabric_api.settings(**ResourceSSHMixin._fabric_settings(resource)):
# return executor()
# @staticmethod
# def _fabric_settings(resource):
# return {
# 'host_string': ResourceSSHMixin._ssh_command_host(resource),
# 'key_filename': resource.args['ssh_key'].value,
# }
# @staticmethod
# def _ssh_command_host(resource):
# return '{}@{}'.format(resource.args['ssh_user'].value,
# resource.args['ip'].value)
class LibrarianPuppet(object):
def __init__(self, resource, organization='openstack', transport_sync=None, transport_run=None):
self.resource = resource