2.86. hammer 用户


操作用户

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

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

Subcommands:
 access-token                  Managing personal access tokens
 add-role                      Assign a user role
 create                        Create a user
 delete, destroy               Delete a user
 info, show                    Show a user
 list, index                   List all users
 mail-notification             Managing personal mail notifications
 remove-role                   Remove a user role
 ssh-keys                      Managing User SSH Keys.
 update                        Update a user

Options:
 -h, --help                    Print help

2.86.1. hammer 用户 access-token

管理个人访问令牌

Usage:
    hammer user access-token [OPTIONS] SUBCOMMAND [ARG] ...

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

Subcommands:
 create                        Create a Personal Access Token for a user
 info, show                    Show a Personal Access Token for a user
 list, index                   List all Personal Access Tokens for a user
 revoke                        Revoke a Personal Access Token for a user

Options:
 -h, --help                    Print help

2.86.1.1. hammer 用户 access-token create

为用户创建个人访问令牌

Usage:
    hammer user access-token create [OPTIONS]

Options:
 --expires-at EXPIRES_AT                 Expiry Date
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

2.86.1.2. hammer 用户 access-token 信息

显示用户的个人访问令牌

Usage:
    hammer user access-token <info|show> [OPTIONS]

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME                             Name to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

Predefined field sets:
  -------------|-----|---------|-----
  FIELDS       | ALL | DEFAULT | THIN
  -------------|-----|---------|-----
  Id           | x   | x       | x
  Name         | x   | x       | x
  Active       | x   | x       |
  Expires at   | x   | x       |
  Created at   | x   | x       |
  Last used at | x   | x       |
  -------------|-----|---------|-----

2.86.1.3. hammer 用户 access-token 列表

列出用户的所有个人访问令牌

Usage:
    hammer user access-token <list|index> [OPTIONS]

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --order ORDER                           Sort field and order, eg. ‘id DESC’
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --page PAGE                             Page number, starting at 1
 --per-page PER_PAGE                     Number of results per page to return, 'all' to return all results
 --search SEARCH                         Filter results
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

Predefined field sets:
  -----------|-----|---------|-----
  FIELDS     | ALL | DEFAULT | THIN
  -----------|-----|---------|-----
  Id         | x   | x       | x
  Name       | x   | x       | x
  Active     | x   | x       |
  Expires at | x   | x       |
  -----------|-----|---------|-----

Search / Order fields:
  name                string
  user_id             integer

2.86.1.4. hammer 用户 access-token 撤销

为用户撤销个人访问令牌

Usage:
    hammer user access-token revoke [OPTIONS]

Options:
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME                             Name to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

2.86.2. hammer 用户 add-role

分配用户角色

Usage:
    hammer user add-role [OPTIONS]

Options:
 --id ID
 --login LOGIN                 User's login to search by
 --role ROLE_NAME              User role name
 --role-id ROLE_ID
 -h, --help                    Print help

2.86.3. hammer 用户创建

创建用户

Usage:
    hammer user create [OPTIONS]

