summaryrefslogtreecommitdiffstats
path: root/src/go/collectors/go.d.plugin/modules/filecheck/config_schema.json
blob: c64bb941f80bcd8816fb24ea04290919220d8a9d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
{
  "jsonSchema": {
    "$schema": "http://json-schema.org/draft-07/schema#",
    "title": "Filecheck collector configuration.",
    "type": "object",
    "properties": {
      "update_every": {
        "title": "Update every",
        "description": "Data collection interval, measured in seconds.",
        "type": "integer",
        "minimum": 1,
        "default": 1
      },
      "discovery_every": {
        "title": "Scan interval",
        "description": "Scan frequency interval (seconds) for files and directories with patterns (globs) in their paths.",
        "type": "integer",
        "minimum": 1,
        "default": 60
      },
      "files": {
        "title": "File selector",
        "description": "Configuration for monitoring specific files. If left empy, no files will be monitored.",
        "type": [
          "object",
          "null"
        ],
        "properties": {
          "include": {
            "title": "Include",
            "description": "Include files that match any of the specified include [patterns](https://golang.org/pkg/path/filepath/#Match).",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "title": "Filepath",
              "type": "string",
              "pattern": "^$|^/"
            },
            "uniqueItems": true
          },
          "exclude": {
            "title": "Exclude",
            "description": "Exclude files that match any of the specified exclude [patterns](https://golang.org/pkg/path/filepath/#Match).",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "title": "Filepath",
              "type": "string",
              "pattern": "^$|^/"
            },
            "uniqueItems": true
          }
        },
        "required": [
          "include"
        ]
      },
      "dirs": {
        "title": "Directory selector",
        "description": "Configuration for monitoring specific directories. If left empy, no directories will be monitored.",
        "type": [
          "object",
          "null"
        ],
        "properties": {
          "collect_dir_size": {
            "title": "Collect directory size",
            "description": "Enable the collection of directory sizes for each monitored directory. **Enabling this option may introduce additional overhead** on both Netdata and the host system, particularly if directories contain a large number of subdirectories and files.",
            "type": "boolean",
            "default": false
          },
          "include": {
            "title": "Include",
            "description": "Include directories that match any of the specified include [patterns](https://golang.org/pkg/path/filepath/#Match).",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "title": "Directory",
              "type": "string",
              "pattern": "^$|^/"
            },
            "uniqueItems": true
          },
          "exclude": {
            "title": "Exclude",
            "description": "Exclude directories that match any of the specified exclude [patterns](https://golang.org/pkg/path/filepath/#Match).",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "title": "Directory",
              "type": "string",
              "pattern": "^$|^/"
            },
            "uniqueItems": true
          }
        },
        "required": [
          "include"
        ]
      }
    },
    "additionalProperties": false,
    "patternProperties": {
      "^name$": {}
    }
  },
  "uiSchema": {
    "uiOptions": {
      "fullPage": true
    },
    "ui:flavour": "tabs",
    "ui:options": {
      "tabs": [
        {
          "title": "Base",
          "fields": [
            "update_every",
            "discovery_every"
          ]
        },
        {
          "title": "Files",
          "fields": [
            "files"
          ]
        },
        {
          "title": "Directories",
          "fields": [
            "dirs"
          ]
        }
      ]
    },
    "files": {
      "ui:help": "The logic for inclusion and exclusion is as follows: `(include1 OR include2) AND !(exclude1 OR exclude2)`.",
      "ui:collapsible": true,
      "include": {
        "ui:listFlavour": "list"
      },
      "exclude": {
        "ui:listFlavour": "list"
      }
    },
    "dirs": {
      "ui:help": "The logic for inclusion and exclusion is as follows: `(include1 OR include2) AND !(exclude1 OR exclude2)`.",
      "ui:collapsible": true,
      "include": {
        "ui:listFlavour": "list"
      },
      "exclude": {
        "ui:listFlavour": "list"
      }
    }
  }
}