Image Management Command: image
List all images: ls
Entry:
lbg image ls
Summary:
usage: lbg image ls [-h] [-q] [-fa] [-s] [-pd] [-c] [-d] [-p PLATFORM] [-f FORMAT] [--csv] [--json] [--yaml] [--table] [--noheader]
options:
-h, --help show this help message and exit
-q, --quiet only show node id
-fa, --failed only show failed image
-s, --scheduling only show scheduling image
-pd, --pending only show pending image
-c, --completed only show completed image
-d, --deleted only show deleted image
-p PLATFORM, --platform PLATFORM
only show selected platform image
-f FORMAT, --format FORMAT
change header format
--csv output with csv format
--json output with json format
--yaml output with yaml format
--table output with table format
--noheader does not print header information
Parameter Description:
Parameter | Abbreviation | Description | Required |
---|---|---|---|
--quiet | -q | Only show Image ID | No |
--failed | -fa | Only show failed images | No |
--scheduling | -s | Only show scheduling images | No |
--pending | -pd | Only show pending images | No |
--completed | -c | Only show completed images | No |
--platform | -p | Only show images available under this platform | No |
Example:
$ lbg image ls
$ lbg image ls -p ali # Only display images with the platform ali
Snapshot to image: release
Entry:
lbg image release
Summary:
usage: lbg image release [-h] [-n NAME] [-c COMMENT] image_id
positional arguments:
image_id id of the image
options:
-h, --help show this help message and exit
-n NAME, --name NAME image name
-c COMMENT, --comment COMMENT
image comment
Parameter Description:
Parameter | Abbreviation | Description | Required |
---|---|---|---|
--name | -n | Image name | No |
--comment | -c | Image description | No |
Example:
$ lbg image release -n dpgen -c "dpgen backup" 253 # Convert snapshot id 253 to a custom image named dpgen with a description of "dpgen backup"
Delete snapshot/image: rm
Entry:
lbg image rm
Summary:
usage: lbg image rm [-h] [-f] image_id [image_id ...]
positional arguments:
image_id id of the image
options:
-h, --help show this help message and exit
-f, --force force delete the image
Parameter Description:
Parameter | Abbreviation | Description | Required |
---|---|---|---|
--force | -f | No prompt | No |
image_id | - | Image id to be deleted | No |
Example:
$ lbg image rm 546 213 # Delete image id 546 and 213