Options:
 --admin ADMIN                                     Is an admin account
                                                   One of true/false, yes/no, 1/0.
 --ask-password ASK_PW                             One of true/false, yes/no, 1/0.
 --auth-source AUTH_SOURCE_NAME                    Name to search by
 --auth-source-id AUTH_SOURCE_ID
 --default-location DEFAULT_LOCATION_NAME          Default location name
 --default-location-id DEFAULT_LOCATION_ID
 --default-organization DEFAULT_ORGANIZATION_NAME  Default organization name
 --default-organization-id DEFAULT_ORGANIZATION_ID
 --description DESCRIPTION
 --disabled DISABLED                               One of true/false, yes/no, 1/0.
 --firstname FIRSTNAME
 --lastname LASTNAME
 --locale LOCALE                                   User's preferred locale
                                                   Possible value(s): 'ca', 'cs_CZ', 'de', 'en', 'en_GB', 'es', 'fr', 'gl', 'it', 'ja', 'ko', 'nl_NL', 'pl', 'pt_BR', 'ru', 'sv_SE', 'zh_CN', 'zh_TW'
 --location LOCATION_NAME                          Set the current location context for the request
 --location-id LOCATION_ID                         Set the current location context for the request
 --location-ids LOCATION_IDS                       REPLACE locations with given ids
                                                   Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --location-title LOCATION_TITLE                   Set the current location context for the request
 --location-titles LOCATION_TITLES                 Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --locations LOCATION_NAMES                        Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --login LOGIN
 --mail MAIL
 --organization ORGANIZATION_NAME                  Set the current organization context for the request
 --organization-id ORGANIZATION_ID                 Set the current organization context for the request
 --organization-ids ORGANIZATION_IDS               REPLACE organizations with given ids.
                                                   Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --organization-title ORGANIZATION_TITLE           Set the current organization context for the request
 --organization-titles ORGANIZATION_TITLES         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --organizations ORGANIZATION_NAMES                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --password PASSWORD                               Required unless user is in an external authentication source
 --role-ids ROLE_IDS                               Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --roles ROLE_NAMES                                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --timezone TIMEZONE                               User's timezone
                                                   Possible value(s): 'International Date Line West', 'American Samoa', 'Midway Island', 'Hawaii', 'Alaska', 'Pacific Time (US & Canada)', 'Tijuana', 'Arizona', 'Chihuahua', 'Mazatlan', 'Mountain Time (US & Canada)', 'Central America', 'Central Time (US & Canada)', 'Guadalajara', 'Mexico City', 'Monterrey', 'Saskatchewan', 'Bogota', 'Eastern Time (US & Canada)', 'Indiana (East)', 'Lima', 'Quito', 'Atlantic Time (Canada)', 'Caracas', 'Georgetown', 'La Paz', 'Puerto Rico', 'Santiago', 'Newfoundland', 'Brasilia', 'Buenos Aires', 'Greenland', 'Montevideo', 'Mid-Atlantic', 'Azores', 'Cape Verde Is.', 'Casablanca', 'Dublin', 'Edinburgh', 'Lisbon', 'London', 'Monrovia', 'UTC', 'Amsterdam', 'Belgrade', 'Berlin', 'Bern', 'Bratislava', 'Brussels', 'Budapest', 'Copenhagen', 'Ljubljana', 'Madrid', 'Paris', 'Prague', 'Rome', 'Sarajevo', 'Skopje', 'Stockholm', 'Vienna', 'Warsaw', 'West Central Africa', 'Zagreb', 'Zurich', 'Athens', 'Bucharest', 'Cairo', 'Harare', 'Helsinki', 'Jerusalem', 'Kaliningrad', 'Kyiv', 'Pretoria', 'Riga', 'Sofia', 'Tallinn', 'Vilnius', 'Baghdad', 'Istanbul', 'Kuwait', 'Minsk', 'Moscow', 'Nairobi', 'Riyadh', 'St. Petersburg', 'Volgograd', 'Tehran', 'Abu Dhabi', 'Baku', 'Muscat', 'Samara', 'Tbilisi', 'Yerevan', 'Kabul', 'Ekaterinburg', 'Islamabad', 'Karachi', 'Tashkent', 'Chennai', 'Kolkata', 'Mumbai', 'New Delhi', 'Sri Jayawardenepura', 'Kathmandu', 'Almaty', 'Astana', 'Dhaka', 'Urumqi', 'Rangoon', 'Bangkok', 'Hanoi', 'Jakarta', 'Krasnoyarsk', 'Novosibirsk', 'Beijing', 'Chongqing', 'Hong Kong', 'Irkutsk', 'Kuala Lumpur', 'Perth', 'Singapore', 'Taipei', 'Ulaanbaatar', 'Osaka', 'Sapporo', 'Seoul', 'Tokyo', 'Yakutsk', 'Adelaide', 'Darwin', 'Brisbane', 'Canberra', 'Guam', 'Hobart', 'Melbourne', 'Port Moresby', 'Sydney', 'Vladivostok', 'Magadan', 'New Caledonia', 'Solomon Is.', 'Srednekolymsk', 'Auckland', 'Fiji', 'Kamchatka', 'Marshall Is.', 'Wellington', 'Chatham Is.', 'Nuku'alofa', 'Samoa', 'Tokelau Is.'
 -h, --help                                        Print help

