Adding Heapster Kubernetes Template

This commit is contained in:
galal-hussein
2016-09-27 20:45:54 +02:00
parent b53c9d1b92
commit c5fa6bde5b
9 changed files with 205 additions and 0 deletions
@@ -0,0 +1,5 @@
# Heapster Grafana InfluxDB
Heapster enables Container Cluster Monitoring and Performance Analysis. Heapster collects and interprets various signals like compute resource usage, lifecycle events, etc, and exports cluster metrics via REST endpoints.
This Tempalte runs Heapster with Grafana and InfluxDB in kube-system namespace, it should be running on Kubernetes v1.3.4-rancher1 or higher.
@@ -0,0 +1,14 @@
apiVersion: v1
kind: Service
metadata:
namespace: kube-system
labels: null
name: monitoring-grafana
spec:
type: NodePort
ports:
- port: 80
nodePort: ${GRAFANA_PORT}
targetPort: 3000
selector:
name: influxGrafana
@@ -0,0 +1,29 @@
---
apiVersion: v1
kind: ReplicationController
metadata:
namespace: kube-system
labels:
k8s-app: heapster
name: heapster
version: v6
name: heapster
spec:
replicas: 1
selector:
k8s-app: heapster
version: v6
template:
metadata:
labels:
k8s-app: heapster
version: v6
spec:
containers:
- name: heapster
image: kubernetes/heapster:canary
imagePullPolicy: Always
command:
- /heapster
- --source=kubernetes:https://Kubernetes.kubernetes:6443?inClusterConfig=true&insecure=true
- --sink=influxdb:http://monitoring-influxdb:8086
@@ -0,0 +1,13 @@
---
apiVersion: v1
kind: Service
metadata:
namespace: kube-system
labels: null
name: heapster
spec:
ports:
- port: 80
targetPort: 8082
selector:
k8s-app: heapster
@@ -0,0 +1,48 @@
---
apiVersion: v1
kind: ReplicationController
metadata:
namespace: kube-system
labels:
name: influxGrafana
name: influxdb-grafana
spec:
replicas: 1
selector:
name: influxGrafana
template:
metadata:
labels:
name: influxGrafana
spec:
containers:
- name: influxdb
image: kubernetes/heapster_influxdb:v0.5
volumeMounts:
- mountPath: /data
name: influxdb-storage
- name: grafana
image: gcr.io/google_containers/heapster_grafana:v2.6.0-2
env:
- name: INFLUXDB_SERVICE_URL
value: http://monitoring-influxdb:8086
# The following env variables are required to make Grafana accessible via
# the kubernetes api-server proxy. On production clusters, we recommend
# removing these env variables, setup auth for grafana, and expose the grafana
# service using a LoadBalancer or a public IP.
- name: GF_AUTH_BASIC_ENABLED
value: "false"
- name: GF_AUTH_ANONYMOUS_ENABLED
value: "true"
- name: GF_AUTH_ANONYMOUS_ORG_ROLE
value: Admin
- name: GF_SERVER_ROOT_URL
value: /
volumeMounts:
- mountPath: /var
name: grafana-storage
volumes:
- name: influxdb-storage
emptyDir: {}
- name: grafana-storage
emptyDir: {}
@@ -0,0 +1,19 @@
---
apiVersion: v1
kind: Service
metadata:
namespace: kube-system
labels: null
name: monitoring-influxdb
spec:
type: NodePort
ports:
- name: http
nodePort: ${INFLUXDB_PORT}
port: 8083
targetPort: 8083
- name: api
port: 8086
targetPort: 8086
selector:
name: influxGrafana
@@ -0,0 +1,15 @@
.catalog:
name: Heapster Grafana InfluxDB
version: canary-rancher1
description: A cluster-wide aggregator of monitoring and event data.
questions:
- variable: "GRAFANA_PORT"
label: "Node port for Grafana"
required: true
default: 30804
type: "int"
- variable: "INFLUXDB_PORT"
label: "Node port for Influxdb"
required: true
default: 30805
type: "int"
@@ -0,0 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 19.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="351px"
height="365px" viewBox="0 0 351 365" style="enable-background:new 0 0 351 365;" xml:space="preserve">
<style type="text/css">
.st0{fill:url(#SVGID_1_);}
</style>
<g id="Layer_1">
</g>
<g id="Layer_2">
<linearGradient id="SVGID_1_" gradientUnits="userSpaceOnUse" x1="170.963" y1="439.9414" x2="170.963" y2="106.0154">
<stop offset="0" style="stop-color:#FFF200"/>
<stop offset="1" style="stop-color:#F15A29"/>
</linearGradient>
<path class="st0" d="M228.8,239.8c-1.1-1.4-3.1-1.8-4.7-0.9c-0.4,0.2-0.8,0.4-1.2,0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9,12.7-11.6,19.6c-2.7,6.9-4.2,14.1-4.6,21c-0.1,1.7-0.1,3.5-0.1,5.2c0,0.4,0,0.9,0,1.3l0.1,1.4c0.1,0.8,0.1,1.7,0.2,2.5
c0.3,3.5,1,6.9,1.9,10.1c1.9,6.5,4.9,12.4,8.6,17.4c3.7,5,8.2,9.1,12.9,12.4c4.7,3.2,9.8,5.5,14.8,7c5,1.5,10,2.1,14.7,2.1
c0.6,0,1.2,0,1.7,0c0.3,0,0.6,0,0.9,0c0.3,0,0.6,0,0.9-0.1c0.5,0,1-0.1,1.5-0.1c0.1,0,0.3,0,0.4-0.1l0.5-0.1c0.3,0,0.6-0.1,0.9-0.1
c0.6-0.1,1.1-0.2,1.7-0.3c0.6-0.1,1.1-0.2,1.6-0.4c1.1-0.2,2.1-0.6,3.1-0.9c2-0.7,3.9-1.5,5.7-2.4c1.8-0.9,3.4-2,5-3
c0.4-0.3,0.9-0.6,1.3-1C229.9,243.8,230.1,241.4,228.8,239.8L228.8,239.8z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.6 KiB

+4
View File
@@ -0,0 +1,4 @@
name: Heapster Grafana InfluxDB
description: A cluster-wide aggregator of monitoring and event data.
version: canary-rancher1
category: Monitoring