-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
9 changed files
with
278 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
apiVersion: v1 | ||
appVersion: "1.0" | ||
description: A Helm chart for Microk8s controller-manager, scheduler and kube-proxy metrics in Prometheus | ||
name: microk8s-kube-metrics | ||
type: application | ||
version: 0.0.1 | ||
home: https://github.com/georgedriver/helm-charts | ||
sources: | ||
- https://github.com/georgedriver/helm-charts | ||
keywords: | ||
- microk8s | ||
- prometheus | ||
- metrics | ||
maintainers: | ||
- name: George |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# microk8s-kube-metrics | ||
|
||
A Helm chart for Microk8s controller-manager, scheduler and kube-proxy metrics in Prometheus | ||
|
||
## Source Code | ||
|
||
* <https://github.com/georgedriver/helm-charts> | ||
|
||
## Installation | ||
|
||
### Add Helm repository | ||
|
||
```shell | ||
helm repo add georgedriver https://georgedriver.github.io/helm-charts | ||
helm repo update | ||
``` | ||
|
||
```shell | ||
helm install --generate-name microk8s-kube-metrics | ||
``` | ||
|
||
## Configuration | ||
|
||
The following table lists the configurable parameters of the chart and the default values. | ||
|
||
## Values | ||
|
||
| Key | Type | Default | Description | | ||
|-----|------|---------|-------------| | ||
| masterIP | string | `"test"` | | | ||
|
||
`docker run --rm --volume "$(pwd):/helm-docs" -u $(id -u) jnorwood/helm-docs:latest` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{{ template "chart.header" . }} | ||
{{ template "chart.description" . }} | ||
|
||
{{ template "chart.kubeVersionLine" . }} | ||
|
||
{{ template "chart.sourcesSection" . }} | ||
|
||
## Installation | ||
|
||
### Add Helm repository | ||
|
||
```shell | ||
helm repo add georgedriver https://georgedriver.github.io/helm-charts | ||
helm repo update | ||
``` | ||
|
||
```shell | ||
helm install --generate-name {{ template "chart.name" . }} | ||
``` | ||
|
||
## Configuration | ||
|
||
The following table lists the configurable parameters of the chart and the default values. | ||
|
||
{{ template "chart.valuesSection" . }} | ||
|
||
`docker run --rm --volume "$(pwd):/helm-docs" -u $(id -u) jnorwood/helm-docs:latest` |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: Endpoints | ||
metadata: | ||
labels: | ||
app.kubernetes.io/managed-by: prometheus-operator | ||
app.kubernetes.io/name: kube-controller-manager | ||
k8s-app: kube-controller-manager | ||
name: kube-controller-manager | ||
namespace: kube-system | ||
subsets: | ||
- addresses: | ||
- ip: {{ .Values.masterIP }} | ||
targetRef: | ||
kind: Node | ||
name: norse | ||
uid: a466371b-4c17-4306-aa64-91d533b7b0a5 | ||
ports: | ||
- name: https-metrics | ||
port: 10257 | ||
protocol: TCP | ||
--- | ||
apiVersion: v1 | ||
kind: Endpoints | ||
metadata: | ||
labels: | ||
app.kubernetes.io/managed-by: prometheus-operator | ||
app.kubernetes.io/name: kube-scheduler | ||
k8s-app: kube-scheduler | ||
name: kube-scheduler | ||
namespace: kube-system | ||
subsets: | ||
- addresses: | ||
- ip: {{ .Values.masterIP }} | ||
targetRef: | ||
kind: Node | ||
name: norse | ||
uid: a466371b-4c17-4306-aa64-91d533b7b0a5 | ||
ports: | ||
- name: https-metrics | ||
port: 10259 | ||
protocol: TCP | ||
|
||
--- | ||
apiVersion: v1 | ||
kind: Endpoints | ||
metadata: | ||
labels: | ||
app.kubernetes.io/managed-by: prometheus-operator | ||
app.kubernetes.io/name: kube-proxy | ||
k8s-app: kube-proxy | ||
name: kube-proxy | ||
namespace: kube-system | ||
subsets: | ||
- addresses: | ||
- ip: {{ .Values.masterIP }} | ||
targetRef: | ||
kind: Node | ||
name: norse | ||
uid: a466371b-4c17-4306-aa64-91d533b7b0a5 | ||
ports: | ||
- name: http-metrics | ||
port: 10249 | ||
protocol: TCP |
71 changes: 71 additions & 0 deletions
71
charts/microk8s-kube-metrics/templates/servicemonitor.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
apiVersion: monitoring.coreos.com/v1 | ||
kind: ServiceMonitor | ||
metadata: | ||
name: microk8s-kube-proxy | ||
namespace: system-monitoring | ||
labels: | ||
app.kubernetes.io/name: microk8s-kube-proxy | ||
k8s-monitoring: "true" | ||
spec: | ||
jobLabel: kube-proxy | ||
endpoints: | ||
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token | ||
interval: 30s | ||
port: http-metrics | ||
scheme: http | ||
selector: | ||
matchLabels: | ||
app.kubernetes.io/name: kube-proxy | ||
namespaceSelector: | ||
matchNames: | ||
- kube-system | ||
|
||
--- | ||
apiVersion: monitoring.coreos.com/v1 | ||
kind: ServiceMonitor | ||
metadata: | ||
name: microk8s-kube-controller-manager | ||
namespace: system-monitoring | ||
labels: | ||
app.kubernetes.io/name: microk8s-kube-controller-manager | ||
k8s-monitoring: "true" | ||
spec: | ||
jobLabel: kube-controller-manager | ||
endpoints: | ||
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token | ||
interval: 30s | ||
port: https-metrics | ||
scheme: https | ||
tlsConfig: | ||
insecureSkipVerify: true | ||
selector: | ||
matchLabels: | ||
app.kubernetes.io/name: kube-controller-manager | ||
namespaceSelector: | ||
matchNames: | ||
- kube-system | ||
|
||
--- | ||
apiVersion: monitoring.coreos.com/v1 | ||
kind: ServiceMonitor | ||
metadata: | ||
name: microk8s-kube-scheduler | ||
namespace: system-monitoring | ||
labels: | ||
app.kubernetes.io/name: microk8s-kube-scheduler | ||
k8s-monitoring: "true" | ||
spec: | ||
jobLabel: kube-scheduler | ||
endpoints: | ||
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token | ||
interval: 30s | ||
port: https-metrics | ||
scheme: https | ||
tlsConfig: | ||
insecureSkipVerify: true | ||
selector: | ||
matchLabels: | ||
app.kubernetes.io/name: kube-scheduler | ||
namespaceSelector: | ||
matchNames: | ||
- kube-system |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
namespace: kube-system | ||
name: kube-scheduler | ||
labels: | ||
k8s-app: kube-scheduler | ||
app.kubernetes.io/name: kube-scheduler | ||
spec: | ||
type: ClusterIP | ||
clusterIP: None | ||
ports: | ||
- name: https-metrics | ||
port: 10259 | ||
targetPort: 10259 | ||
protocol: TCP | ||
--- | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
namespace: kube-system | ||
name: kube-controller-manager | ||
labels: | ||
k8s-app: kube-controller-manager | ||
app.kubernetes.io/name: kube-controller-manager | ||
spec: | ||
type: ClusterIP | ||
clusterIP: None | ||
ports: | ||
- name: https-metrics | ||
port: 10257 | ||
targetPort: 10257 | ||
protocol: TCP | ||
--- | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
namespace: kube-system | ||
name: kube-proxy | ||
labels: | ||
k8s-app: kube-proxy | ||
app.kubernetes.io/name: kube-proxy | ||
spec: | ||
type: ClusterIP | ||
clusterIP: None | ||
ports: | ||
- name: http-metrics | ||
port: 10249 | ||
targetPort: 10249 | ||
protocol: TCP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Default values for microk8s-kube-metrics. | ||
# This is a YAML-formatted file. | ||
# Declare variables to be passed into your templates. | ||
|
||
# name -- The master node IP address which controller-manager, scheduler and kube-proxy are running on | ||
masterIP: "test" |