~xdavidwu/flux

4f16e73a1377c055d09deecd0230e276a89e48bd — Pinghao Wu 19 days ago 4cd3113
prometheus: add thanos store
A monitoring/prometheus/deployment-store.yaml => monitoring/prometheus/deployment-store.yaml +38 -0
@@ 0,0 1,38 @@
apiVersion: apps/v1
kind: Deployment
metadata:
  name: thanos-store
spec:
  replicas: 1
  selector:
    matchLabels:
      component: store
  template:
    metadata:
      annotations:
        prometheus.xdavidwu.link/instance: main
      labels:
        metrics: metrics
        component: store
    spec:
      containers:
        - name: store
          image: quay.io/thanos/thanos:THANOS_VERSION
          args:
            - store
            - --data-dir=/tmp
            - --objstore.config-file=/etc/thanos/objstore.yml
          ports:
            - name: metrics
              containerPort: 10902
          readinessProbe:
            httpGet:
              port: metrics
              path: /-/ready
          volumeMounts:
            - name: thanos
              mountPath: /etc/thanos
      volumes:
        - name: thanos
          secret:
            secretName: thanos

M monitoring/prometheus/kustomization.yaml => monitoring/prometheus/kustomization.yaml +2 -0
@@ 13,6 13,8 @@ resources:
  - namespace.yaml
  - deployment.yaml
  - service.yaml
  - deployment-store.yaml
  - service-store.yaml
  - configmap.yaml
  - serviceaccount.yaml
  - clusterrole.yaml

A monitoring/prometheus/service-store.yaml => monitoring/prometheus/service-store.yaml +11 -0
@@ 0,0 1,11 @@
apiVersion: v1
kind: Service
metadata:
  name: thanos-store
spec:
  selector:
    component: store
  ports:
    - name: store-grpc
      protocol: TCP
      port: 10901