更新时间:2024-04-30 GMT+08:00

查询镜像构建模板

ma-cli提供了一些常用的镜像构建模板,模板中包含了在ModelArts Notebook上进行Dockerfile开发的牵引指导。

$ ma-cli image get-template -h
Usage: ma-cli image get-template [OPTIONS]

  List build-in dockerfile templates.

  Example:

  # List build-in dockerfile templates
  ma-cli image get-template [--filer <filter_info>]  [--page-num <yourPageNum>] [--page-size <yourPageSize>]

Options:
  --filter TEXT                   filter by keyword.
  -pn, --page-num INTEGER RANGE   Specify which page to query.  [x>=1]
  -ps, --page-size INTEGER RANGE  The maximum number of results for this query.  [x>=1]
  -D, --debug                     Debug Mode. Shows full stack trace when error occurs.
  -P, --profile TEXT              CLI connection profile to use. The default profile is "DEFAULT".
  -H, -h, --help                  Show this message and exit.
(PyTorch-1.4) [ma-user work]$
表1 参数说明

参数名

参数类型

是否必选

参数说明

--filter

String

根据模板名称关键字过滤模板列表。

-pn / --page-num

Int

镜像页索引,默认是第1页。

-ps / --page-size

Int

每页显示的镜像数量,默认是20。

示例

查看镜像构建模板。

ma-cli image get-template