The glanceclient.v1.legacy_shell Module

DEPRECATED functions that implement the same command line interface as the legacy glance client.

class glanceclient.v1.legacy_shell.PrettyTable

Bases: object

Creates an ASCII art table

Example:

ID Name Size Hits — —————– ———— —– 122 image 22 0
add_column(width, label='', just='l')

Add a column to the table

Parameters:
  • width – number of characters wide the column should be
  • label – column heading
  • just – justification for the column, ‘l’ for left, ‘r’ for right
make_header()
make_row(*args)
glanceclient.v1.legacy_shell.do_add(gc, args)

DEPRECATED! Use image-create instead.

glanceclient.v1.legacy_shell.do_clear(gc, args)

DEPRECATED!

glanceclient.v1.legacy_shell.do_delete(gc, args)

DEPRECATED! Use image-delete instead.

glanceclient.v1.legacy_shell.do_details(gc, args)

DEPRECATED! Use image-list instead.

glanceclient.v1.legacy_shell.do_image_members(gc, args)

DEPRECATED! Use member-list instead.

glanceclient.v1.legacy_shell.do_index(gc, args)

DEPRECATED! Use image-list instead.

glanceclient.v1.legacy_shell.do_member_add(gc, args)

DEPRECATED! Use member-create instead.

glanceclient.v1.legacy_shell.do_member_images(gc, args)

DEPRECATED! Use member-list instead.

glanceclient.v1.legacy_shell.do_members_replace(gc, args)

DEPRECATED!

glanceclient.v1.legacy_shell.do_show(gc, args)

DEPRECATED! Use image-show instead.

glanceclient.v1.legacy_shell.do_update(gc, args)

DEPRECATED! Use image-update instead.

glanceclient.v1.legacy_shell.get_image_fields_from_args(args)

Validate the set of arguments passed as field name/value pairs and return them as a mapping.

glanceclient.v1.legacy_shell.get_image_filters_from_args(args)

Build a dictionary of query filters based on the supplied args.

glanceclient.v1.legacy_shell.print_image_formatted(client, image)

Formatted print of image metadata.

Parameters:
  • client – The Glance client object
  • image – The image metadata
glanceclient.v1.legacy_shell.user_confirm(prompt, default=False)

Yes/No question dialog with user.

Parameters:
  • prompt – question/statement to present to user (string)
  • default – boolean value to return if empty string is received as response to prompt

This Page