diff options
Diffstat (limited to '')
| -rw-r--r-- | bundles/prometheus/files/kube.yaml | 71 |
1 files changed, 64 insertions, 7 deletions
diff --git a/bundles/prometheus/files/kube.yaml b/bundles/prometheus/files/kube.yaml index 952f485..7a7f961 100644 --- a/bundles/prometheus/files/kube.yaml +++ b/bundles/prometheus/files/kube.yaml @@ -9,40 +9,97 @@ metadata: traefik.http.routers.prometheus.entrypoints: http,https traefik.http.routers.prometheus.rule: Host(`prom.gzr.im`) traefik.http.routers.prometheus.service: prometheus + traefik.http.routers.prometheus.middlewares: prometheus-consoles-redirect traefik.http.services.prometheus.loadbalancer.server.port: 9090 + traefik.http.middlewares.prometheus-consoles-redirect.redirectregex.regex: ^https://prom.gzr.im/consoles(|/)$ + traefik.http.middlewares.prometheus-consoles-redirect.redirectregex.replacement: https://prom.gzr.im/consoles/index.html + traefik.http.middlewares.prometheus-consoles-redirect.redirectregex.permanent: true spec: - restartPolicy: Never dnsPolicy: Default dnsConfig: searches: - tail2d6ce.ts.net + securityContext: + runAsUser: 0 containers: - name: prom - image: quay.io/prometheus/prometheus:v2.52.0 + image: quay.io/prometheus/prometheus:v3.7.3 + args: + - --config.file=/etc/prometheus/prometheus.yml + - --storage.tsdb.path=/prometheus + - --storage.tsdb.retention.time=30d + - --storage.tsdb.retention.size=6GB + - --web.page-title=Prometheus + - --web.console.templates=/usr/share/prometheus/consoles + - --web.console.libraries=/usr/share/prometheus/console_libraries + - --web.user-assets=/usr/share/prometheus/console_assets volumeMounts: - - mountPath: /etc/prometheus:z + - mountPath: /etc/prometheus name: config readOnly: true - - mountPath: /usr/share/prometheus/consoles:z + - mountPath: /usr/share/prometheus/consoles name: config subPath: consoles readOnly: true - - mountPath: /usr/share/prometheus/console_libraries:z + - mountPath: /usr/share/prometheus/console_libraries name: config subPath: console_libraries readOnly: true + - mountPath: /usr/share/prometheus/console_assets + name: config + subPath: console_assets + readOnly: true + - mountPath: /prometheus + name: prom-data ports: - containerPort: 9090 protocol: TCP + livenessProbe: + exec: + command: + - sh + - -c + - wget -qO - http://localhost:9090/-/healthy | grep -q 'is Healthy' resources: limits: cpu: 100m - memory: 200Mi + memory: 256Mi requests: cpu: 25m - memory: 100Mi + memory: 128Mi + + - name: alert + image: quay.io/prometheus/alertmanager:v0.29.0 + volumeMounts: + - mountPath: /etc/alertmanager + name: config + readOnly: true + - mountPath: /alertmanager + name: alert-data + ports: + - containerPort: 9093 + protocol: TCP + livenessProbe: + exec: + command: + - sh + - -c + - wget -qO - http://localhost:9093/-/healthy | grep -q 'OK' + resources: + limits: + cpu: 50m + memory: 64Mi + volumes: - name: config hostPath: path: /etc/prometheus type: Directory + - name: prom-data + hostPath: + path: /var/lib/prometheus/prom + type: DirectoryOrCreate + - name: alert-data + hostPath: + path: /var/lib/prometheus/alert + type: DirectoryOrCreate |