~andrewjbeach/juju-ci-tools/make-local-patcher

« back to all changes in this revision

Viewing changes to deploy_stack.py

  • Committer: Curtis Hovey
  • Date: 2015-06-11 19:35:22 UTC
  • mto: This revision was merged to the branch mainline in revision 983.
  • Revision ID: curtis@canonical.com-20150611193522-o2nqkqb04o2i75wv
Remove euca_dump_logs because it has not been used this year.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
    temp_bootstrap_env,
30
30
)
31
31
from substrate import (
32
 
    dump_euca_console,
33
 
    get_job_instances,
 
32
    destroy_job_instances,
34
33
    LIBVIRT_DOMAIN_RUNNING,
35
34
    run_instances,
36
35
    start_libvirt_domain,
84
83
        destroy_job_instances(instance_tag)
85
84
 
86
85
 
87
 
def destroy_job_instances(job_name):
88
 
    instances = list(get_job_instances(job_name))
89
 
    if len(instances) == 0:
90
 
        return
91
 
    subprocess.check_call(['euca-terminate-instances'] + instances)
92
 
 
93
 
 
94
86
def deploy_dummy_stack(client, charm_prefix):
95
87
    """"Deploy a dummy stack in the specified environment.
96
88
    """
164
156
    return ''.join(random.choice(allowed_chars) for n in range(20))
165
157
 
166
158
 
167
 
def dump_env_logs(client, bootstrap_host, directory, host_id=None,
168
 
                  jenv_path=None):
 
159
def dump_env_logs(client, bootstrap_host, directory, jenv_path=None):
169
160
    machine_addrs = get_machines_for_logs(client, bootstrap_host)
170
161
 
171
162
    for machine_id, addr in machine_addrs.iteritems():
175
166
        local_state_server = client.env.local and machine_id == '0'
176
167
        dump_logs(client, addr, machine_directory,
177
168
                  local_state_server=local_state_server)
178
 
 
179
 
    dump_euca_console(host_id, directory)
180
169
    retain_jenv(jenv_path, directory)
181
170
 
182
171