Ejemplo n.º 1
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')

    client = XoClient(base_url=url, keyfile=key_file)
    client.create(name=name)

    if args.wait:
        client.wait_for_commit()
Ejemplo n.º 2
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')

    client = XoClient(base_url=url, keyfile=key_file)
    client.create(name=name)

    if args.wait:
        client.wait_for_commit()
Ejemplo n.º 3
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')

    client = XoClient(base_url=url, keyfile=key_file)

    if args.wait and args.wait > 0:
        response = client.create(name, wait=args.wait)
    else:
        response = client.create(name)

    print("Response: {}".format(response))
Ejemplo n.º 4
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')

    client = XoClient(base_url=url,
                      keyfile=key_file)
    response = client.create(name)
    print("Response: {}".format(response))
Ejemplo n.º 5
0
def do_create(args):
    name = args.name

    url = _get_url(args)
    keyfile = _get_keyfile(args)
    auth_user, auth_password = _get_auth_info(args)

    client = XoClient(base_url=url, keyfile=keyfile)

    if args.wait and args.wait > 0:
        response = client.create(name,
                                 wait=args.wait,
                                 auth_user=auth_user,
                                 auth_password=auth_password)
    else:
        response = client.create(name,
                                 auth_user=auth_user,
                                 auth_password=auth_password)

    print("Response: {}".format(response))
Ejemplo n.º 6
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')
    auth_user, auth_password = _get_auth_info(args)

    client = XoClient(base_url=url, keyfile=key_file)

    if args.wait and args.wait > 0:
        response = client.create(
            name, wait=args.wait,
            auth_user=auth_user,
            auth_password=auth_password)
    else:
        response = client.create(
            name, auth_user=auth_user,
            auth_password=auth_password)

    print("Response: {}".format(response))
Ejemplo n.º 7
0
def do_create(args):
    name = args.name

    url = _get_url(args)
    keyfile = _get_keyfile(args)
    auth_user, auth_password = _get_auth_info(args)

    client = XoClient(base_url=url, keyfile=keyfile)

    if args.wait and args.wait > 0:
        response = client.create(
            name, wait=args.wait,
            auth_user=auth_user,
            auth_password=auth_password)
    else:
        response = client.create(
            name, auth_user=auth_user,
            auth_password=auth_password)

    print("Response: {}".format(response))
Ejemplo n.º 8
0
def do_create(args, config):
    name = args.name

    url = config.get('DEFAULT', 'url')
    key_file = config.get('DEFAULT', 'key_file')
    auth_user, auth_password = _get_auth_info(args)

    client = XoClient(base_url=url, keyfile=key_file)

    if args.wait and args.wait > 0:
        response = client.create(name,
                                 wait=args.wait,
                                 auth_user=auth_user,
                                 auth_password=auth_password)
    else:
        response = client.create(name,
                                 auth_user=auth_user,
                                 auth_password=auth_password)

    print("Response: {}".format(response))