From 94c12630b58a2dbdc6dd0e0eeb9ccc0c1dee7913 Mon Sep 17 00:00:00 2001 From: Chelsea Holland Komlo Date: Sun, 17 Sep 2017 13:36:54 +0000 Subject: [PATCH] documentation; add to existing commands --- commands.go | 5 +++ website/source/docs/commands/acl.html.md.erb | 2 + .../docs/commands/acl/policy-info.html.md.erb | 43 +++++++++++++++++++ 3 files changed, 50 insertions(+) create mode 100644 website/source/docs/commands/acl/policy-info.html.md.erb diff --git a/commands.go b/commands.go index ed052f0e2..2f9fa6520 100644 --- a/commands.go +++ b/commands.go @@ -46,6 +46,11 @@ func Commands(metaPtr *command.Meta) map[string]cli.CommandFactory { Meta: meta, }, nil }, + "acl policy info": func() (cli.Command, error) { + return &command.ACLPolicyInfoCommand{ + Meta: meta, + }, nil + }, "acl token": func() (cli.Command, error) { return &command.ACLTokenCommand{ Meta: meta, diff --git a/website/source/docs/commands/acl.html.md.erb b/website/source/docs/commands/acl.html.md.erb index 1b8e2b6b7..721c0ebd1 100644 --- a/website/source/docs/commands/acl.html.md.erb +++ b/website/source/docs/commands/acl.html.md.erb @@ -22,12 +22,14 @@ subcommands are available: * [`acl bootstrap`][bootstrap] - Bootstrap the initial ACL token * [`acl policy apply`][policyapply] - Create or update ACL policies * [`acl policy delete`][policydelete] - Delete an existing ACL policies +* [`acl policy info`][policyinfo] - Fetch information on an existing ACL policy * [`acl token create`][tokencreate] - Create new ACL token * [`acl token delete`][tokendelete] - Delete an existing ACL token [bootstrap]: /docs/commands/acl/bootstrap.html [policyapply]: /docs/commands/acl/policy-apply.html [policydelete]: /docs/commands/acl/policy-delete.html +[policyinfo]: /docs/commands/acl/policy-info.html [tokencreate]: /docs/commands/acl/token-create.html [tokendelete]: /docs/commands/acl/token-delete.html diff --git a/website/source/docs/commands/acl/policy-info.html.md.erb b/website/source/docs/commands/acl/policy-info.html.md.erb new file mode 100644 index 000000000..6e8aee298 --- /dev/null +++ b/website/source/docs/commands/acl/policy-info.html.md.erb @@ -0,0 +1,43 @@ +--- +layout: "docs" +page_title: "Commands: acl policy info" +sidebar_current: "docs-commands-acl-policy-info" +description: > +The policy info command is used to fetch information on an existing ACL +policy. +--- + +# Command: acl policy info + +The `acl policy info` command is used to fetch information on an existing ACL +policy. + +## Usage + +``` +nomad acl policy info +``` + +The `acl policy info` command requires the policy name. + +## General Options + +<%= partial "docs/commands/_general_options" %> + +## Examples + +Fetch information on an existing ACL Policy: + +``` +$ nomad acl policy info my-policy +Name = my-name +Description = +Rules = { +"Name": "my-policy", +"Description": "This is a great policy", +"Rules": "" +} +CreateIndex = %!s(uint64=749) +ModifyIndex = %!s(uint64=758) + +```