From 40e6548499566639cf34f67559cf4a829a59e71a Mon Sep 17 00:00:00 2001 From: David Kilfoyle Date: Wed, 5 Mar 2025 15:56:24 -0500 Subject: [PATCH] Add Filesource provider to Fleet & Agent docs --- .../fleet/filesource-provider.md | 21 +++++++++++++++++++ reference/toc.yml | 1 + 2 files changed, 22 insertions(+) create mode 100644 reference/ingestion-tools/fleet/filesource-provider.md diff --git a/reference/ingestion-tools/fleet/filesource-provider.md b/reference/ingestion-tools/fleet/filesource-provider.md new file mode 100644 index 0000000000..f0bae3128b --- /dev/null +++ b/reference/ingestion-tools/fleet/filesource-provider.md @@ -0,0 +1,21 @@ +# Filesource provider [filesource-provider] + +Watches for changes of specified files and updates the values of the variables when the content of the files changes. + +This allows information from the filesystem to be used as variables in the {{agent}} configuration. This information is allowed only when the provider has been explicitly configured to read this information from the disk. The policy cannot just read any file, it has to be explicitly configured to allow it. + +For example, the following configuration watches for changes to `file1`: + +```yaml +provides: + filesource: + sources: + file1: + path: ./file1 + +inputs: + - id: filestream + type: filestream + paths: + - ${filesource.file1} +``` \ No newline at end of file diff --git a/reference/toc.yml b/reference/toc.yml index 1674199d35..af5f47f803 100644 --- a/reference/toc.yml +++ b/reference/toc.yml @@ -125,6 +125,7 @@ toc: - file: ingestion-tools/fleet/agent-provider.md - file: ingestion-tools/fleet/host-provider.md - file: ingestion-tools/fleet/env-provider.md + - file: ingestion-tools/fleet/filesource-provider.md - file: ingestion-tools/fleet/kubernetes_secrets-provider.md - file: ingestion-tools/fleet/kubernetes_leaderelection-provider.md - file: ingestion-tools/fleet/local-dynamic-provider.md