2.86.4. hammer 用户删除

删除用户

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

Options:
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --login LOGIN                           User's login to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 -h, --help                              Print help

2.86.5. hammer 用户信息

显示用户

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

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --login LOGIN                           User's login to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 -h, --help                              Print help

Predefined field sets:
  --------------------------------|-----|---------|-----
  FIELDS                          | ALL | DEFAULT | THIN
  --------------------------------|-----|---------|-----
  Id                              | x   | x       | x
  Login                           | x   | x       | x
  Name                            | x   | x       |
  Email                           | x   | x       |
  Admin                           | x   | x       |
  Disabled                        | x   | x       |
  Last login                      | x   | x       |
  Authorized by                   | x   | x       |
  Effective admin                 | x   | x       |
  Locale                          | x   | x       |
  Timezone                        | x   | x       |
  Description                     | x   | x       |
  Default organization            | x   | x       |
  Default location                | x   | x       |
  Roles/                          | x   | x       |
  User groups/usergroup           | x   | x       |
  User groups/id                  | x   | x       |
  User groups/roles/              | x   | x       |
  Inherited user groups/usergroup | x   | x       |
  Inherited user groups/id        | x   | x       |
  Inherited user groups/roles/    | x   | x       |
  Locations/                      | x   | x       |
  Organizations/                  | x   | x       |
  Created at                      | x   | x       |
  Updated at                      | x   | x       |
  --------------------------------|-----|---------|-----

2.86.6. hammer 用户列表

列出所有用户

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

Options:
 --auth-source-ldap AUTH_SOURCE_LDAP_NAME  Name to search by
 --auth-source-ldap-id AUTH_SOURCE_LDAP_ID ID of LDAP authentication source
 --fields FIELDS                           Show specified fields or predefined field sets only. (See below)
                                           Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                           JSON is acceptable and preferred way for complex parameters
 --location LOCATION_NAME                  Set the current location context for the request
 --location-id LOCATION_ID                 Scope by locations
 --location-title LOCATION_TITLE           Set the current location context for the request
 --order ORDER                             Sort field and order, eg. ‘id DESC’
 --organization ORGANIZATION_NAME          Set the current organization context for the request
 --organization-id ORGANIZATION_ID         Scope by organizations
 --organization-title ORGANIZATION_TITLE   Set the current organization context for the request
 --page PAGE                               Page number, starting at 1
 --per-page PER_PAGE                       Number of results per page to return, 'all' to return all results
 --role ROLE_NAME                          User role name
 --role-id ROLE_ID                         ID of role
 --search SEARCH                           Filter results
 --user-group USER_GROUP_NAME              Name to search by
 --user-group-id USER_GROUP_ID
 -h, --help                                Print help

Predefined field sets:
  --------------|-----|---------|-----
  FIELDS        | ALL | DEFAULT | THIN
  --------------|-----|---------|-----
  Id            | x   | x       | x
  Login         | x   | x       | x
  Name          | x   | x       |
  Email         | x   | x       |
  Admin         | x   | x       |
  Disabled      | x   | x       |
  Last login    | x   | x       |
  Authorized by | x   | x       |
  --------------|-----|---------|-----

Search / Order fields:
  admin               Values: true, false
  auth_source         string
  auth_source_type    string
  description         text
  disabled            Values: true, false
  firstname           string
  last_login_on       datetime
  lastname            string
  location            string
  location_id         integer
  login               string
  mail                string
  organization        string
  organization_id     integer
  role                string
  role_id             integer
  usergroup           string

2.86.7. hammer 用户 mail-notification

管理个人电子邮件通知

Usage:
    hammer user mail-notification [OPTIONS] SUBCOMMAND [ARG] ...

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

Subcommands:
 add                           Add an email notification for a user
 list, index                   List all email notifications for a user
 remove                        Remove an email notification for a user
 update                        Update an email notification for a user

Options:
 -h, --help                    Print help

2.86.7.1. hammer 用户 mail-notification 添加

为用户添加电子邮件通知

Usage:
    hammer user mail-notification add [OPTIONS]

