Created
August 14, 2016 23:34
-
-
Save seanknox/00a5c837c79036905973f09f9c293130 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
kubernetes.io/cluster-service: 'true' | |
kubernetes.io/name: monitoring-grafana | |
name: monitoring-grafana | |
namespace: kube-system | |
spec: | |
# In a production setup, we recommend accessing Grafana through an external Loadbalancer | |
# or through a public IP. | |
# type: LoadBalancer | |
ports: | |
- port: 80 | |
targetPort: 3000 | |
selector: | |
name: influxGrafana | |
--- | |
apiVersion: extensions/v1beta1 | |
kind: Deployment | |
metadata: | |
labels: | |
k8s-app: heapster | |
name: heapster | |
version: v6 | |
name: heapster | |
namespace: kube-system | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
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.default | |
- --sink=influxdb:http://monitoring-influxdb:8086 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
kubernetes.io/cluster-service: 'true' | |
kubernetes.io/name: Heapster | |
name: heapster | |
namespace: kube-system | |
spec: | |
ports: | |
- port: 80 | |
targetPort: 8082 | |
selector: | |
k8s-app: heapster | |
--- | |
apiVersion: v1 | |
kind: ReplicationController | |
metadata: | |
labels: | |
name: influxGrafana | |
name: influxdb-grafana | |
namespace: kube-system | |
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: /api/v1/proxy/namespaces/kube-system/services/monitoring-grafana/ | |
volumeMounts: | |
- mountPath: /var | |
name: grafana-storage | |
volumes: | |
- name: influxdb-storage | |
emptyDir: {} | |
- name: grafana-storage | |
emptyDir: {} | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: null | |
name: monitoring-influxdb | |
namespace: kube-system | |
spec: | |
ports: | |
- name: http | |
port: 8083 | |
targetPort: 8083 | |
- name: api | |
port: 8086 | |
targetPort: 8086 | |
selector: | |
name: influxGrafana |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment