Compare commits
4 Commits
auto-updat
...
auto-updat
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6d2ceb50ef | ||
|
|
fb651bc6fe | ||
|
|
04330aa474 | ||
|
|
57d517af77 |
@@ -40,6 +40,7 @@ ArgoCD homelab project
|
|||||||
| **greece-notifier** | [](https://ag.hexor.cy/applications/argocd/greece-notifier) |
|
| **greece-notifier** | [](https://ag.hexor.cy/applications/argocd/greece-notifier) |
|
||||||
| **hexound** | [](https://ag.hexor.cy/applications/argocd/hexound) |
|
| **hexound** | [](https://ag.hexor.cy/applications/argocd/hexound) |
|
||||||
| **immich** | [](https://ag.hexor.cy/applications/argocd/immich) |
|
| **immich** | [](https://ag.hexor.cy/applications/argocd/immich) |
|
||||||
|
| **iperf3** | [](https://ag.hexor.cy/applications/argocd/iperf3) |
|
||||||
| **jellyfin** | [](https://ag.hexor.cy/applications/argocd/jellyfin) |
|
| **jellyfin** | [](https://ag.hexor.cy/applications/argocd/jellyfin) |
|
||||||
| **k8s-secrets** | [](https://ag.hexor.cy/applications/argocd/k8s-secrets) |
|
| **k8s-secrets** | [](https://ag.hexor.cy/applications/argocd/k8s-secrets) |
|
||||||
| **khm** | [](https://ag.hexor.cy/applications/argocd/khm) |
|
| **khm** | [](https://ag.hexor.cy/applications/argocd/khm) |
|
||||||
|
|||||||
@@ -14,6 +14,58 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
app: iperf3-exporter
|
app: iperf3-exporter
|
||||||
spec:
|
spec:
|
||||||
|
serviceAccountName: iperf3-server
|
||||||
|
initContainers:
|
||||||
|
- name: create-exporter-service
|
||||||
|
image: bitnami/kubectl:latest
|
||||||
|
env:
|
||||||
|
- name: NODE_NAME
|
||||||
|
valueFrom:
|
||||||
|
fieldRef:
|
||||||
|
fieldPath: spec.nodeName
|
||||||
|
- name: POD_IP
|
||||||
|
valueFrom:
|
||||||
|
fieldRef:
|
||||||
|
fieldPath: status.podIP
|
||||||
|
command:
|
||||||
|
- /bin/bash
|
||||||
|
- -c
|
||||||
|
- |
|
||||||
|
NODE_CLEAN=$(echo "$NODE_NAME" | cut -d'.' -f1 | tr '[:upper:]' '[:lower:]' | tr '_' '-')
|
||||||
|
SERVICE_NAME="iperf3-exporter-${NODE_CLEAN}"
|
||||||
|
|
||||||
|
kubectl apply -f - <<EOF
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: ${SERVICE_NAME}
|
||||||
|
namespace: iperf3
|
||||||
|
labels:
|
||||||
|
app: iperf3-exporter-service
|
||||||
|
target-node: "${NODE_NAME}"
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- name: metrics
|
||||||
|
port: 9579
|
||||||
|
protocol: TCP
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Endpoints
|
||||||
|
metadata:
|
||||||
|
name: ${SERVICE_NAME}
|
||||||
|
namespace: iperf3
|
||||||
|
labels:
|
||||||
|
app: iperf3-exporter-service
|
||||||
|
target-node: "${NODE_NAME}"
|
||||||
|
subsets:
|
||||||
|
- addresses:
|
||||||
|
- ip: ${POD_IP}
|
||||||
|
ports:
|
||||||
|
- name: metrics
|
||||||
|
port: 9579
|
||||||
|
protocol: TCP
|
||||||
|
EOF
|
||||||
containers:
|
containers:
|
||||||
- name: iperf3-exporter
|
- name: iperf3-exporter
|
||||||
image: ghcr.io/edgard/iperf3_exporter:1.2.2
|
image: ghcr.io/edgard/iperf3_exporter:1.2.2
|
||||||
|
|||||||
@@ -16,26 +16,105 @@ spec:
|
|||||||
interval: 5m
|
interval: 5m
|
||||||
scrapeTimeout: 30s
|
scrapeTimeout: 30s
|
||||||
params:
|
params:
|
||||||
target:
|
target: ['iperf3-ch.iperf3.svc.cluster.local:5201']
|
||||||
- "iperf3-ch.iperf3.svc.cluster.local:5201"
|
period: ['10s']
|
||||||
- "iperf3-us.iperf3.svc.cluster.local:5201"
|
streams: ['4']
|
||||||
- "iperf3-iris.iperf3.svc.cluster.local:5201"
|
|
||||||
- "iperf3-home.iperf3.svc.cluster.local:5201"
|
|
||||||
- "iperf3-master.iperf3.svc.cluster.local:5201"
|
|
||||||
- "iperf3-it.iperf3.svc.cluster.local:5201"
|
|
||||||
- "iperf3-nas.iperf3.svc.cluster.local:5201"
|
|
||||||
- "iperf3-spb.iperf3.svc.cluster.local:5201"
|
|
||||||
duration:
|
|
||||||
- "10"
|
|
||||||
streams:
|
|
||||||
- "4"
|
|
||||||
relabelings:
|
relabelings:
|
||||||
- sourceLabels: [__param_target]
|
- sourceLabels: [__param_target]
|
||||||
targetLabel: instance
|
targetLabel: instance
|
||||||
- sourceLabels: [__param_target]
|
|
||||||
targetLabel: __param_target
|
|
||||||
- targetLabel: __address__
|
- targetLabel: __address__
|
||||||
replacement: iperf3-exporter.iperf3.svc.cluster.local:9579
|
replacement: ch.tail2fe2d.ts.net
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-us.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: us.tail2fe2d.ts.net
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-iris.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: iris.khv
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-home.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: home.homenet
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-master.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: de.hexor.cy
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-it.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: it.hexor.cy
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-nas.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: nas.homenet
|
||||||
|
- port: metrics
|
||||||
|
path: /probe
|
||||||
|
interval: 5m
|
||||||
|
scrapeTimeout: 30s
|
||||||
|
params:
|
||||||
|
target: ['iperf3-spb.iperf3.svc.cluster.local:5201']
|
||||||
|
period: ['10s']
|
||||||
|
streams: ['4']
|
||||||
|
relabelings:
|
||||||
|
- sourceLabels: [__param_target]
|
||||||
|
targetLabel: instance
|
||||||
|
- targetLabel: __address__
|
||||||
|
replacement: spb.tail2fe2d.ts.net
|
||||||
metricRelabelings:
|
metricRelabelings:
|
||||||
- sourceLabels: [__name__]
|
- sourceLabels: [__name__]
|
||||||
regex: iperf3_(.+)
|
regex: iperf3_(.+)
|
||||||
|
|||||||
Reference in New Issue
Block a user