예제 #1
0
def install_celery_plugin(plugin_url):

    """
    Installs celery tasks into the cloudify agent.

        1. Installs the plugin into the current python installation directory.
        2  Adds the python files into the agent includes directive.

    :param plugin_url: URL to an archive of the plugin.
    """

    command = 'cmd /c "{0}\Scripts\pip.exe install {1}"' \
        .format(sys.prefix, plugin_url)
    utils.LocalCommandRunner(
        logger=logger,
        host=utils.get_local_ip()
    ).run(command)
    plugin_name = plugin_utils.extract_plugin_name(plugin_url)
    module_paths = plugin_utils.extract_module_paths(plugin_name)
    _update_includes(module_paths)
예제 #2
0
def install_celery_plugin(plugin_url):
    '''

    Installs celery tasks into the cloudify agent.

        1. Installs the plugin into the current python installation directory.
        2  Adds the python files into the agent includes directive.

    :param plugin_url: URL to an archive of the plugin.
    :return:
    '''

    command = 'cmd /c "{0}\Scripts\pip.exe install --process-dependency-links {1}"'\
              .format(sys.prefix, plugin_url)
    LocalCommandRunner().run(command)

    plugin_name = plugin_utils.extract_plugin_name(plugin_url)

    module_paths = plugin_utils.extract_module_paths(plugin_name)

    _update_includes(module_paths)
예제 #3
0
def install_celery_plugin(plugin_url):

    '''

    Installs celery tasks into the cloudify agent.

        1. Installs the plugin into the current python installation directory.
        2  Adds the python files into the agent includes directive.

    :param plugin_url: URL to an archive of the plugin.
    :return:
    '''

    command = 'cmd /c "{0}\Scripts\pip.exe install --process-dependency-links {1}"'\
              .format(sys.prefix, plugin_url)
    LocalCommandRunner().run(command)

    plugin_name = plugin_utils.extract_plugin_name(plugin_url)

    module_paths = plugin_utils.extract_module_paths(plugin_name)

    _update_includes(module_paths)