Skip to content

Commit

Permalink
Incorporate doc updates from elastic/beats#6184
Browse files Browse the repository at this point in the history
  • Loading branch information
jalvz authored and simitt committed Mar 22, 2018
1 parent e525ccb commit 22a5831
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 12 deletions.
12 changes: 10 additions & 2 deletions docs/copied-from-beats/command-reference.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,15 @@
:keystore-command-short-desc: Manages the <<keystore,secrets keystore>>
:modules-command-short-desc: Manages configured modules
:run-command-short-desc: Runs {beatname_uc}. This command is used by default if you start {beatname_uc} without specifying a command

ifeval::["{has_ml_jobs}"=="yes"]
:setup-command-short-desc: Sets up the initial environment, including the index template, Kibana dashboards (when available), and machine learning jobs (when available)
endif::[]

ifeval::["{has_ml_jobs}"!="yes"]
:setup-command-short-desc: Sets up the initial environment, including the index template, Kibana dashboards (when available)
endif::[]

:test-command-short-desc: Tests the configuration
:version-command-short-desc: Shows information about the current version

Expand All @@ -31,7 +39,7 @@
<titleabbrev>Command reference</titleabbrev>
++++

{beatname_uc} provides a command-line interface for running the Beat and
{beatname_uc} provides a command-line interface for starting {beatname_uc} and
performing common tasks, like testing configuration files and loading
dashboards. The command-line also supports <<global-flags,global flags>>
for controlling global behaviors.
Expand Down Expand Up @@ -164,7 +172,7 @@ Specifies the name of the command to show help for.
[[keystore-command]]
==== `keystore` command

{keystore-command-short-desc}.
{keystore-command-short-desc}.

*SYNOPSIS*

Expand Down
23 changes: 13 additions & 10 deletions docs/copied-from-beats/keystore.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,30 +13,33 @@
=== Secrets keystore

When you configure {beatname_uc}, you might need to specify sensitive settings,
such as passwords. Relying on the file system to protect these values is not
sufficient. {beatname_uc} provides a keystore for storing secret values to use
in configuration settings.
such as passwords. Rather than relying on file system permissions to protect
these values, you can use the {beatname_uc} keystore to securely store secret
values for use in configuration settings.

Unlike the Elasticsearch keystore, the {beatname_uc} keystore does not store
actual configuration settings. Instead, you add a key and secret value to the
keystore, and then use the key in place of the secret value when you configure
sensitive settings.
After adding a key and its secret value to the keystore, you can use the key in
place of the secret value when you configure sensitive settings.

The syntax for referencing keys is identical to the syntax for environment
variables:

`${KEY}`

Where KEY is the name of the key.
Where KEY is the name of the key.

For example, imagine that the keystore contains a key called `ES_PWD` with the
value `yourelasticsearchpassword`:

* In the configuration file, use `output.elasticsearch.password: "${ES_PWD}"`
* On the command line, use: `-E "output.elasticsearch.password=${ES_PWD}"`
* On the command line, use: `-E "output.elasticsearch.password=${ES_PWD}"`

When {beatname_uc} unpacks the configuration, it resolves keys before resolving
environment variables and other variables.
environment variables and other variables.

Notice that the {beatname_uc} keystore differs from the Elasticsearch keystore.
Whereas the Elasticsearch keystore lets you store `elasticsearch.yml` values by
name, the {beatname_uc} keystore lets you specify arbitrary names that you can
reference in the {beatname_uc} configuration.

To create and manage keys, use the `keystore` command. See the
<<keystore-command,command reference>> for the full command syntax, including
Expand Down

0 comments on commit 22a5831

Please sign in to comment.