init commit
This commit is contained in:
@@ -0,0 +1,71 @@
|
||||
---
|
||||
"kind": "ServiceAccount"
|
||||
"apiVersion": "v1"
|
||||
"metadata":
|
||||
"name": "loki"
|
||||
"namespace": "loki"
|
||||
---
|
||||
"kind": "ConfigMap"
|
||||
"apiVersion": "v1"
|
||||
"metadata":
|
||||
"name": "loki-config"
|
||||
"namespace": "loki"
|
||||
"data":
|
||||
"loki.yaml": |
|
||||
auth_enabled: false
|
||||
|
||||
server:
|
||||
http_listen_port: 3100
|
||||
grpc_listen_port: 9096
|
||||
|
||||
common:
|
||||
instance_addr: 127.0.0.1
|
||||
path_prefix: /loki
|
||||
storage:
|
||||
filesystem:
|
||||
chunks_directory: /loki/chunks
|
||||
rules_directory: /loki/rules
|
||||
replication_factor: 1
|
||||
ring:
|
||||
kvstore:
|
||||
store: inmemory
|
||||
|
||||
schema_config:
|
||||
configs:
|
||||
- from: "2024-04-01"
|
||||
store: tsdb
|
||||
object_store: filesystem
|
||||
schema: v13
|
||||
index:
|
||||
prefix: index_
|
||||
period: 24h
|
||||
|
||||
limits_config:
|
||||
allow_structured_metadata: true
|
||||
reject_old_samples: true
|
||||
reject_old_samples_max_age: 168h
|
||||
ingestion_rate_mb: 16
|
||||
ingestion_burst_size_mb: 32
|
||||
max_cache_freshness_per_query: 10m
|
||||
|
||||
storage_config:
|
||||
filesystem:
|
||||
directory: /loki/chunks
|
||||
tsdb_shipper:
|
||||
active_index_directory: /loki/index
|
||||
cache_location: /loki/index_cache
|
||||
|
||||
---
|
||||
"kind": "PersistentVolumeClaim"
|
||||
"apiVersion": "v1"
|
||||
"metadata":
|
||||
"name": "loki-data"
|
||||
"namespace": "loki"
|
||||
"spec":
|
||||
"accessModes":
|
||||
- "ReadWriteOnce"
|
||||
"resources":
|
||||
"requests":
|
||||
"storage": "20Gi"
|
||||
"storageClassName": "nfs-csi"
|
||||
"volumeMode": "Filesystem"
|
||||
@@ -0,0 +1,50 @@
|
||||
---
|
||||
"kind": "Service"
|
||||
"apiVersion": "v1"
|
||||
"metadata":
|
||||
"name": "loki"
|
||||
"namespace": "loki"
|
||||
"labels":
|
||||
"k8slens-edit-resource-version": "v1"
|
||||
"spec":
|
||||
"ports":
|
||||
-
|
||||
"name": "http-metrics"
|
||||
"protocol": "TCP"
|
||||
"port": 3100
|
||||
"targetPort": "http-metrics"
|
||||
"nodePort": 31940
|
||||
-
|
||||
"name": "grpc"
|
||||
"protocol": "TCP"
|
||||
"port": 9096
|
||||
"targetPort": "grpc"
|
||||
"nodePort": 30320
|
||||
"selector":
|
||||
"app": "loki"
|
||||
"type": "NodePort"
|
||||
"sessionAffinity": "None"
|
||||
"externalTrafficPolicy": "Cluster"
|
||||
---
|
||||
"kind": "Service"
|
||||
"apiVersion": "v1"
|
||||
"metadata":
|
||||
"name": "loki-headless"
|
||||
"namespace": "loki"
|
||||
"spec":
|
||||
"ports":
|
||||
-
|
||||
"name": "http-metrics"
|
||||
"protocol": "TCP"
|
||||
"port": 3100
|
||||
"targetPort": "http-metrics"
|
||||
-
|
||||
"name": "grpc"
|
||||
"protocol": "TCP"
|
||||
"port": 9096
|
||||
"targetPort": "grpc"
|
||||
"selector":
|
||||
"app": "loki"
|
||||
"type": "ClusterIP"
|
||||
"sessionAffinity": "None"
|
||||
"clusterIP": "None"
|
||||
@@ -0,0 +1,100 @@
|
||||
---
|
||||
"kind": "StatefulSet"
|
||||
"apiVersion": "apps/v1"
|
||||
"metadata":
|
||||
"name": "loki"
|
||||
"namespace": "loki"
|
||||
"spec":
|
||||
"replicas": 1
|
||||
"selector":
|
||||
"matchLabels":
|
||||
"app": "loki"
|
||||
"template":
|
||||
"metadata":
|
||||
"labels":
|
||||
"app": "loki"
|
||||
"spec":
|
||||
"volumes":
|
||||
-
|
||||
"name": "config"
|
||||
"configMap":
|
||||
"name": "loki-config"
|
||||
"defaultMode": 420
|
||||
-
|
||||
"name": "storage"
|
||||
"persistentVolumeClaim":
|
||||
"claimName": "loki-data"
|
||||
"containers":
|
||||
-
|
||||
"name": "loki"
|
||||
"image": "grafana/loki:3.4.2"
|
||||
"args":
|
||||
- "-config.file=/etc/loki/config/loki.yaml"
|
||||
"ports":
|
||||
-
|
||||
"name": "http-metrics"
|
||||
"containerPort": 3100
|
||||
"protocol": "TCP"
|
||||
-
|
||||
"name": "grpc"
|
||||
"containerPort": 9096
|
||||
"protocol": "TCP"
|
||||
"resources":
|
||||
"limits":
|
||||
"cpu": "1"
|
||||
"memory": "1Gi"
|
||||
"requests":
|
||||
"cpu": "100m"
|
||||
"memory": "256Mi"
|
||||
"volumeMounts":
|
||||
-
|
||||
"name": "storage"
|
||||
"mountPath": "/loki"
|
||||
-
|
||||
"name": "config"
|
||||
"mountPath": "/etc/loki/config"
|
||||
"livenessProbe":
|
||||
"httpGet":
|
||||
"path": "/ready"
|
||||
"port": "http-metrics"
|
||||
"scheme": "HTTP"
|
||||
"initialDelaySeconds": 45
|
||||
"timeoutSeconds": 1
|
||||
"periodSeconds": 10
|
||||
"successThreshold": 1
|
||||
"failureThreshold": 3
|
||||
"readinessProbe":
|
||||
"httpGet":
|
||||
"path": "/ready"
|
||||
"port": "http-metrics"
|
||||
"scheme": "HTTP"
|
||||
"initialDelaySeconds": 45
|
||||
"timeoutSeconds": 1
|
||||
"periodSeconds": 10
|
||||
"successThreshold": 1
|
||||
"failureThreshold": 3
|
||||
"terminationMessagePath": "/dev/termination-log"
|
||||
"terminationMessagePolicy": "File"
|
||||
"imagePullPolicy": "IfNotPresent"
|
||||
"restartPolicy": "Always"
|
||||
"terminationGracePeriodSeconds": 30
|
||||
"dnsPolicy": "ClusterFirst"
|
||||
"serviceAccountName": "loki"
|
||||
"serviceAccount": "loki"
|
||||
"securityContext":
|
||||
"runAsUser": 10001
|
||||
"runAsGroup": 10001
|
||||
"runAsNonRoot": true
|
||||
"fsGroup": 10001
|
||||
"schedulerName": "default-scheduler"
|
||||
"serviceName": "loki"
|
||||
"podManagementPolicy": "OrderedReady"
|
||||
"updateStrategy":
|
||||
"type": "RollingUpdate"
|
||||
"rollingUpdate":
|
||||
"partition": 0
|
||||
"maxUnavailable": 1
|
||||
"revisionHistoryLimit": 10
|
||||
"persistentVolumeClaimRetentionPolicy":
|
||||
"whenDeleted": "Retain"
|
||||
"whenScaled": "Retain"
|
||||
Reference in New Issue
Block a user