From c0f5184fd1a9df874472a28ef51eaa107a07b2ce Mon Sep 17 00:00:00 2001 From: Jonathan Budzenski Date: Wed, 30 Jun 2021 11:34:18 -0500 Subject: [PATCH] [paths] Add default lookup for config folder at /etc/kibana When `(KBN|KIBANA)_PATH_CONF` was introduced, we removed the fallback lookup to `/etc/kibana/kibana.yml` in #67433. This environment variable was added to `/etc/default/kibana` and made available, scoped to the Kibana service for deb and rpm packages. This environment setting, however, is not available when running binaries directly and caused the regression noted in This re-adds a fallback lookup to `/etc/kibana/kibana.yml` when searching for a kibana.yml configuration. Testing 1) Install a .deb or .rpm package 2) `sudo -u kibana /usr/share/bin/kibana --version` Closes #101249 --- packages/kbn-utils/src/path/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/kbn-utils/src/path/index.ts b/packages/kbn-utils/src/path/index.ts index 2d6d0e9e919eb..9835179a61e9d 100644 --- a/packages/kbn-utils/src/path/index.ts +++ b/packages/kbn-utils/src/path/index.ts @@ -18,6 +18,7 @@ const CONFIG_PATHS = [ process.env.KIBANA_PATH_CONF && join(process.env.KIBANA_PATH_CONF, 'kibana.yml'), process.env.CONFIG_PATH, // deprecated join(REPO_ROOT, 'config/kibana.yml'), + '/etc/kibana/kibana.yml', ].filter(isString); const CONFIG_DIRECTORIES = [