github.com/anth0d/nomad@v0.0.0-20221214183521-ae3a0a2cad06/website/content/docs/commands/acl/role/create.mdx (about)

     1  ---
     2  layout: docs
     3  page_title: 'Commands: acl role create'
     4  description: The role create command is used to create new ACL Roles.
     5  ---
     6  
     7  # Command: acl role create
     8  
     9  The `acl role create` command is used to create new ACL Roles.
    10  
    11  ## Usage
    12  
    13  ```plaintext
    14  nomad acl role create [options]
    15  ```
    16  
    17  The `acl role create` command requires the correct setting of the create options
    18  via flags detailed below.
    19  
    20  ## General Options
    21  
    22  @include 'general_options_no_namespace.mdx'
    23  
    24  ## Create Options
    25  
    26  - `-name`: Sets the human-readable name for the ACL Role. It is required and
    27    can contain alphanumeric characters, dashes, and underscores. This name must
    28    be unique and must not exceed 128 characters.
    29  
    30  - `-description`: A free form text description of the role that must not exceed
    31    256 characters.
    32  
    33  - `-policy`: Specifies a policy to associate with the role identified by their
    34    name. This flag can be specified multiple times and must be specified at
    35    least once.
    36  
    37  - `-json`: Output the ACL role in a JSON format.
    38  
    39  - `-t`: Format and display the ACL role using a Go template.
    40  
    41  ## Examples
    42  
    43  Create a new ACL Role:
    44  
    45  ```shell-session
    46  $ nomad acl role create -name="example-acl-role" -policy=example-acl-policy
    47  ID           = a53b0095-c28a-6181-0586-807b82e665e4
    48  Name         = example-acl-role
    49  Description  = <none>
    50  Policies     = example-acl-policy
    51  Create Index = 71
    52  Modify Index = 71
    53  ```