Skip to content

Commit

Permalink
chore(docs): improve source data_dir docs (#19596)
Browse files Browse the repository at this point in the history
* chore(docs): improve source data_dir docs

* fix doc content

* regen docs
  • Loading branch information
pront authored Jan 12, 2024
1 parent e1d570d commit f262324
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 12 deletions.
6 changes: 4 additions & 2 deletions src/sources/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,10 @@ pub struct FileConfig {

/// The directory used to persist file checkpoint positions.
///
/// By default, the [global `data_dir` option][global_data_dir] is used. Make sure the running user has write
/// permissions to this directory.
/// By default, the [global `data_dir` option][global_data_dir] is used.
/// Make sure the running user has write permissions to this directory.
///
/// If this directory is specified, then Vector will attempt to create it.
///
/// [global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
#[serde(default)]
Expand Down
8 changes: 6 additions & 2 deletions src/sources/journald.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,12 @@ pub struct JournaldConfig {

/// The directory used to persist file checkpoint positions.
///
/// By default, the global `data_dir` option is used. Make sure the running user has write
/// permissions to this directory.
/// By default, the [global `data_dir` option][global_data_dir] is used.
/// Make sure the running user has write permissions to this directory.
///
/// If this directory is specified, then Vector will attempt to create it.
///
/// [global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
#[serde(default)]
#[configurable(metadata(docs::examples = "/var/lib/vector"))]
#[configurable(metadata(docs::human_name = "Data Directory"))]
Expand Down
8 changes: 6 additions & 2 deletions src/sources/kubernetes_logs/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,12 @@ pub struct Config {

/// The directory used to persist file checkpoint positions.
///
/// By default, the global `data_dir` option is used. Make sure the running user has write
/// permissions to this directory.
/// By default, the [global `data_dir` option][global_data_dir] is used.
/// Make sure the running user has write permissions to this directory.
///
/// If this directory is specified, then Vector will attempt to create it.
///
/// [global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
#[configurable(metadata(docs::examples = "/var/local/lib/vector/"))]
#[configurable(metadata(docs::human_name = "Data Directory"))]
data_dir: Option<PathBuf>,
Expand Down
6 changes: 4 additions & 2 deletions website/cue/reference/components/sources/base/file.cue
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,10 @@ base: components: sources: file: configuration: {
description: """
The directory used to persist file checkpoint positions.
By default, the [global `data_dir` option][global_data_dir] is used. Make sure the running user has write
permissions to this directory.
By default, the [global `data_dir` option][global_data_dir] is used.
Make sure the running user has write permissions to this directory.
If this directory is specified, then Vector will attempt to create it.
[global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
"""
Expand Down
8 changes: 6 additions & 2 deletions website/cue/reference/components/sources/base/journald.cue
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,12 @@ base: components: sources: journald: configuration: {
description: """
The directory used to persist file checkpoint positions.
By default, the global `data_dir` option is used. Make sure the running user has write
permissions to this directory.
By default, the [global `data_dir` option][global_data_dir] is used.
Make sure the running user has write permissions to this directory.
If this directory is specified, then Vector will attempt to create it.
[global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
"""
required: false
type: string: examples: ["/var/lib/vector"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,12 @@ base: components: sources: kubernetes_logs: configuration: {
description: """
The directory used to persist file checkpoint positions.
By default, the global `data_dir` option is used. Make sure the running user has write
permissions to this directory.
By default, the [global `data_dir` option][global_data_dir] is used.
Make sure the running user has write permissions to this directory.
If this directory is specified, then Vector will attempt to create it.
[global_data_dir]: https://vector.dev/docs/reference/configuration/global-options/#data_dir
"""
required: false
type: string: examples: ["/var/local/lib/vector/"]
Expand Down

0 comments on commit f262324

Please sign in to comment.