Options:
 --interval INTERVAL                         Mail notification interval option, e.g. Daily, Weekly or Monthly. Required for summary notification
 --location LOCATION_NAME                    Set the current location context for the request
 --location-id LOCATION_ID                   Set the current location context for the request
 --location-title LOCATION_TITLE             Set the current location context for the request
 --mail-notification MAIL_NOTIFICATION_NAME  Name to search by
 --mail-notification-id MAIL_NOTIFICATION_ID
 --mail-query MAIL_QUERY                     Relevant only for audit summary notification
 --organization ORGANIZATION_NAME            Set the current organization context for the request
 --organization-id ORGANIZATION_ID           Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE     Set the current organization context for the request
 --subscription SUBSCRIPTION                 Mail notification subscription option, e.g. Subscribe, Subscribe to my hosts or Subscribe to all hosts. Required for host built and config error state
 --user USER_LOGIN                           User's login to search by
 --user-id USER_ID
 -h, --help                                  Print help

2.86.7.2. hammer 用户 mail-notification 列表

列出用户的所有电子邮件通知

Usage:
    hammer user mail-notification <list|index> [OPTIONS]

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID
 -h, --help                              Print help

Predefined field sets:
  ------------|-----|---------|-----
  FIELDS      | ALL | DEFAULT | THIN
  ------------|-----|---------|-----
  Id          | x   | x       |
  Name        | x   | x       | x
  Description | x   | x       |
  Interval    | x   | x       |
  Mail query  | x   | x       |
  ------------|-----|---------|-----

2.86.7.3. hammer 用户 mail-notification remove

删除用户的电子邮件通知

Usage:
    hammer user mail-notification remove [OPTIONS]

Options:
 --location LOCATION_NAME                    Set the current location context for the request
 --location-id LOCATION_ID                   Set the current location context for the request
 --location-title LOCATION_TITLE             Set the current location context for the request
 --mail-notification MAIL_NOTIFICATION_NAME  Name to search by
 --mail-notification-id MAIL_NOTIFICATION_ID
 --organization ORGANIZATION_NAME            Set the current organization context for the request
 --organization-id ORGANIZATION_ID           Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE     Set the current organization context for the request
 --user USER_LOGIN                           User's login to search by
 --user-id USER_ID
 -h, --help                                  Print help

2.86.7.4. hammer 用户 mail-notification 更新

更新用户的电子邮件通知

Usage:
    hammer user mail-notification update [OPTIONS]

Options:
 --interval INTERVAL                         Mail notification interval option, e.g. Daily, Weekly or Monthly. Required for summary notification
 --location LOCATION_NAME                    Set the current location context for the request
 --location-id LOCATION_ID                   Set the current location context for the request
 --location-title LOCATION_TITLE             Set the current location context for the request
 --mail-notification MAIL_NOTIFICATION_NAME  Name to search by
 --mail-notification-id MAIL_NOTIFICATION_ID
 --mail-query MAIL_QUERY                     Relevant only for audit summary notification
 --new-name NEW_NAME
 --organization ORGANIZATION_NAME            Set the current organization context for the request
 --organization-id ORGANIZATION_ID           Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE     Set the current organization context for the request
 --subscription SUBSCRIPTION                 Mail notification subscription option, e.g. Subscribe, Subscribe to my hosts or Subscribe to all hosts. Required for host built and config error state
 --user USER_LOGIN                           User's login to search by
 --user-id USER_ID
 -h, --help                                  Print help

2.86.8. hammer 用户 remove-role

删除用户角色

Usage:
    hammer user remove-role [OPTIONS]

Options:
 --id ID
 --login LOGIN                 User's login to search by
 --role ROLE_NAME              User role name
 --role-id ROLE_ID
 -h, --help                    Print help

2.86.9. hammer 用户 ssh-keys

管理用户 SSH 密钥.

Usage:
    hammer user ssh-keys [OPTIONS] SUBCOMMAND [ARG] ...

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

Subcommands:
 add                           Add an SSH key for a user
 delete, destroy               Delete an SSH key for a user
 info, show                    Show an SSH key from a user
 list, index                   List all SSH keys for a user

Options:
 -h, --help                    Print help

2.86.9.1. hammer 用户 ssh-keys 添加

