Esempio n. 1
0
                 # Speed up slow DH generation.
                 "dhparam__bits: ['128', '64']\n" % (ci_lib.key_file, ))

    with open(inventory_path, 'a') as fp:
        fp.writelines('%(name)s '
                      'ansible_host=%(hostname)s '
                      'ansible_port=%(port)d '
                      'ansible_python_interpreter=%(python_path)s '
                      '\n' % container for container in containers)

    print()
    print(' echo --- ansible/inventory/hosts: ---')
    ci_lib.run('cat ansible/inventory/hosts')
    print('---')
    print()

    # Now we have real host key checking, we need to turn it off
    os.environ['ANSIBLE_HOST_KEY_CHECKING'] = 'False'

interesting = ci_lib.get_interesting_procs()

with ci_lib.Fold('first_run'):
    ci_lib.run('debops common %s', ' '.join(sys.argv[1:]))

ci_lib.check_stray_processes(interesting, containers)

with ci_lib.Fold('second_run'):
    ci_lib.run('debops common %s', ' '.join(sys.argv[1:]))

ci_lib.check_stray_processes(interesting, containers)
Esempio n. 2
0
#!/usr/bin/env python
# Run the Mitogen tests.

import os

import ci_lib

os.environ.update({
    'MITOGEN_TEST_DISTRO': ci_lib.DISTRO,
    'MITOGEN_LOG_LEVEL': 'debug',
    'SKIP_ANSIBLE': '1',
})

if not ci_lib.have_docker():
    os.environ['SKIP_DOCKER_TESTS'] = '1'

interesting = ci_lib.get_interesting_procs()
ci_lib.run('./run_tests -v')
ci_lib.check_stray_processes(interesting)