From 13f1a94039ea0f3c89852eeb6e0c581f5e82f5c3 Mon Sep 17 00:00:00 2001 From: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Date: Tue, 9 May 2023 14:48:42 -0400 Subject: [PATCH] [7.17] Adds documentation to clarify kibana-keystore behaviour (#157146) (#157187) # Backport This will backport the following commits from `main` to `7.17`: - [Adds documentation to clarify kibana-keystore behaviour (#157146)](https://github.com/elastic/kibana/pull/157146) ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) Co-authored-by: Alex Szabo --- docs/setup/secure-settings.asciidoc | 2 ++ src/cli_keystore/add.js | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/setup/secure-settings.asciidoc b/docs/setup/secure-settings.asciidoc index 55b8c39e0ede8d..37fe4db6e61237 100644 --- a/docs/setup/secure-settings.asciidoc +++ b/docs/setup/secure-settings.asciidoc @@ -36,6 +36,8 @@ bin/kibana-keystore list [[add-string-to-keystore]] === Add string settings +NOTE: Your input will be JSON-parsed to allow for object/array input configurations. To enforce string values, use "double quotes" around your input. + Sensitive string settings, like authentication credentials for Elasticsearch can be added using the `add` command: diff --git a/src/cli_keystore/add.js b/src/cli_keystore/add.js index 39aa4d007240fe..ec27a0b4642955 100644 --- a/src/cli_keystore/add.js +++ b/src/cli_keystore/add.js @@ -64,7 +64,9 @@ export async function add(keystore, key, options = {}) { export function addCli(program, keystore) { program .command('add ') - .description('Add a string setting to the keystore') + .description( + 'Add a setting to the keystore. Note: The value will be JSON parsed. Use quotes to force string inputs.' + ) .option('-f, --force', 'overwrite existing setting without prompting') .option('-x, --stdin', 'read setting value from stdin') .option('-s, --silent', 'prevent all logging')