2018-03-02 01:03:53 +01:00
|
|
|
apiVersion: extensions/v1beta1
|
|
|
|
kind: Deployment
|
|
|
|
metadata:
|
|
|
|
name: kube-state-metrics
|
|
|
|
spec:
|
|
|
|
replicas: 1
|
|
|
|
template:
|
|
|
|
metadata:
|
|
|
|
labels:
|
|
|
|
app: kube-state-metrics
|
|
|
|
spec:
|
|
|
|
serviceAccountName: kube-state-metrics
|
|
|
|
securityContext:
|
|
|
|
runAsNonRoot: true
|
|
|
|
runAsUser: 65534
|
|
|
|
containers:
|
|
|
|
- name: kube-state-metrics
|
2018-03-06 18:03:25 +01:00
|
|
|
image: carlosedp/kube-state-metrics:v1.2.0
|
2018-03-02 01:03:53 +01:00
|
|
|
args:
|
|
|
|
- "--host=0.0.0.0"
|
|
|
|
- "--port=8443"
|
|
|
|
- "--telemetry-host=0.0.0.0"
|
|
|
|
- "--telemetry-port=9443"
|
|
|
|
ports:
|
|
|
|
- name: http-main
|
|
|
|
containerPort: 8443
|
|
|
|
- name: http-self
|
|
|
|
containerPort: 9443
|
|
|
|
- name: addon-resizer
|
2018-05-29 19:33:05 +02:00
|
|
|
image: carlosedp/addon-resizer:2.1
|
2018-03-02 01:03:53 +01:00
|
|
|
resources:
|
|
|
|
limits:
|
|
|
|
cpu: 100m
|
|
|
|
memory: 30Mi
|
|
|
|
requests:
|
|
|
|
cpu: 100m
|
|
|
|
memory: 30Mi
|
|
|
|
env:
|
|
|
|
- name: MY_POD_NAME
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: metadata.name
|
|
|
|
- name: MY_POD_NAMESPACE
|
|
|
|
valueFrom:
|
|
|
|
fieldRef:
|
|
|
|
fieldPath: metadata.namespace
|
|
|
|
command:
|
|
|
|
- /pod_nanny
|
|
|
|
- --container=kube-state-metrics
|
|
|
|
- --cpu=100m
|
|
|
|
- --extra-cpu=2m
|
|
|
|
- --memory=150Mi
|
|
|
|
- --extra-memory=30Mi
|
|
|
|
#- --threshold=5
|
|
|
|
- --deployment=kube-state-metrics
|