コード例 #1
0
def installed():
    """
    Ensure that the supervisord is installed.

    If not present, supervisord is sudo() installed via ``easy_install``.
    
    Currently RHEL/CentOS flavored.
    """
    cuisine.select_package(option='yum')
    cuisine.command_ensure('easy_install', package='python-setuptools')
    if not cuisine.command_check('supervisord'):
        sudo('easy_install supervisor')
コード例 #2
0
    def install_prereqs(self):
        select_package(self.util.get_package_manager())

        vcs_to_pkg = {
            'git': 'git',
            'hg': 'mercurial',
        }
        package_ensure(vcs_to_pkg[self.vcs])

        command_ensure('python2.7')

        if not command_check('virtualenv'):
            package_ensure('python-virtualenv')

        for pkg in self.install_packages:
            package_ensure(pkg)
コード例 #3
0
def installed(version=None):
    """
    Ensure that the supervisord is installed.

    :param version: str; the exact version string to install (e.g. "3.0a12")

    If supervisord is not present, the package is sudo() installed via ``easy_install``.
    
    Currently RHEL/CentOS flavored.
    """
    cuisine.select_package(option='yum') 
    cuisine.command_ensure('easy_install', package='python-setuptools')
    if not cuisine.command_check('supervisord'):
        if version:
            sudo('easy_install supervisor==%s' % version)
        else:
            sudo('easy_install supervisor')