3.57. hammer 产品


操作产品

Usage:
    hammer product [OPTIONS] SUBCOMMAND [ARG] ...

Parameters:
 SUBCOMMAND                    Subcommand
 [ARG] ...                     Subcommand arguments

Subcommands:
 create                        Create a product
 delete, destroy               Destroy a product
 info, show                    Show a product
 list, index                   List products
 remove-sync-plan              Delete assignment sync plan and product
 set-sync-plan                 Assign sync plan to product
 synchronize                   Sync all repositories for a product
 update                        Updates a product
 update-proxy                  Updates an HTTP Proxy for a product

Options:
 -h, --help                    Print help

3.57.1. Hammer 产品创建

创建产品

Usage:
    hammer product create [OPTIONS]

Options:
 --description VALUE           Product description
 --gpg-key-id NUMBER           Identifier of the GPG key
 --label VALUE
 --name VALUE                  Product name
 --organization VALUE          Organization name to search by
 --organization-id NUMBER      ID of the organization
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 --ssl-ca-cert-id NUMBER       Idenifier of the SSL CA Cert
 --ssl-client-cert-id NUMBER   Identifier of the SSL Client Cert
 --ssl-client-key-id NUMBER    Identifier of the SSL Client Key
 --sync-plan VALUE             Sync plan name to search by
 --sync-plan-id NUMBER         Plan numeric identifier
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.2. Hammer 产品删除

销毁产品

Usage:
    hammer product <delete|destroy> [OPTIONS]

Options:
 --id NUMBER                   Product numeric identifier
 --name VALUE                  Product name to search by
 --organization VALUE          Organization name to search by
 --organization-id NUMBER
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.3. hammer 产品信息

显示产品

Usage:
    hammer product <info|show> [OPTIONS]

Options:
 --fields LIST                 Show specified fields or predefined field sets only. (See below)
 --id NUMBER                   Product numeric identifier
 --name VALUE                  Product name to search by
 --organization VALUE          Organization name to search by
 --organization-id NUMBER      Organization ID
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 -h, --help                    Print help

Predefined field sets:
  ---------------------|-----|---------|-----
  FIELDS               | ALL | DEFAULT | THIN
  ---------------------|-----|---------|-----
  Id                   | x   | x       | x
  Name                 | x   | x       | x
  Label                | x   | x       |
  Description          | x   | x       |
  Sync state (all)     | x   | x       |
  Sync state (last)    | x   | x       |
  Sync plan id         | x   | x       |
  Gpg/gpg key id       | x   | x       |
  Gpg/gpg key          | x   | x       |
  Organization         | x   | x       |
  Readonly             | x   | x       |
  Deletable            | x   | x       |
  Content/repo name    | x   | x       |
  Content/url          | x   | x       |
  Content/content type | x   | x       |
  ---------------------|-----|---------|-----

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.4. Hammer 产品列表

列出产品

Usage:
    hammer product <list|index> [OPTIONS]

Options:
 --available-for VALUE               Interpret specified object to return only Products that can be associated with
                                     specified object.  Only 'sync_plan' is supported.
 --custom BOOLEAN                    Return custom products only
 --enabled BOOLEAN                   Return enabled products only
 --fields LIST                       Show specified fields or predefined field sets only. (See below)
 --full-result BOOLEAN               Whether or not to show all results
 --include-available-content BOOLEAN Whether to include available content attribute in results
 --name VALUE                        Filter products by name
 --order VALUE                       Sort field and order, eg. 'id DESC'
 --organization VALUE                Organization name to search by
 --organization-id NUMBER            Filter products by organization
 --organization-label VALUE          Organization label to search by
 --organization-title VALUE          Organization title
 --page NUMBER                       Page number, starting at 1
 --per-page NUMBER                   Number of results per page to return
 --redhat-only BOOLEAN               Return Red Hat (non-custom) products only
 --search VALUE                      Search string
 --subscription VALUE                Subscription name to search by
 --subscription-id NUMBER            Filter products by subscription
 --sync-plan VALUE                   Sync plan name to search by
 --sync-plan-id NUMBER               Filter products by sync plan id
 -h, --help                          Print help

