From e1f73d091ef0458e7658171a62620b6293b8d66f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fredrik=20Adel=C3=B6w?= Date: Thu, 29 Feb 2024 14:33:04 +0100 Subject: [PATCH] Added config.d.ts entry with secrets for the shared auth block MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Fredrik Adelöw --- .changeset/proud-socks-hear.md | 5 ++++ .../config.d.ts | 27 +++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 .changeset/proud-socks-hear.md diff --git a/.changeset/proud-socks-hear.md b/.changeset/proud-socks-hear.md new file mode 100644 index 0000000000..20764ae8a0 --- /dev/null +++ b/.changeset/proud-socks-hear.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-search-backend-module-elasticsearch': patch +--- + +Added config.d.ts entry with secrets for the shared auth block diff --git a/plugins/search-backend-module-elasticsearch/config.d.ts b/plugins/search-backend-module-elasticsearch/config.d.ts index b798240cef..401e55f792 100644 --- a/plugins/search-backend-module-elasticsearch/config.d.ts +++ b/plugins/search-backend-module-elasticsearch/config.d.ts @@ -212,6 +212,33 @@ export interface Config { }; } ); + + /** + * Authentication credentials for ElasticSearch. These are fallback + * credentials - in most cases, for known specific ES implementations, the + * respective auth block inside the clientOptions above will be used. + * + * If both ApiKey/Bearer token and username+password is provided, tokens + * take precedence + */ + auth?: + | { + username: string; + + /** + * @visibility secret + */ + password: string; + } + | { + /** + * Base64 Encoded API key to be used to connect to the cluster. + * See: https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-create-api-key.html + * + * @visibility secret + */ + apiKey: string; + }; }; }; }