-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvector.yaml
More file actions
70 lines (64 loc) · 1.86 KB
/
vector.yaml
File metadata and controls
70 lines (64 loc) · 1.86 KB
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
# __ __ __
# \ \ / / / /
# \ V / / /
# \_/ \/
#
# V E C T O R
# Configuration
#
# ------------------------------------------------------------------------------
# Website: https://vector.dev
# Docs: https://vector.dev/docs
# Chat: https://chat.vector.dev
# ------------------------------------------------------------------------------
# Change this to use a non-default directory for Vector data storage:
# data_dir: "/var/lib/vector"
# Random Syslog-formatted logs
sources:
docker_logs:
type: "docker_logs"
# See the Vector Remap Language reference for more info: https://vrl.dev
transforms:
parse_docker:
type: remap
inputs: ["docker_logs"]
source: |
.message = parse_json(.message) ?? .message
if is_object(.message) && (is_null(.message.message) || .message.message == "") {
.message.message = "access"
}
# Print parsed logs to stdout
sinks:
# print:
# type: "console"
# inputs: ["parse_docker"]
# encoding:
# codec: "json"
# json:
# pretty: true
vlogs:
type: http
inputs:
- parse_docker
uri: ${VLOGS_URI}
encoding:
codec: json
framing:
method: newline_delimited
compression: gzip
healthcheck:
enabled: false
request:
headers:
AccountID: "0"
ProjectID: "0"
VL-Stream-Fields: container_name
VL-Msg-Field: message.message
VL-Time-Field: timestamp
VL-Extra-Fields: cluster=pc-proxy
# Vector's GraphQL API (disabled by default)
# Uncomment to try it out with the `vector top` command or
# in your browser at http://localhost:8686
# api:
# enabled: true
# address: "127.0.0.1:8686"