def main(): closure_test = "Jeremy" def job(environ): import time for i in xrange(0, 10): time.sleep(1) print "%s | Hello, %s!" % (environ['current_host'], closure_test) return 42 eisenhower.execute(job, hosts = [ 'ssh://localhost', 'ssh://jeremy@some-remote-server' ])
def main(): #AWS section parser = argparse.ArgumentParser(description='Specifiy the command line arguments to run') parser.add_argument('--security',) #need to add command line args instances = aws(num_instances,ami_id,security_group,key_name) # need to shutdown each instance #eisenhower section closure_test = "Jeremy" def job(environ): import time for i in xrange(0, 10): time.sleep(1) print "%s | Hello, %s!" % (environ['current_host'], closure_test) return 42 eisenhower.execute(job, hosts = [ instances ]) #should be 'ssh://each_instance'