- --config.file=/var/lib/alloy/config/config.yaml
This commit is contained in:
parent
39eab1ef93
commit
c376f6d0c6
2 changed files with 11 additions and 16 deletions
|
@ -15,18 +15,16 @@ data:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
discovery.kubernetes "pod" {
|
local.file_match "applogs" {
|
||||||
role = "pod"
|
path_targets = [
|
||||||
}
|
{
|
||||||
|
"__path__" = "/openbao/logs/*"
|
||||||
discovery.relabel "openbao_pod_logs" {
|
}
|
||||||
targets = discovery.kubernetes.pod.targets
|
]
|
||||||
|
sync_period = "5s"
|
||||||
rule {
|
|
||||||
source_labels = ["__meta_kubernetes_pod_name"]
|
|
||||||
action = "keep"
|
|
||||||
regex = "openbao-0"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
loki.source.file "openbao_logs" {
|
||||||
|
targets = local.file_match.applogs.targets
|
||||||
forward_to = [loki.write.local_loki.receiver]
|
forward_to = [loki.write.local_loki.receiver]
|
||||||
}
|
}
|
|
@ -6,11 +6,8 @@ server:
|
||||||
- containerPort: 12345
|
- containerPort: 12345
|
||||||
securityContext:
|
securityContext:
|
||||||
runAsUser: 100
|
runAsUser: 100
|
||||||
# args:
|
args:
|
||||||
# - --config.file=/etc/alloy/config.yaml
|
- --config.file=/var/lib/alloy/config/config.yaml
|
||||||
# volumeMounts:
|
|
||||||
# - name: alloy-data
|
|
||||||
# mountPath: /var/lib/alloy/data
|
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: log-storage
|
- name: log-storage
|
||||||
mountPath: /openbao/logs
|
mountPath: /openbao/logs
|
||||||
|
|
Loading…
Reference in a new issue