diff options
author | makefunstuff <[email protected]> | 2024-06-29 22:27:47 +0200 |
---|---|---|
committer | makefunstuff <[email protected]> | 2024-06-29 22:27:47 +0200 |
commit | b9b33038285a1774b3fbad3785c56c561994707d (patch) | |
tree | 5c71e2ede0e75fd749f7919669c9a25ae9a373ee /tools/eck-operator/templates | |
parent | c7bfc7770684ffc6d17f5d8995afe16d28288f8c (diff) | |
download | k3s-lab-b9b33038285a1774b3fbad3785c56c561994707d.tar.gz |
filebeat
Diffstat (limited to '')
-rw-r--r-- | tools/eck-operator/templates/beat.yaml | 97 |
1 files changed, 29 insertions, 68 deletions
diff --git a/tools/eck-operator/templates/beat.yaml b/tools/eck-operator/templates/beat.yaml index 48c4b09..0b9edd4 100644 --- a/tools/eck-operator/templates/beat.yaml +++ b/tools/eck-operator/templates/beat.yaml @@ -3,77 +3,38 @@ kind: Beat metadata: name: log-storage spec: + type: filebeat + version: 8.14.1 + elasticsearchRef: + name: log-storage config: - filebeat: - autodiscover: - providers: - - node: ${NODE_NAME} - type: kubernetes - hints: - enabled: true - default_config: - type: container - paths: - - /var/log/containers/*${data.kubernetes.container.id}.log + filebeat.inputs: + - type: container + paths: + - /var/log/containers/*.log daemonSet: podTemplate: spec: - serviceAccount: elastic-beat-filebeat-log-storage - automountServiceAccountToken: true + dnsPolicy: ClusterFirstWithHostNet + hostNetwork: true + securityContext: + runAsUser: 0 containers: - name: filebeat - env: - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName -... ---- -apiVersion: v1 -kind: ServiceAccount -metadata: - name: elastic-beat-filebeat-log-storage ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: elastic-beat-autodiscover-binding -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: elastic-beat-autodiscover -subjects: -- kind: ServiceAccount - name: elastic-beat-filebeat-log-storage - namespace: default ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: elastic-beat-autodiscover -rules: -- apiGroups: - - "" - resources: - - nodes - - namespaces - - events - - pods - verbs: - - get - - list - - watch -- apiGroups: ["apps"] - resources: - - replicasets - verbs: - - get - - list - - watch -- apiGroups: ["batch"] - resources: - - jobs - verbs: - - get - - list - - watch + volumeMounts: + - name: varlogcontainers + mountPath: /var/log/containers + - name: varlogpods + mountPath: /var/log/pods + - name: varlibdockercontainers + mountPath: /var/lib/docker/containers + volumes: + - name: varlogcontainers + hostPath: + path: /var/log/containers + - name: varlogpods + hostPath: + path: /var/log/pods + - name: varlibdockercontainers + hostPath: + path: /var/lib/docker/containers |