3.79. hammer 模板
操作置备模板
Usage: hammer template [OPTIONS] SUBCOMMAND [ARG] ... Parameters: SUBCOMMAND Subcommand [ARG] ... Subcommand arguments Subcommands: add-operatingsystem Associate an operating system build-pxe-default Update the default PXE menu on all configured TFTP servers clone Clone a provision template combination Manage template combinations create Create a provisioning template delete, destroy Delete a provisioning template dump View provisioning template content info, show Show provisioning template details kinds List available provisioning template kinds list, index List provisioning templates remove-operatingsystem Disassociate an operating system update Update a provisioning template Options: -h, --help Print help
3.79.1. hammer 模板 add-operatingsystem
关联操作系统
Usage: hammer template add-operatingsystem [OPTIONS] Options: --id VALUE --name VALUE Name to search by --operatingsystem VALUE Operating system title --operatingsystem-id NUMBER -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.79.2. hammer template build-pxe-default
更新所有配置的 TFTP 服务器中的默认 PXE 菜单
Usage: hammer template build-pxe-default [OPTIONS] Options: --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -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.79.3. Hammer 模板克隆
克隆置备模板
Usage: hammer template clone [OPTIONS] Options: --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --name VALUE Template name --new-name VALUE Template name --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -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.79.4. Hammer 模板组合
管理模板组合
Usage: hammer template combination [OPTIONS] SUBCOMMAND [ARG] ... Parameters: SUBCOMMAND Subcommand [ARG] ... Subcommand arguments Subcommands: create Add a template combination delete, destroy Delete a template combination info, show Show template combination list, index List template combination update Update template combination Options: -h, --help Print help
3.79.4.1. Hammer 模板组合创建
添加模板组合
Usage: hammer template combination create [OPTIONS] Options: --hostgroup VALUE Hostgroup name --hostgroup-id VALUE ID of host group --hostgroup-title VALUE Hostgroup title --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request --provisioning-template VALUE Name to search by --provisioning-template-id VALUE ID of config template -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.79.4.2. Hammer 模板组合删除
删除模板组合
Usage: hammer template combination <delete|destroy> [OPTIONS] Options: --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -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.79.4.3. hammer 模板组合信息
显示模板组合
Usage: hammer template combination <info|show> [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) --hostgroup VALUE Hostgroup name --hostgroup-id VALUE ID of host group --hostgroup-title VALUE Hostgroup title --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request --provisioning-template VALUE Name to search by --provisioning-template-id VALUE ID of config template -h, --help Print help Predefined field sets: ---------------------------|-----|---------|----- FIELDS | ALL | DEFAULT | THIN ---------------------------|-----|---------|----- Id | x | x | x Provisioning template id | x | x | Provisioning template name | x | x | Hostgroup id | x | x | Hostgroup name | x | x | Locations/ | x | x | Organizations/ | x | x | Created at | x | x | Updated at | 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.79.4.4. Hammer 模板组合列表
列出模板组合
Usage: hammer template combination <list|index> [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request --provisioning-template VALUE Name to search by --provisioning-template-id VALUE ID of config template -h, --help Print help Predefined field sets: ----------------------|-----|---------|----- FIELDS | ALL | DEFAULT | THIN ----------------------|-----|---------|----- Id | x | x | x Provisioning template | x | x | Hostgroup | 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.79.4.5. Hammer 模板组合更新
更新模板组合
Usage: hammer template combination update [OPTIONS] Options: --hostgroup VALUE Hostgroup name --hostgroup-id VALUE ID of host group --hostgroup-title VALUE Hostgroup title --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request --provisioning-template VALUE Name to search by --provisioning-template-id VALUE ID of config template -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.79.5. hammer 模板创建
创建置备模板
Usage: hammer template create [OPTIONS] Options: --audit-comment VALUE --description VALUE --file FILE Path to a file that contains the template --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-ids LIST REPLACE locations with given ids --location-title VALUE Set the current location context for the request --location-titles LIST --locations LIST --locked BOOLEAN Whether or not the template is locked for editing --name VALUE Template name --operatingsystem-ids LIST Array of operating system IDs to associate with the template --operatingsystems LIST --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-ids LIST REPLACE organizations with given ids. --organization-title VALUE Set the current organization context for the request --organization-titles LIST --organizations LIST --type VALUE Template type. Eg. snippet, script, provision -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.79.6. hammer 模板删除
删除置备模板
Usage: hammer template <delete|destroy> [OPTIONS] Options: --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --name VALUE Name to search by --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -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.79.7. Hammer 模板转储
查看置备模板内容
Usage: hammer template dump [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --name VALUE Name to search by --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -h, --help Print help Predefined field sets: ------ FIELDS ------ 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.79.8. hammer 模板信息
显示置备模板详情
Usage: hammer template <info|show> [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-title VALUE Set the current location context for the request --name VALUE Name to search by --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-title VALUE Set the current organization context for the request -h, --help Print help Predefined field sets: ---------------------------------------|-----|---------|----- FIELDS | ALL | DEFAULT | THIN ---------------------------------------|-----|---------|----- Id | x | x | x Name | x | x | x Type | x | x | Description | x | x | Locked | x | x | Operating systems/ | x | x | Locations/ | x | x | Organizations/ | x | x | Template combinations/hostgroup name | x | x | Template combinations/environment name | 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.79.9. hammer 模板类型
列出可用的置备模板类型
Usage: hammer template kinds [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) -h, --help Print help Predefined field sets: -------|-----|---------|----- FIELDS | ALL | DEFAULT | THIN -------|-----|---------|----- Name | x | 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.79.10. Hammer 模板列表
列出置备模板
Usage: hammer template <list|index> [OPTIONS] Options: --fields LIST Show specified fields or predefined field sets only. (See below) --location VALUE Set the current location context for the request --location-id NUMBER Scope by locations --location-title VALUE Set the current location context for the request --operatingsystem VALUE Operating system title --operatingsystem-id NUMBER ID of operating system --order VALUE Sort and order by a searchable field, e.g. '<field> DESC' --organization VALUE Set the current organization context for the request --organization-id NUMBER Scope by organizations --organization-title VALUE Set the current organization context for the request --page NUMBER Page number, starting at 1 --per-page VALUE Number of results per page to return, 'all' to return all results --search VALUE Filter results -h, --help Print help Predefined field sets: -------|-----|---------|----- FIELDS | ALL | DEFAULT | THIN -------|-----|---------|----- Id | x | x | x Name | x | x | x 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 Search / Order fields: default_template Values: true, false hostgroup string kind string location string location_id integer locked Values: true, false name string operatingsystem string organization string organization_id integer snippet Values: true, false supported Values: true, false template text vendor string
3.79.11. hammer template remove-operatingsystem
解除操作系统关联
Usage: hammer template remove-operatingsystem [OPTIONS] Options: --id VALUE --name VALUE Name to search by --operatingsystem VALUE Operating system title --operatingsystem-id NUMBER -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.79.12. Hammer 模板更新
更新置备模板
Usage: hammer template update [OPTIONS] Options: --audit-comment VALUE --description VALUE --file FILE Path to a file that contains the template --id VALUE --location VALUE Set the current location context for the request --location-id NUMBER Set the current location context for the request --location-ids LIST REPLACE locations with given ids --location-title VALUE Set the current location context for the request --location-titles LIST --locations LIST --locked BOOLEAN Whether or not the template is locked for editing --name VALUE Template name --new-name VALUE Template name --operatingsystem-ids LIST Array of operating system IDs to associate with the template --operatingsystems LIST --organization VALUE Set the current organization context for the request --organization-id NUMBER Set the current organization context for the request --organization-ids LIST REPLACE organizations with given ids. --organization-title VALUE Set the current organization context for the request --organization-titles LIST --organizations LIST --type VALUE Template type. Eg. snippet, script, provision -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