Skip to content

Instantly share code, notes, and snippets.

@zimmertr
Created October 30, 2019 18:25
Show Gist options
  • Save zimmertr/f2e3b44a9b83858c2702e7e8b4966d79 to your computer and use it in GitHub Desktop.
Save zimmertr/f2e3b44a9b83858c2702e7e8b4966d79 to your computer and use it in GitHub Desktop.
apiVersion: apps/v1
kind: Deployment
metadata:
name: prometheus
namespace: {{ namespace }}
labels:
app: grafana-prometheus
version: latest
type: offical
facing: internal
spec:
replicas: 1
strategy:
type: Recreate
selector:
matchLabels:
app: prometheus
template:
metadata:
labels:
app: prometheus
spec:
serviceAccountName: grafana-prometheus-scraper
containers:
- name: prometheus
image: prom/prometheus
ports:
- name: "tcp-prometheus"
containerPort: 9090
protocol: TCP
volumeMounts:
- name: grafana-prometheus-data
mountPath: /prometheus
- name: grafana-prometheus-configuration
mountPath: /etc/prometheus/prometheus.yml
subPath: prometheus.yml
volumes:
- name: grafana-prometheus-data
persistentVolumeClaim:
claimName: grafana-prometheus-data
- name: grafana-prometheus-configuration
persistentVolumeClaim:
configMap:
name: grafana-prometheus-configuration
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment