mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 17:35:43 +03:00
website: document bootstrap CLI and update ACL guide
This commit is contained in:
25
website/source/docs/commands/acl.html.md.erb
Normal file
25
website/source/docs/commands/acl.html.md.erb
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
layout: "docs"
|
||||
page_title: "Commands: acl"
|
||||
sidebar_current: "docs-commands-acl"
|
||||
description: >
|
||||
The deployment command is used to interact with ACL policies and tokens.
|
||||
---
|
||||
|
||||
# Nomad ACL
|
||||
|
||||
Command: `nomad acl`
|
||||
|
||||
The `acl` command is used to interact with ACL policies and tokens.
|
||||
|
||||
## Usage
|
||||
|
||||
Usage: `nomad acl <subcommand> [options]`
|
||||
|
||||
Run `nomad acl <subcommand> -h` for help on that subcommand. The following
|
||||
subcommands are available:
|
||||
|
||||
* [`acl bootstrap`][bootstrap] - Bootstrap the initial ACL token
|
||||
|
||||
[bootstrap]: /docs/commands/acl/bootstrap.html
|
||||
|
||||
40
website/source/docs/commands/acl/bootstrap.html.md.erb
Normal file
40
website/source/docs/commands/acl/bootstrap.html.md.erb
Normal file
@@ -0,0 +1,40 @@
|
||||
---
|
||||
layout: "docs"
|
||||
page_title: "Commands: acl bootstrap"
|
||||
sidebar_current: "docs-commands-acl-bootstrap"
|
||||
description: >
|
||||
The deployment list command is used to list deployments.
|
||||
---
|
||||
|
||||
# Command: acl bootstrap
|
||||
|
||||
The `acl bootstrap` command is used to bootstrap the initial ACL token.
|
||||
|
||||
## Usage
|
||||
|
||||
```
|
||||
nomad acl bootstrap [options]
|
||||
```
|
||||
|
||||
The `acl bootstrap` command requires no arguments.
|
||||
|
||||
## General Options
|
||||
|
||||
<%= partial "docs/commands/_general_options" %>
|
||||
|
||||
## Examples
|
||||
|
||||
Bootstrap the initial token:
|
||||
|
||||
```
|
||||
$ nomad acl bootstrap
|
||||
Accessor ID = 5b7fd453-d3f7-6814-81dc-fcfe6daedea5
|
||||
Secret ID = 9184ec35-65d4-9258-61e3-0c066d0a45c5
|
||||
Name = Bootstrap Token
|
||||
Type = management
|
||||
Global = true
|
||||
Policies = n/a
|
||||
Create Time = 2017-09-11 17:38:10.999089612 +0000 UTC
|
||||
Create Index = 7
|
||||
Modify Index = 7
|
||||
```
|
||||
@@ -83,25 +83,19 @@ Please take care to restart the servers one at a time, and ensure each server ha
|
||||
|
||||
### Generate the initial token
|
||||
|
||||
Once the ACL system is enabled, we need to generate our initial token. This first token is used to bootstrap the system and care should be taken not to lose it. Once the ACL system is enabled, we use the [Bootstrap API](/api/acl-tokens.html#bootstrap-token):
|
||||
Once the ACL system is enabled, we need to generate our initial token. This first token is used to bootstrap the system and care should be taken not to lose it. Once the ACL system is enabled, we use the [Bootstrap CLI](/docs/commands/acl/bootstrap.html):
|
||||
|
||||
```text
|
||||
$ curl \
|
||||
--request POST \
|
||||
https://nomad.rocks/v1/acl/bootstrap?pretty=true
|
||||
```
|
||||
```json
|
||||
{
|
||||
"AccessorID":"b780e702-98ce-521f-2e5f-c6b87de05b24",
|
||||
"SecretID":"3f4a0fcd-7c42-773c-25db-2d31ba0c05fe",
|
||||
"Name":"Bootstrap Token",
|
||||
"Type":"management",
|
||||
"Policies":null,
|
||||
"Global":true,
|
||||
"CreateTime":"2017-08-23T22:47:14.695408057Z",
|
||||
"CreateIndex":7,
|
||||
"ModifyIndex":7
|
||||
}
|
||||
$ nomad acl bootstrap
|
||||
Accessor ID = 5b7fd453-d3f7-6814-81dc-fcfe6daedea5
|
||||
Secret ID = 9184ec35-65d4-9258-61e3-0c066d0a45c5
|
||||
Name = Bootstrap Token
|
||||
Type = management
|
||||
Global = true
|
||||
Policies = n/a
|
||||
Create Time = 2017-09-11 17:38:10.999089612 +0000 UTC
|
||||
Create Index = 7
|
||||
Modify Index = 7
|
||||
```
|
||||
|
||||
Once the initial bootstrap is performed, it cannot be performed again unless [reset](#reseting-acl-bootstrap). Make sure to save this AccessorID and SecretID.
|
||||
|
||||
@@ -167,6 +167,14 @@
|
||||
<li<%= sidebar_current("docs-commands") %>>
|
||||
<a href="/docs/commands/index.html">Commands (CLI)</a>
|
||||
<ul class="nav">
|
||||
<li<%= sidebar_current("docs-commands-acl") %>>
|
||||
<a href="/docs/commands/acl.html">acl</a>
|
||||
<ul class="nav">
|
||||
<li<%= sidebar_current("docs-commands-acl-bootstrap") %>>
|
||||
<a href="/docs/commands/acl/bootstrap.html">acl bootstrap</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li<%= sidebar_current("docs-commands-_agent") %>>
|
||||
<a href="/docs/commands/agent.html">agent</a>
|
||||
</li>
|
||||
|
||||
Reference in New Issue
Block a user