为用户添加 SSH 密钥

Usage:
    hammer user ssh-keys add [OPTIONS]

Options:
 --key KEY                               Public SSH key
 --key-file KEY_FILE                     Path to a SSH public key
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

2.86.9.2. hammer 用户 ssh-keys 删除

删除用户的 SSH 密钥

Usage:
    hammer user ssh-keys <delete|destroy> [OPTIONS]

Options:
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME                             Name to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

2.86.9.3. hammer 用户 ssh-keys 信息

显示用户的 SSH 密钥

Usage:
    hammer user ssh-keys <info|show> [OPTIONS]

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --id ID
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --name NAME                             Name to search by
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

Predefined field sets:
  ------------|-----|---------|-----
  FIELDS      | ALL | DEFAULT | THIN
  ------------|-----|---------|-----
  Id          | x   | x       | x
  Name        | x   | x       | x
  Fingerprint | x   | x       |
  Length      | x   | x       |
  Created at  | x   | x       |
  Public key  | x   | x       |
  ------------|-----|---------|-----

2.86.9.4. hammer 用户 ssh-keys 列表

列出用户的所有 SSH 密钥

Usage:
    hammer user ssh-keys <list|index> [OPTIONS]

Options:
 --fields FIELDS                         Show specified fields or predefined field sets only. (See below)
                                         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                         JSON is acceptable and preferred way for complex parameters
 --location LOCATION_NAME                Set the current location context for the request
 --location-id LOCATION_ID               Set the current location context for the request
 --location-title LOCATION_TITLE         Set the current location context for the request
 --order ORDER                           Sort field and order, eg. ‘id DESC’
 --organization ORGANIZATION_NAME        Set the current organization context for the request
 --organization-id ORGANIZATION_ID       Set the current organization context for the request
 --organization-title ORGANIZATION_TITLE Set the current organization context for the request
 --page PAGE                             Page number, starting at 1
 --per-page PER_PAGE                     Number of results per page to return, 'all' to return all results
 --search SEARCH                         Filter results
 --user USER_LOGIN                       User's login to search by
 --user-id USER_ID                       ID of the user
 -h, --help                              Print help

Predefined field sets:
  ------------|-----|---------|-----
  FIELDS      | ALL | DEFAULT | THIN
  ------------|-----|---------|-----
  Id          | x   | x       | x
  Name        | x   | x       | x
  Fingerprint | x   | x       |
  Length      | x   | x       |
  Created at  | x   | x       |
  ------------|-----|---------|-----

Search / Order fields:
  name                string
  user_id             integer

2.86.10. hammer 用户更新

更新用户

Usage:
    hammer user update [OPTIONS]

