コード例 #1
0
ファイル: fabfile.py プロジェクト: Athospd/thirty-min-app
def deploy_web():

	# Create New Instance
	instance = ec2.create_new_instance()

	# Set Env Host String
	env.host_string = "ec2-user@%s" % (instance.ip_address) 
	
	# Install Web
	connect_attempts = 0
	while connect_attempts <= 3:
		try:
			install_web()
			break
		except NetworkError:
			print "Failed to connect: used attempt %s of 3" % \
											(connect_attempts)
			connect_attempts += 1
			time.sleep(10)
		except:
			print "Failed to install_web"
			break

	return True
コード例 #2
0
def deploy_web():

    # Create New Instance
    instance = ec2.create_new_instance()

    # Set Env Host String
    env.host_string = "ec2-user@%s" % (instance.ip_address)

    # Install Web
    connect_attempts = 0
    while connect_attempts <= 3:
        try:
            install_web()
            break
        except NetworkError:
            print "Failed to connect: used attempt %s of 3" % \
                    (connect_attempts)
            connect_attempts += 1
            time.sleep(10)
        except:
            print "Failed to install_web"
            break

    return True
コード例 #3
0
ファイル: fabfile.py プロジェクト: Athospd/thirty-min-app
def create_instance():
	""" Just Creates an Amazon Instance """
	instance = ec2.create_new_instance()
	return instance
コード例 #4
0
def create_instance():
    """ Just Creates an Amazon Instance """
    instance = ec2.create_new_instance()
    return instance
コード例 #5
0
ファイル: fabfile.py プロジェクト: norkans7/thirty-min-app
def create_instance():
	""" Just Creates an Instance """
	instance = ec2.create_new_instance()