Scale down Kubernetes deployments after work hours
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

42 lines
1.0 KiB

apiVersion: apps/v1
kind: Deployment
metadata:
labels:
application: kube-downscaler
version: v21.2.0
name: kube-downscaler
spec:
replicas: 1
selector:
matchLabels:
application: kube-downscaler
template:
metadata:
labels:
application: kube-downscaler
version: v21.2.0
spec:
serviceAccountName: kube-downscaler
containers:
- name: downscaler
# see https://github.com/hjacobs/kube-downscaler/releases
image: hjacobs/kube-downscaler:21.2.0
args:
# dry run by default, remove to perform downscaling
- --dry-run
# run every minute
- --interval=60
envFrom:
- configMapRef:
name: kube-downscaler
optional: true
resources:
limits:
memory: 100Mi
requests:
cpu: 5m
memory: 100Mi
securityContext:
readOnlyRootFilesystem: true
runAsNonRoot: true
runAsUser: 1000