Options:
 --admin ADMIN                                     Is an admin account
                                                   One of true/false, yes/no, 1/0.
 --ask-password ASK_PW                             One of true/false, yes/no, 1/0.
 --auth-source AUTH_SOURCE_NAME                    Name to search by
 --auth-source-id AUTH_SOURCE_ID
 --current-password CURRENT_PASSWORD               Required when user want to change own password
 --default-location DEFAULT_LOCATION_NAME          Default location name
 --default-location-id DEFAULT_LOCATION_ID
 --default-organization DEFAULT_ORGANIZATION_NAME  Default organization name
 --default-organization-id DEFAULT_ORGANIZATION_ID
 --description DESCRIPTION
 --disabled DISABLED                               One of true/false, yes/no, 1/0.
 --firstname FIRSTNAME
 --id ID
 --lastname LASTNAME
 --locale LOCALE                                   User's preferred locale
                                                   Possible value(s): 'ca', 'cs_CZ', 'de', 'en', 'en_GB', 'es', 'fr', 'gl', 'it', 'ja', 'ko', 'nl_NL', 'pl', 'pt_BR', 'ru', 'sv_SE', 'zh_CN', 'zh_TW'
 --location LOCATION_NAME                          Set the current location context for the request
 --location-id LOCATION_ID                         Set the current location context for the request
 --location-ids LOCATION_IDS                       REPLACE locations with given ids
                                                   Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --location-title LOCATION_TITLE                   Set the current location context for the request
 --location-titles LOCATION_TITLES                 Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --locations LOCATION_NAMES                        Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --login LOGIN                                     User's login to search by
 --mail MAIL
 --new-login NEW_LOGIN
 --organization ORGANIZATION_NAME                  Set the current organization context for the request
 --organization-id ORGANIZATION_ID                 Set the current organization context for the request
 --organization-ids ORGANIZATION_IDS               REPLACE organizations with given ids.
                                                   Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --organization-title ORGANIZATION_TITLE           Set the current organization context for the request
 --organization-titles ORGANIZATION_TITLES         Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --organizations ORGANIZATION_NAMES                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --password PASSWORD                               Required unless user is in an external authentication source
 --role-ids ROLE_IDS                               Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --roles ROLE_NAMES                                Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
                                                   JSON is acceptable and preferred way for complex parameters
 --timezone TIMEZONE                               User's timezone
                                                   Possible value(s): 'International Date Line West', 'American Samoa', 'Midway Island', 'Hawaii', 'Alaska', 'Pacific Time (US & Canada)', 'Tijuana', 'Arizona', 'Chihuahua', 'Mazatlan', 'Mountain Time (US & Canada)', 'Central America', 'Central Time (US & Canada)', 'Guadalajara', 'Mexico City', 'Monterrey', 'Saskatchewan', 'Bogota', 'Eastern Time (US & Canada)', 'Indiana (East)', 'Lima', 'Quito', 'Atlantic Time (Canada)', 'Caracas', 'Georgetown', 'La Paz', 'Puerto Rico', 'Santiago', 'Newfoundland', 'Brasilia', 'Buenos Aires', 'Greenland', 'Montevideo', 'Mid-Atlantic', 'Azores', 'Cape Verde Is.', 'Casablanca', 'Dublin', 'Edinburgh', 'Lisbon', 'London', 'Monrovia', 'UTC', 'Amsterdam', 'Belgrade', 'Berlin', 'Bern', 'Bratislava', 'Brussels', 'Budapest', 'Copenhagen', 'Ljubljana', 'Madrid', 'Paris', 'Prague', 'Rome', 'Sarajevo', 'Skopje', 'Stockholm', 'Vienna', 'Warsaw', 'West Central Africa', 'Zagreb', 'Zurich', 'Athens', 'Bucharest', 'Cairo', 'Harare', 'Helsinki', 'Jerusalem', 'Kaliningrad', 'Kyiv', 'Pretoria', 'Riga', 'Sofia', 'Tallinn', 'Vilnius', 'Baghdad', 'Istanbul', 'Kuwait', 'Minsk', 'Moscow', 'Nairobi', 'Riyadh', 'St. Petersburg', 'Volgograd', 'Tehran', 'Abu Dhabi', 'Baku', 'Muscat', 'Samara', 'Tbilisi', 'Yerevan', 'Kabul', 'Ekaterinburg', 'Islamabad', 'Karachi', 'Tashkent', 'Chennai', 'Kolkata', 'Mumbai', 'New Delhi', 'Sri Jayawardenepura', 'Kathmandu', 'Almaty', 'Astana', 'Dhaka', 'Urumqi', 'Rangoon', 'Bangkok', 'Hanoi', 'Jakarta', 'Krasnoyarsk', 'Novosibirsk', 'Beijing', 'Chongqing', 'Hong Kong', 'Irkutsk', 'Kuala Lumpur', 'Perth', 'Singapore', 'Taipei', 'Ulaanbaatar', 'Osaka', 'Sapporo', 'Seoul', 'Tokyo', 'Yakutsk', 'Adelaide', 'Darwin', 'Brisbane', 'Canberra', 'Guam', 'Hobart', 'Melbourne', 'Port Moresby', 'Sydney', 'Vladivostok', 'Magadan', 'New Caledonia', 'Solomon Is.', 'Srednekolymsk', 'Auckland', 'Fiji', 'Kamchatka', 'Marshall Is.', 'Wellington', 'Chatham Is.', 'Nuku'alofa', 'Samoa', 'Tokelau Is.'
 -h, --help                                        Print help
Red Hat logoGithubRedditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

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

让开源更具包容性

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

關於紅帽

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

© 2024 Red Hat, Inc.