def get_vpc_id(conn, vpc_tag):
    """Return the vpc object queried by tag"""

    vpcs = conn.get_all_vpcs()

    for v in vpcs:
        if 'Name' in v.tags:
            if v.tags['Name'] == vpc_tag:
                return v