daemonset.yaml 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. ---
  2. # Source: loki-stack/charts/promtail/templates/daemonset.yaml
  3. apiVersion: apps/v1
  4. kind: DaemonSet
  5. metadata:
  6. name: loki-promtail
  7. namespace: loki
  8. labels:
  9. app: promtail
  10. chart: promtail-0.13.1
  11. release: loki
  12. heritage: Tiller
  13. annotations:
  14. {}
  15. spec:
  16. selector:
  17. matchLabels:
  18. app: promtail
  19. release: loki
  20. updateStrategy:
  21. type: RollingUpdate
  22. template:
  23. metadata:
  24. labels:
  25. app: promtail
  26. release: loki
  27. annotations:
  28. checksum/config: f67946cf335ae9cf8fd8f3ca85db81366fef63f97f5ad24bf1d271fe4c54c429
  29. prometheus.io/port: http-metrics
  30. prometheus.io/scrape: "true"
  31. spec:
  32. serviceAccountName: loki-promtail
  33. containers:
  34. - name: promtail
  35. image: "grafana/promtail:v0.4.0"
  36. imagePullPolicy: IfNotPresent
  37. args:
  38. - "-config.file=/etc/promtail/promtail.yaml"
  39. - "-client.url=http://loki:3100/loki/api/v1/push"
  40. volumeMounts:
  41. - name: config
  42. mountPath: /etc/promtail
  43. - name: run
  44. mountPath: /run/promtail
  45. - mountPath: /var/lib/docker/containers
  46. name: docker
  47. readOnly: true
  48. - mountPath: /var/log/pods
  49. name: pods
  50. readOnly: true
  51. env:
  52. - name: HOSTNAME
  53. valueFrom:
  54. fieldRef:
  55. fieldPath: spec.nodeName
  56. ports:
  57. - containerPort: 3101
  58. name: http-metrics
  59. securityContext:
  60. readOnlyRootFilesystem: true
  61. runAsGroup: 0
  62. runAsUser: 0
  63. readinessProbe:
  64. failureThreshold: 5
  65. httpGet:
  66. path: /ready
  67. port: http-metrics
  68. initialDelaySeconds: 10
  69. periodSeconds: 10
  70. successThreshold: 1
  71. timeoutSeconds: 1
  72. resources:
  73. {}
  74. nodeSelector:
  75. {}
  76. affinity:
  77. {}
  78. tolerations:
  79. - effect: NoSchedule
  80. key: node-role.kubernetes.io/master
  81. operator: Exists
  82. volumes:
  83. - name: config
  84. configMap:
  85. name: loki-promtail
  86. - name: run
  87. hostPath:
  88. path: /run/promtail
  89. - hostPath:
  90. path: /var/lib/docker/containers
  91. name: docker
  92. - hostPath:
  93. path: /var/log/pods
  94. name: pods