def test_install_jboss(self, m_json_load, m_system, m_check_call):
        commands.getoutput("echo test > test.txt")
        cplane_utils.JBOSS_DIR = '.'
        data = {'jboss': 'test.txt'}
        m_json_load.return_value = data
        cplane_utils.JBOSS_DIR = '.'
        cplane_utils.install_jboss()
        m_check_call.assert_called_with(['unzip', '-o', 'test.txt'])
        m_system.assert_called_with('export JBOSS_HOME=/opt/jboss/\
jboss-6.1.0.Final')
        commands.getoutput("rm -f  test.txt")
예제 #2
0
    def test_install_jboss(self, m_json_load, m_system, m_check_call):
        commands.getoutput("echo test > test.txt")
        cplane_utils.JBOSS_DIR = '.'
        data = {'jboss': 'test.txt'}
        m_json_load.return_value = data
        cplane_utils.JBOSS_DIR = '.'
        cplane_utils.install_jboss()
        m_check_call.assert_called_with(['unzip', '-o', 'test.txt'])
        m_system.assert_called_with('export JBOSS_HOME=/opt/jboss/\
jboss-6.1.0.Final')
        commands.getoutput("rm -f  test.txt")
예제 #3
0
def install():
    apt_update(fatal=True)
    pkgs = determine_packages()
    apt_install(pkgs, fatal=True)
    prepare_env()
    flush_upgrade_type()
    download_cplane_packages()
    install_jboss()
    install_jdk()
    cmd = "echo '#Added by cplane' >> /etc/hosts"
    os.system(cmd)
    if config('jboss-db-on-host'):
        install_oracle()
        configure_oracle()
    else:
        install_oracle_client()
        configure_oracle_client()
    cplane_installer()
    if config('intall-reboot-scripts') == 'y':
        install_reboot_scripts()
예제 #4
0
def install():
    apt_update(fatal=True)
    pkgs = determine_packages()
    apt_install(pkgs, fatal=True)
    prepare_env()
    flush_upgrade_type()
    download_cplane_packages()
    install_jboss()
    install_jdk()
    cmd = "echo '#Added by cplane' >> /etc/hosts"
    os.system(cmd)
    if config('jboss-db-on-host'):
        install_oracle()
        configure_oracle()
    else:
        install_oracle_client()
        configure_oracle_client()
    cplane_installer()
    if config('intall-reboot-scripts') == 'y':
        install_reboot_scripts()