Exemplo n.º 1
0
def deploy():
    S3Bucket.create_bucket(defaults.S3_PHOTO_BUCKET)
    instance = LaunchEC2.launch_instance(cmd_shell=False)[0]
    sleeptime = 60
    print('sleeping for %d seconds' % sleeptime)
    time.sleep(sleeptime)

    print('attempting to connect to %s' % instance.public_dns_name)
    execute(deploy_photosite, hosts=[instance.public_dns_name])
Exemplo n.º 2
0
def undeploy():
    TerminateEC2.terminate_all()
    S3Bucket.delete_bucket(defaults.S3_PHOTO_BUCKET)