Predefined field sets:
  -------------|-----|---------|-----
  FIELDS       | ALL | DEFAULT | THIN
  -------------|-----|---------|-----
  Id           | x   | x       | x
  Name         | x   | x       | x
  Description  | x   | x       |
  Organization | x   | x       |
  Repositories | x   | x       |
  Sync state   | x   | x       |
  -------------|-----|---------|-----

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

Search / Order fields:
  description         text
  label               string
  name                string
  organization_id     integer
  redhat              Values: true, false

3.57.5. hammer product remove-sync-plan

删除分配同步计划和产品

Usage:
    hammer product remove-sync-plan [OPTIONS]

Options:
 --description VALUE           Product description
 --gpg-key-id NUMBER           Identifier of the GPG key
 --id NUMBER                   Product numeric identifier
 --name VALUE                  Product name
 --new-name VALUE              Product name
 --organization VALUE          Organization name to search by
 --organization-id NUMBER
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 --ssl-ca-cert-id NUMBER       Idenifier of the SSL CA Cert
 --ssl-client-cert-id NUMBER   Identifier of the SSL Client Cert
 --ssl-client-key-id NUMBER    Identifier of the SSL Client Key
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.6. hammer product set-sync-plan

为产品分配迁移计划

Usage:
    hammer product set-sync-plan [OPTIONS]

Options:
 --id NUMBER                   Product numeric identifier
 --name VALUE                  Product name to search by
 --new-name VALUE              Product name
 --organization VALUE          Organization name to search by
 --organization-id NUMBER
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 --ssl-ca-cert-id NUMBER       Idenifier of the SSL CA Cert
 --ssl-client-cert-id NUMBER   Identifier of the SSL Client Cert
 --ssl-client-key-id NUMBER    Identifier of the SSL Client Key
 --sync-plan VALUE             Sync plan name to search by
 --sync-plan-id NUMBER         Plan numeric identifier
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.7. Hammer 产品同步

同步产品的所有软件仓库

Usage:
    hammer product synchronize [OPTIONS]

Options:
 --async                       Do not wait for the task
 --id NUMBER                   Product ID
 --name VALUE                  Product name to search by
 --organization VALUE          Organization name to search by
 --organization-id NUMBER
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.8. Hammer 产品更新

更新产品

Usage:
    hammer product update [OPTIONS]

Options:
 --description VALUE           Product description
 --gpg-key-id NUMBER           Identifier of the GPG key
 --id NUMBER                   Product numeric identifier
 --name VALUE                  Product name
 --new-name VALUE              Product name
 --organization VALUE          Organization name to search by
 --organization-id NUMBER
 --organization-label VALUE    Organization label to search by
 --organization-title VALUE    Organization title
 --ssl-ca-cert-id NUMBER       Idenifier of the SSL CA Cert
 --ssl-client-cert-id NUMBER   Identifier of the SSL Client Cert
 --ssl-client-key-id NUMBER    Identifier of the SSL Client Key
 --sync-plan VALUE             Sync plan name to search by
 --sync-plan-id NUMBER         Plan numeric identifier
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string

3.57.9. hammer product update-proxy

为产品更新 HTTP 代理

Usage:
    hammer product update-proxy [OPTIONS]

Options:
 --http-proxy VALUE            Name to search by
 --http-proxy-id NUMBER        HTTP Proxy identifier to associated
 --http-proxy-policy ENUM      Policy for HTTP Proxy for content sync
                               Possible value(s): 'global_default_http_proxy', 'none',
                               'use_selected_http_proxy'
 --ids LIST                    List of product ids
 -h, --help                    Print help

Option details:
  Here you can find option types and the value an option can accept:

  BOOLEAN             One of true/false, yes/no, 1/0
  DATETIME            Date and time in YYYY-MM-DD HH:MM:SS or ISO 8601 format
  ENUM                Possible values are described in the option's description
  FILE                Path to a file
  KEY_VALUE_LIST      Comma-separated list of key=value.
                      JSON is acceptable and preferred way for such parameters
  LIST                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                      JSON is acceptable and preferred way for such parameters
  MULTIENUM           Any combination of possible values described in the option's description
  NUMBER              Numeric value. Integer
  SCHEMA              Comma separated list of values defined by a schema.
                      JSON is acceptable and preferred way for such parameters
  VALUE               Value described in the option's description. Mostly simple string
Red Hat logoGithubRedditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

© 2024 Red Hat, Inc.