コード例 #1
0
ファイル: vmware.py プロジェクト: vpejovski/automation
def check_vmware_tools():
    '''
    Check if the vmware tools are installed and running.
    '''
    common.disable_output()
    result = run('ps aux | grep -i vmtoolsd')
    if '/usr/sbin/vmtoolsd' in result:
        out = run('/usr/sbin/vmtoolsd -v')
        print env.host, green(' - VMWare tools running. ({0})'.format(out))
    else:
        print env.host, red(' - VMWare tools NOT running.')
コード例 #2
0
ファイル: splunk.py プロジェクト: vpejovski/automation
def check():
    """
    Checks if splunk has been installed and is running
    """
    common.disable_output()

    out = sudo('ls /apps/')

    if "splunkforwarder" in out:
        print(green(env.host + " Splunk is installed"))
    else:
        print(red(env.host + " Splunk is not installed"))